lkml.org 
[lkml]   [2020]   [Apr]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [RFC PATCH 0/4] mm: Add PG_zero support
From
Date
On 4/13/20 7:49 AM, Alex Williamson wrote:
>> VFIO's unconditional page pinning is the real problem here IMNHO. They
>> don't *really* need to pin the memory. We just don't have good
>> paravirtualized IOMMU support or want to pay the runtime cost for
>> pin/unpin operations. You *could* totally have speedy VM startup if
>> only the pages being accessed or having DMA performed to them were
>> allocated. But, the hacks that are in place mean that everything must
>> be pinned.
> Maybe in an SEV or Secure Boot environment we can assume the VM guest
> OS uses the IOMMU exclusively for DMA, but otherwise the IOMMU is
> optional (at least for x86, other archs do require IOMMU support
> afaik). Therefore, how would we know which pages to pin when there are
> only limited configs where we might be able to lean on the vIOMMU to
> this extent? Thanks,

You can delay pinning until the device is actually used. That should be
late enough for the host to figure out whether a paravirtualized IOMMU
is in place.

\
 
 \ /
  Last update: 2020-04-13 17:15    [W:0.050 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site