<div>I have run in to a few problems with IGD passthrough with a linux guest. I am not running in legacy mode, so I guess that I might not be supported.</div><div> </div><div>The first thing that I noticed was on some intel machines, when the VFIO IOMMU module was loaded from qemu I was getting a whole lot of DMAR faults. The address I found was the same as the one that was being set by the kernel here:</div><div> </div><div><div>Jun 23 10:21:35 phys kernel: DMAR: Setting RMRR:<div>Jun 23 10:21:35 phys kernel: DMAR: Setting identity map for device 0000:00:02.0 [0xcb000000 - 0xcf1fffff]</div></div><div> </div><div>This happened on two machines at different memory locations. I was able to fix this by hardcoding an entry thus:</div><div><div>diff --git a/drivers/vfio/vfio_iommu_type1.c b/drivers/vfio/vfio_iommu_type1.c</div><div>index a8a079ba9477..3c0f134c1669 100644</div><div>--- a/drivers/vfio/vfio_iommu_type1.c</div><div>+++ b/drivers/vfio/vfio_iommu_type1.c</div><div>@@ -1270,6 +1270,8 @@ static int vfio_iommu_type1_attach_group(void *iommu_data,</div><div>                        goto out_domain;</div><div>        }</div><div> </div><div>+       ret = iommu_map(domain->domain, 0xcb000000u,0xcb000000u , 0x4200000u,  IOMMU_READ | IOMMU_WRITE);</div><div> </div><div>and the machine because usable again. As this fixed my problem, I didn't bother checking what RMRR does, but should this be handled or should entries that doesn't apepar in the PCI configation space not be remove from the DMAR?</div><div> </div><div>Anyhow, I tried to get the OpRegion working, adding an x-idg-opregion and overrring the VGA check in the vfio kernel module. But I noticed in the VM the OpRegion ins't mapped:</div><div> </div><div>On the guest the region FC is zero whereas it contains a 32bit address from the host:</div><div><div>lspci -xxxx -s 00:2</div><div>00:02.0 Display controller: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor Integrated Graphics Controller (rev 06)</div><div>00: 86 80 12 04 07 04 90 00 06 00 80 03 00 00 80 00</div><div>....</div><div>f0: 00 00 00 00 00 00 00 00 00 00 06 00 00 00 00 00</div><div> </div><div> lspci -xxxx -s 00:2</div><div>00:02.0 Display controller: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor Integrated Graphics Controller (rev 06)</div><div>00: 86 80 12 04 07 04 90 00 06 00 80 03 00 00 00 00</div><div>...</div><div>f0: 00 00 00 00 00 00 00 00 00 00 06 00 18 c0 d5 c8</div><div> </div><div>How is the OpRegion mapped in the guest?</div><div> </div><div>Cheers</div><div> </div><div>JT</div></div></div></div>