From: Ackerley Tng <ackerleytng@google.com>
To: Sean Christopherson <seanjc@google.com>,
Marc Zyngier <maz@kernel.org>,
Oliver Upton <oliver.upton@linux.dev>,
Paolo Bonzini <pbonzini@redhat.com>
Cc: linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev,
kvm@vger.kernel.org, linux-kernel@vger.kernel.org,
David Hildenbrand <david@redhat.com>,
Fuad Tabba <tabba@google.com>, Shivank Garg <shivankg@amd.com>,
Ashish Kalra <ashish.kalra@amd.com>,
Vlastimil Babka <vbabka@suse.cz>
Subject: Re: [PATCH v12 00/12] KVM: guest_memfd: Add NUMA mempolicy support
Date: Thu, 09 Oct 2025 13:58:24 -0700 [thread overview]
Message-ID: <diqz5xcniyhb.fsf@google.com> (raw)
In-Reply-To: <20251007221420.344669-1-seanjc@google.com>
Sean Christopherson <seanjc@google.com> writes:
> Shivank's series to add support for NUMA-aware memory placement in
> guest_memfd. This is based on:
>
> https://github.com/kvm-x86/linux.git gmem
>
> which is an unstable topic branch that contains the guest_memfd MMAP fixes
> destined for 6.18 (to avoid conflicts), and three non-KVM changes related to
> mempolicy that were in previous versions of this series
For future reference, these are the three specific patches:
[1] https://lore.kernel.org/all/20250827175247.83322-4-shivankg@amd.com/
[2] https://lore.kernel.org/all/20250827175247.83322-5-shivankg@amd.com/
[3] https://lore.kernel.org/all/20250827175247.83322-6-shivankg@amd.com/
Might have missed this, did we discuss how these 3 would get merged? I
noticed this patch was withdrawn, not sure what that means: [4]
[4] https://lore.kernel.org/all/20250625000155.62D08C4CEE3@smtp.kernel.org/
> (I want to keep this
> version KVM focused, and AFAICT there is nothing left to discuss in the prep
> paches).
>
> Once 6.18-rc1 is cut I'll turn "gmem" into a proper topic branch, rebase it,
> and freeze the hashes.
>
> v12:
> - Add missing functionality to KVM selftests' existing numaif.h instead of
> linking to libnuma (which appears to have caveats with -static).
> - Add KVM_SYSCALL_DEFINE() infrastructure to reduce the boilerplate needed
> to wrap syscalls and/or to assert that a syscall succeeds.
> - Rename kvm_gmem to gmem_file, and use gmem_inode for the inode structure.
> - Track flags in a gmem_inode field instead of using i_private.
> - Add comments to call out subtleties in the mempolicy code (e.g. that
> returning NULL for vm_operations_struct.get_policy() is important for ABI
> reasons).
> - Improve debugability of guest_memfd_test (I kept generating SIGBUS when
> tweaking the tests).
> - Test mbind() with private memory (sadly, verifying placement with
> move_pages() doesn't work due to the dependency on valid page tables).
>
> - V11: Rebase on kvm-next, remove RFC tag, use Ackerley's latest patch
> and fix a rcu race bug during kvm module unload.
> - V10: Rebase on top of Fuad's V17. Use latest guest_memfd inode patch
> from Ackerley (with David's review comments). Use newer kmem_cache_create()
> API variant with arg parameter (Vlastimil)
> - v9: Rebase on top of Fuad's V13 and incorporate review comments
> - v8: Rebase on top of Fuad's V12: Host mmaping for guest_memfd memory.
> - v7: Use inodes to store NUMA policy instead of file [0].
> - v4-v6: Current approach using shared_policy support and vm_ops (based on
> suggestions from David [1] and guest_memfd bi-weekly upstream
> call discussion [2]).
> - v3: Introduced fbind() syscall for VMM memory-placement configuration.
> - v1,v2: Extended the KVM_CREATE_GUEST_MEMFD IOCTL to pass mempolicy.
>
> [0] https://lore.kernel.org/all/diqzbjumm167.fsf@ackerleytng-ctop.c.googlers.com
> [1] https://lore.kernel.org/all/6fbef654-36e2-4be5-906e-2a648a845278@redhat.com
> [2] https://lore.kernel.org/all/2b77e055-98ac-43a1-a7ad-9f9065d7f38f@amd.com
>
> Ackerley Tng (1):
> KVM: guest_memfd: Use guest mem inodes instead of anonymous inodes
>
> Sean Christopherson (7):
> KVM: guest_memfd: Rename "struct kvm_gmem" to "struct gmem_file"
> KVM: guest_memfd: Add macro to iterate over gmem_files for a
> mapping/inode
> KVM: selftests: Define wrappers for common syscalls to assert success
> KVM: selftests: Report stacktraces SIGBUS, SIGSEGV, SIGILL, and SIGFPE
> by default
> KVM: selftests: Add additional equivalents to libnuma APIs in KVM's
> numaif.h
> KVM: selftests: Use proper uAPI headers to pick up mempolicy.h
> definitions
> KVM: guest_memfd: Add gmem_inode.flags field instead of using
> i_private
>
> Shivank Garg (4):
> KVM: guest_memfd: Add slab-allocated inode cache
> KVM: guest_memfd: Enforce NUMA mempolicy using shared policy
> KVM: selftests: Add helpers to probe for NUMA support, and multi-node
> systems
> KVM: selftests: Add guest_memfd tests for mmap and NUMA policy support
>
> include/uapi/linux/magic.h | 1 +
> tools/testing/selftests/kvm/arm64/vgic_irq.c | 2 +-
> .../testing/selftests/kvm/guest_memfd_test.c | 98 +++++
> .../selftests/kvm/include/kvm_syscalls.h | 81 +++++
> .../testing/selftests/kvm/include/kvm_util.h | 29 +-
> tools/testing/selftests/kvm/include/numaif.h | 110 +++---
> .../selftests/kvm/kvm_binary_stats_test.c | 4 +-
> tools/testing/selftests/kvm/lib/kvm_util.c | 55 +--
> .../kvm/x86/private_mem_conversions_test.c | 9 +-
> .../selftests/kvm/x86/xapic_ipi_test.c | 5 +-
> virt/kvm/guest_memfd.c | 344 ++++++++++++++----
> virt/kvm/kvm_main.c | 7 +-
> virt/kvm/kvm_mm.h | 9 +-
> 13 files changed, 576 insertions(+), 178 deletions(-)
> create mode 100644 tools/testing/selftests/kvm/include/kvm_syscalls.h
>
>
> base-commit: 67033eaa5ea2cb67b6cdaa91d7f5c42bfafb36f7
> --
> 2.51.0.710.ga91ca5db03-goog
next prev parent reply other threads:[~2025-10-09 20:58 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-07 22:14 [PATCH v12 00/12] KVM: guest_memfd: Add NUMA mempolicy support Sean Christopherson
2025-10-07 22:14 ` [PATCH v12 01/12] KVM: guest_memfd: Rename "struct kvm_gmem" to "struct gmem_file" Sean Christopherson
2025-10-08 5:25 ` Garg, Shivank
2025-10-09 21:08 ` Ackerley Tng
2025-10-10 15:07 ` David Hildenbrand
2025-10-07 22:14 ` [PATCH v12 02/12] KVM: guest_memfd: Add macro to iterate over gmem_files for a mapping/inode Sean Christopherson
2025-10-08 5:30 ` Garg, Shivank
2025-10-09 21:27 ` Ackerley Tng
2025-10-07 22:14 ` [PATCH v12 03/12] KVM: guest_memfd: Use guest mem inodes instead of anonymous inodes Sean Christopherson
2025-10-07 22:14 ` [PATCH v12 04/12] KVM: guest_memfd: Add slab-allocated inode cache Sean Christopherson
2025-10-09 21:39 ` Ackerley Tng
2025-10-09 22:16 ` Ackerley Tng
2025-10-07 22:14 ` [PATCH v12 05/12] KVM: guest_memfd: Enforce NUMA mempolicy using shared policy Sean Christopherson
2025-10-09 22:15 ` Ackerley Tng
2025-10-10 7:57 ` Garg, Shivank
2025-10-10 20:33 ` Sean Christopherson
2025-10-10 21:57 ` Ackerley Tng
2025-10-12 20:00 ` Garg, Shivank
2025-10-15 16:56 ` Sean Christopherson
2025-10-07 22:14 ` [PATCH v12 06/12] KVM: selftests: Define wrappers for common syscalls to assert success Sean Christopherson
2025-10-09 21:44 ` Ackerley Tng
2025-10-07 22:14 ` [PATCH v12 07/12] KVM: selftests: Report stacktraces SIGBUS, SIGSEGV, SIGILL, and SIGFPE by default Sean Christopherson
2025-10-09 22:31 ` Ackerley Tng
2025-10-07 22:14 ` [PATCH v12 08/12] KVM: selftests: Add additional equivalents to libnuma APIs in KVM's numaif.h Sean Christopherson
2025-10-09 22:34 ` Ackerley Tng
2025-10-07 22:14 ` [PATCH v12 09/12] KVM: selftests: Use proper uAPI headers to pick up mempolicy.h definitions Sean Christopherson
2025-10-10 17:59 ` Ackerley Tng
2025-10-07 22:14 ` [PATCH v12 10/12] KVM: selftests: Add helpers to probe for NUMA support, and multi-node systems Sean Christopherson
2025-10-07 22:14 ` [PATCH v12 11/12] KVM: selftests: Add guest_memfd tests for mmap and NUMA policy support Sean Christopherson
2025-10-09 23:08 ` Ackerley Tng
2025-10-07 22:14 ` [PATCH v12 12/12] KVM: guest_memfd: Add gmem_inode.flags field instead of using i_private Sean Christopherson
2025-10-09 20:58 ` Ackerley Tng [this message]
2025-10-10 4:59 ` [PATCH v12 00/12] KVM: guest_memfd: Add NUMA mempolicy support Garg, Shivank
2025-10-10 17:56 ` Ackerley Tng
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=diqz5xcniyhb.fsf@google.com \
--to=ackerleytng@google.com \
--cc=ashish.kalra@amd.com \
--cc=david@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=kvmarm@lists.linux.dev \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maz@kernel.org \
--cc=oliver.upton@linux.dev \
--cc=pbonzini@redhat.com \
--cc=seanjc@google.com \
--cc=shivankg@amd.com \
--cc=tabba@google.com \
--cc=vbabka@suse.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.