|
| From: | Xiaoyao Li |
| Subject: | Re: [PATCH v3 03/70] RAMBlock/guest_memfd: Enable KVM_GUEST_MEMFD_ALLOW_HUGEPAGE |
| Date: | Thu, 30 Nov 2023 15:32:08 +0800 |
| User-agent: | Mozilla Thunderbird |
On 11/20/2023 5:26 PM, David Hildenbrand wrote:
... did you shamelessly copy that from hw/virtio/virtio-mem.c ? ;)Get caught.This should be factored out into a common helper.Sure, will do it in next version.Factor it out in a separate patch. Then, this patch is get small that you can just squash it into #2.And my comment regarding "flags = 0" to patch #2 does no longer apply :)
I see.But it depends on if KVM_GUEST_MEMFD_ALLOW_HUGEPAGE will appear together with initial guest memfd in linux (hopefully 6.8)
https://lore.kernel.org/all/CABgObfa=DH7FySBviF63OS9sVog_wt-AqYgtUAGKqnY5Bizivw@mail.gmail.com/If like Paolo committed, no KVM_GUEST_MEMFD_ALLOW_HUGEPAGE in initial merge, I will go simplify Patch #2. Otherwise factor out a common function to get hugepage size as you suggested.
Thanks!
| [Prev in Thread] | Current Thread | [Next in Thread] |