[PATCH v1 0/3] udmabuf: Add support for page migration out of movable zone or CMA
David Hildenbrand
david at redhat.com
Thu Sep 14 13:43:44 UTC 2023
>> I think it makes sense to have a generic (non-GUP) version of
>> check_and_migrate_movable_pages() available in migration.h that
>> drivers can use to ensure that they don't break memory hotunplug
>> accidentally.
>
> Definately not.
>
> Either use the VMA and pin_user_pages(), or implement
> pin_user_pages_fd() in core code.
>
> Do not open code something wonky in drivers.
Agreed. pin_user_pages_fd() might become relevant in the context of
vfio/mdev + KVM gmem -- don't mmap guest memory but instead provide it
via a special memfd to the kernel.
So there might be value in having such a core infrastructure.
--
Cheers,
David / dhildenb
More information about the dri-devel
mailing list