This is a note to let you know that I've just added the patch titled vfio/pci: Bypass IGD init in case of -ENODEV to the 5.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: vfio-pci-bypass-igd-init-in-case-of-enodev.patch and it can be found in the queue-5.4 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. commit c27f30ef965fffd06e517f10d2b00ea2d8f27a9a Author: Fred Gao <fred.gao@xxxxxxxxx> Date: Tue Nov 3 02:01:20 2020 +0800 vfio/pci: Bypass IGD init in case of -ENODEV [ Upstream commit e4eccb853664de7bcf9518fb658f35e748bf1f68 ] Bypass the IGD initialization when -ENODEV returns, that should be the case if opregion is not available for IGD or within discrete graphics device's option ROM, or host/lpc bridge is not found. Then use of -ENODEV here means no special device resources found which needs special care for VFIO, but we still allow other normal device resource access. Cc: Zhenyu Wang <zhenyuw@xxxxxxxxxxxxxxx> Cc: Xiong Zhang <xiong.y.zhang@xxxxxxxxx> Cc: Hang Yuan <hang.yuan@xxxxxxxxxxxxxxx> Cc: Stuart Summers <stuart.summers@xxxxxxxxx> Signed-off-by: Fred Gao <fred.gao@xxxxxxxxx> Signed-off-by: Alex Williamson <alex.williamson@xxxxxxxxxx> Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c index a72fd5309b09f..443a35dde7f52 100644 --- a/drivers/vfio/pci/vfio_pci.c +++ b/drivers/vfio/pci/vfio_pci.c @@ -334,7 +334,7 @@ static int vfio_pci_enable(struct vfio_pci_device *vdev) pdev->vendor == PCI_VENDOR_ID_INTEL && IS_ENABLED(CONFIG_VFIO_PCI_IGD)) { ret = vfio_pci_igd_init(vdev); - if (ret) { + if (ret && ret != -ENODEV) { pci_warn(pdev, "Failed to setup Intel IGD regions\n"); goto disable_exit; }