aboutsummaryrefslogtreecommitdiffstats
path: root/xen
diff options
context:
space:
mode:
authorJan Beulich <jbeulich@suse.com>2013-01-07 12:56:52 +0100
committerJan Beulich <jbeulich@suse.com>2013-01-07 12:56:52 +0100
commitc9af51eb96319f8248ababea592282bc6215fc30 (patch)
tree50fdb9b72d194769311b854a7c41bdfbfad63d09 /xen
parent4e9950dc1bd23d0eb61f25c5355318bfdd33657e (diff)
downloadxen-c9af51eb96319f8248ababea592282bc6215fc30.tar.gz
xen-c9af51eb96319f8248ababea592282bc6215fc30.tar.bz2
xen-c9af51eb96319f8248ababea592282bc6215fc30.zip
VT-d: relax source qualifier for MSI of phantom functions
With ordinary requests allowed to come from phantom functions, the remapping tables ought to be set up to allow for MSI triggers to come from other than the "real" device too. Signed-off-by: Jan Beulich <jbeulich@suse.com> Acked-by: "Zhang, Xiantao" <xiantao.zhang@intel.com>
Diffstat (limited to 'xen')
-rw-r--r--xen/drivers/passthrough/vtd/intremap.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/xen/drivers/passthrough/vtd/intremap.c b/xen/drivers/passthrough/vtd/intremap.c
index aaf9301896..8b45e5ae8b 100644
--- a/xen/drivers/passthrough/vtd/intremap.c
+++ b/xen/drivers/passthrough/vtd/intremap.c
@@ -442,13 +442,22 @@ static void set_msi_source_id(struct pci_dev *pdev, struct iremap_entry *ire)
devfn = pdev->devfn;
switch ( pdev->type )
{
+ unsigned int sq;
+
case DEV_TYPE_PCIe_BRIDGE:
case DEV_TYPE_PCIe2PCI_BRIDGE:
case DEV_TYPE_LEGACY_PCI_BRIDGE:
break;
case DEV_TYPE_PCIe_ENDPOINT:
- set_ire_sid(ire, SVT_VERIFY_SID_SQ, SQ_ALL_16, PCI_BDF2(bus, devfn));
+ switch ( pdev->phantom_stride )
+ {
+ case 1: sq = SQ_13_IGNORE_3; break;
+ case 2: sq = SQ_13_IGNORE_2; break;
+ case 4: sq = SQ_13_IGNORE_1; break;
+ default: sq = SQ_ALL_16; break;
+ }
+ set_ire_sid(ire, SVT_VERIFY_SID_SQ, sq, PCI_BDF2(bus, devfn));
break;
case DEV_TYPE_PCI: