Fred Griffoul <[email protected]> writes:

> From: Fred Griffoul <[email protected]>
>
> Some drivers manage RAM outside the page allocator: a carve-out, device
> memory, or memory that a host component moves between VMs while they
> run. This memory often has no struct page. The driver wants to lend
> pages to a VM and to its devices, and to take any of them back later.
>
> David Woodhouse's series "KVM: Allow alternative providers of
> guest_memfd backed by PFNMAP memory" lets such a driver back a
> guest_memfd through struct kvm_gmem_ops:
>
>   https://lore.kernel.org/kvm/[email protected]/
>
> That covers the guest, but not the VM's devices, which his cover
> letter left as an open question. This series adds a small interface in
> mm: the driver that owns the memory becomes a provider, and the code
> that maps it attaches as a consumer. There are two consumers, a
> guest_memfd backend and IOMMU_IOAS_MAP_FILE in iommufd.
>
> The series is on top of David's v2 (base 0e35b9b6ec0f). Patch 1 was
> part of the earlier dma-buf RFC. The provider backend depends on it, so
> this series carries it.
>


I have been working on something similar for confidential computing use
cases. There is likely some overlap between this series and what I posted
at [1].

I have not reviewed this series in detail yet, but I will compare the two
approaches and identify what can be shared between the use cases. Please
let me know how you would like to proceed.

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

-aneesh

Reply via email to