diff options
-rw-r--r-- | xen/drivers/passthrough/vtd/intremap.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/xen/drivers/passthrough/vtd/intremap.c b/xen/drivers/passthrough/vtd/intremap.c index 6dc058445e..0fcc775e3e 100644 --- a/xen/drivers/passthrough/vtd/intremap.c +++ b/xen/drivers/passthrough/vtd/intremap.c @@ -752,15 +752,19 @@ int enable_intremap(struct iommu *iommu, int eim) if ( (sts & DMA_GSTS_IRES) && ir_ctrl->iremap_maddr ) return 0; - sts = dmar_readl(iommu->reg, DMAR_GSTS_REG); if ( !(sts & DMA_GSTS_QIES) ) { - dprintk(XENLOG_ERR VTDPREFIX, - "Queued invalidation is not enabled, should not enable " - "interrupt remapping\n"); + printk(XENLOG_ERR VTDPREFIX + " Queued invalidation is not enabled on IOMMU #%u:" + " Should not enable interrupt remapping\n", iommu->index); return -EINVAL; } + if ( !eim && (sts & DMA_GSTS_CFIS) ) + printk(XENLOG_WARNING VTDPREFIX + " Compatibility Format Interrupts permitted on IOMMU #%u:" + " Device pass-through will be insecure\n", iommu->index); + if ( ir_ctrl->iremap_maddr == 0 ) { drhd = iommu_to_drhd(iommu); |