Skip to content

KVM: Fix guest_memfd binding overlap errno and selftest

Sean Christopherson kvm lkml sashiko-reviews 1 version Applied

Status from this message: Applied to kvm-x86 gmem, thanks!

Get series with b4
b4 am [email protected]

Versions newest first

  1. v2 Latest3 patches 3 repliesApplied

Changes in v2 from the cover letter

- Collect Ackerley's reviews.
- Keep the GPA overlap testcases (because why not). [Sean]
- Add a patch to remove superfluous %s formatting. [Ackerley]

Patches in v2 Applied

#Subject and filesSizeRepliesApplied
1/3KVM: guest_memfd: Return -EEXIST for overlapping bindingsvirt/kvm/guest_memfd.c+1 -01 reply
2/3KVM: selftests: Test guest_memfd binding overlap without GPA overlaptools/testing/selftests/kvm/set_memory_region_test.c+25 -20 replies
3/3KVM: selftests: Remove unnecessary "%s" formatting of a constant stringtools/testing/selftests/kvm/set_memory_region_test.c+2 -21 reply

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchAckerley Tng
1/3R-b T-b
2/3R-b T-b
3/3R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/3] KVM: Fix guest_memfd binding overlap errno and selftest

Fix a goof where KVM rejects guest_memfd bindings that overlap an existing binding with EINVAL instead of the intended EEXIST, and then add that specific scenario to testcase that's supposed to verify overlap checks.

v2:
- Collect Ackerley's reviews.
- Keep the GPA overlap testcases (because why not). [Sean]
- Add a patch to remove superfluous %s formatting. [Ackerley]

v1: https://lore.kernel.org/all/[email protected]

Sean Christopherson (1):
KVM: selftests: Remove unnecessary "%s" formatting of a constant
string

Zongyao Chen (2):
KVM: guest_memfd: Return -EEXIST for overlapping bindings
KVM: selftests: Test guest_memfd binding overlap without GPA overlap

 .../selftests/kvm/set_memory_region_test.c    | 31 ++++++++++++++++---
 virt/kvm/guest_memfd.c                        |  1 +
 2 files changed, 28 insertions(+), 4 deletions(-)

base-commit: b7fbe9a1bf9ee6c967ef77d366ca58c35fcf1887

Signature · 1 line
2.54.0.794.g4f17f83d09-goog