[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] PCI/MSI: don't disable AMD IOMMU MSI on Xen dom0



On 06/21/2012 02:45 PM, Jan Beulich wrote:
On 21.06.12 at 14:28, Wei Wang<wei.wang2@xxxxxxx>  wrote:
On 06/21/2012 02:06 PM, Jan Beulich wrote:
On 21.06.12 at 13:21, Wei Wang<wei.wang2@xxxxxxx>   wrote:
I also evaluated the possibility of hiding iommu device from dom0. I
think the change is no quite a lot, at least, for io based pcicfg
access. A proof-of-concept patch is attached.
This completely hides the device from Dom0, but only when
config space is accessed via method 1. Did you not see my
earlier patch doing this for MCFG as well
Could you please provide a particular c/s number?... (I saw too many c/s
might be related to this topic). so that I could work out a patch to
support both i/o and mmcfg.
I sent this to you yesterday, so you'd be able to test whether
it actually fulfills its purpose before we discuss whether this is
acceptable for 4.2. See
http://lists.xen.org/archives/html/xen-devel/2012-06/msg01129.html
Oh, yes I found it, my email filter did not work well so I did not see 
it at the right folder. I will test right now.
(albeit only disallowing
writes, so allowing the device to still be seen by Dom0)?
Sounds better to me...this still allows user to check iommu status from
lspci.

Whether completely hiding the device is actually okay I can't
easily tell: Would IOMMUs always be either at func 0 of a single-
unction device, or at a non-zero func of a multi-function one? If
not, other devices may get hidden implicitly.
AMD IOMMU is an independent pci-e endpoint, and this function will not
be used for other purposes other than containing an iommu. So I don't
see that iommu will share bdf value with other devices.
The question is not regarding bdf, but regarding whether under
the same seg:bus:dev there might be multiple functions, one of
which is the IOMMU, and if so, whether the IOMMU would be
guaranteed to have a non-zero function number.
In a real system (single or multiple iommu), amd iommu shares the same 
device number with north bridge but has function number 2.. (e.g 
bus:00.2) Howerver according to spec, it does not guaranteed to have 
non-zero function number. So what is the problem you see if iommu uses 
fun0 on a multi-func device?
Thanks,
Wei

Jan




_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.