From: Alex Williamson <alex.williamson@redhat.com>
To: Fred Gao <fred.gao@intel.com>
Cc: Hang Yuan <hang.yuan@linux.intel.com>,
kvm@vger.kernel.org, intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH v3] vfio/pci: Bypass IGD init in case of -ENODEV
Date: Tue, 3 Nov 2020 11:21:43 -0700 [thread overview]
Message-ID: <20201103112143.07682d41@w520.home> (raw)
In-Reply-To: <20201102180120.25319-1-fred.gao@intel.com>
On Tue, 3 Nov 2020 02:01:20 +0800
Fred Gao <fred.gao@intel.com> wrote:
> 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@linux.intel.com>
> Cc: Xiong Zhang <xiong.y.zhang@intel.com>
> Cc: Hang Yuan <hang.yuan@linux.intel.com>
> Cc: Stuart Summers <stuart.summers@intel.com>
> Signed-off-by: Fred Gao <fred.gao@intel.com>
> ---
> drivers/vfio/pci/vfio_pci.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Applied to vfio for-linus branch for v5.10. Thanks,
Alex
>
> diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
> index f634c81998bb..c88cf9937469 100644
> --- a/drivers/vfio/pci/vfio_pci.c
> +++ b/drivers/vfio/pci/vfio_pci.c
> @@ -341,7 +341,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;
> }
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
prev parent reply other threads:[~2020-11-03 18:21 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-29 16:10 [Intel-gfx] [PATCH v2] vfio/pci: Refine Intel IGD OpRegion support Fred Gao
2020-09-29 8:49 ` Zhenyu Wang
2020-09-29 19:19 ` [Intel-gfx] ✓ Fi.CI.IGT: success for vfio/pci: Refine Intel IGD OpRegion support (rev2) Patchwork
2020-09-29 22:06 ` [Intel-gfx] [PATCH v2] vfio/pci: Refine Intel IGD OpRegion support Alex Williamson
2020-11-02 11:48 ` [Intel-gfx] ✓ Fi.CI.BAT: success for vfio/pci: Refine Intel IGD OpRegion support (rev3) Patchwork
2020-11-02 16:13 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2020-11-02 18:01 ` [Intel-gfx] [PATCH v3] vfio/pci: Bypass IGD init in case of -ENODEV Fred Gao
2020-11-03 18:21 ` Alex Williamson [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20201103112143.07682d41@w520.home \
--to=alex.williamson@redhat.com \
--cc=fred.gao@intel.com \
--cc=hang.yuan@linux.intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=kvm@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox