> From: Nicolin Chen <nicol...@nvidia.com>
> Sent: Friday, May 9, 2025 11:03 AM
> 
> The new HW QUEUE object will be added for HW to access the guest queue
> for
> HW-accelerated virtualization feature. It needs to ensure the guest memory
> pages are pinned when HW accesses them and they are contiguous in
> physical
> address space.

'pin' is the generic requirement but contiguity is vendor specific. Let's
make it clear.

> 
> This is very like the existing iommufd_access_pin_pages() that outputs the
> pinned page list for the caller to test its contiguity.
> 
> Move those code from iommufd_access_pin/unpin_pages() and related
> function
> for a pair of iopt helpers that can be shared with the HW QUEUE allocator.
> 
> Rename check_area_prot() to align with the existing iopt_area helpers, and
> inline it to the header since iommufd_access_rw() still uses it.
> 
> Reviewed-by: Pranjal Shrivastava <pr...@google.com>
> Signed-off-by: Nicolin Chen <nicol...@nvidia.com>

Reviewed-by: Kevin Tian <kevin.t...@intel.com>

Reply via email to