Thread (4 messages) 4 messages, 3 authors, 2019-04-17

Re: [RFC PATCH] virtio_ring: Use DMA API if guest memory is encrypted

flat view

From: David Gibson <hidden>
Date: 2019-03-25 04:34:37
Also in: linux-iommu, linuxppc-dev, lkml

On Sat, Mar 23, 2019 at 05:01:35PM -0400, Michael S. Tsirkin wrote:
On Thu, Mar 21, 2019 at 09:05:04PM -0300, Thiago Jung Bauermann wrote:
quoted
Michael S. Tsirkin [off-list ref] writes:
[snip]
quoted
quoted
quoted
quoted
Is there any justification to doing that beyond someone putting
out slow code in the past?
The definition of the ACCESS_PLATFORM flag is generic and captures the
notion of memory access restrictions for the device. Unfortunately, on
powerpc pSeries guests it also implies that the IOMMU is turned on
IIUC that's really because on pSeries IOMMU is *always* turned on.
Platform has no way to say what you want it to say
which is bypass the iommu for the specific device.
Yes, that's correct. pSeries guests running on KVM are in a gray area
where theoretically they use an IOMMU but in practice KVM ignores it.
It's unfortunate but it's the reality on the ground today. :-/
Um.. I'm not sure what you mean by this.  As far as I'm concerned
there is always a guest-visible (paravirtualized) IOMMU, and that will
be backed onto the host IOMMU when necessary.

[Actually there is an IOMMU bypass hack that's used by the guest
 firmware, but I don't think we want to expose that]
Well it's not just the reality, virt setups need something that
emulated IOMMUs don't provide. That is not uncommon, e.g.
intel's VTD has a "cache mode" field which AFAIK is only used for virt.
-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help