From: Alexey Kardashevskiy <aik@ozlabs.ru>
To: linuxppc-dev@lists.ozlabs.org
Cc: Alexey Kardashevskiy <aik@ozlabs.ru>,
Alex Williamson <alex.williamson@redhat.com>,
Gavin Shan <gwshan@linux.vnet.ibm.com>,
kvm@vger.kernel.org
Subject: [PATCH v2 4/4] vfio_pci: spapr: Enable VFIO if EEH is not supported
Date: Wed, 6 Aug 2014 12:48:33 +1000 [thread overview]
Message-ID: <1407293313-24894-5-git-send-email-aik@ozlabs.ru> (raw)
In-Reply-To: <1407293313-24894-1-git-send-email-aik@ozlabs.ru>
The existing vfio_pci_open() fails if there is no EEH support for PCI.
This breaks POWER7's P5IOC2 PHB support which this patch brings back.
It is a warning because this should not normally happen on supported
configurations such as POWER8+IODA so we always want to see it in dmesg.
It is _once() as the message may be triggered by non-privileged userspace
and we do not want to pollute dmesg.
Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
---
Changes:
v2:
* discussed with Ben Herrenschmidt and did s/pr_warn/pr_warn_once/
* updated commit log
---
drivers/vfio/pci/vfio_pci.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c
index e2ee80f..68dc8da 100644
--- a/drivers/vfio/pci/vfio_pci.c
+++ b/drivers/vfio/pci/vfio_pci.c
@@ -179,10 +179,8 @@ static int vfio_pci_open(void *device_data)
goto error;
ret = vfio_spapr_pci_eeh_open(vdev->pdev);
- if (ret) {
- vfio_pci_disable(vdev);
- goto error;
- }
+ if (ret)
+ pr_warn_once("EEH is not supported\n");
}
return 0;
--
2.0.0
next prev parent reply other threads:[~2014-08-06 2:49 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-06 2:48 [PATCH v2 0/4] vfio: eeh: spapr: Compile and compatibility fixes Alexey Kardashevskiy
2014-08-06 2:48 ` [PATCH v2 1/4] powerpc/eeh: Export eeh_iommu_group_to_pe() Alexey Kardashevskiy
2014-08-06 2:48 ` [PATCH v2 2/4] vfio: spapr: Fix build error Alexey Kardashevskiy
2014-08-06 3:12 ` Alex Williamson
2014-08-06 3:54 ` Gavin Shan
2014-08-06 6:33 ` Alexey Kardashevskiy
2014-08-06 6:57 ` Gavin Shan
2014-08-06 2:48 ` [PATCH v2 3/4] vfio_spapr_eeh: Enable compile as a module Alexey Kardashevskiy
2014-08-06 2:48 ` Alexey Kardashevskiy [this message]
2014-08-06 3:44 ` [PATCH v2 4/4] vfio_pci: spapr: Enable VFIO if EEH is not supported Alex Williamson
2014-08-06 4:34 ` Benjamin Herrenschmidt
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=1407293313-24894-5-git-send-email-aik@ozlabs.ru \
--to=aik@ozlabs.ru \
--cc=alex.williamson@redhat.com \
--cc=gwshan@linux.vnet.ibm.com \
--cc=kvm@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.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;
as well as URLs for NNTP newsgroup(s).