* [PATCH 1/2] powerpc/eeh: Fix crash in eeh_add_device_early() on Cell
@ 2015-04-14 6:49 Michael Ellerman
2015-04-14 6:49 ` [PATCH 2/2] powerpc/cell: Fix iommu breakage caused by controller_ops change Michael Ellerman
0 siblings, 1 reply; 3+ messages in thread
From: Michael Ellerman @ 2015-04-14 6:49 UTC (permalink / raw)
To: linuxppc-dev; +Cc: gwshan, dja
The recent change to the EEH probing causes a crash on Cell because
eeh_ops is NULL.
Check if EEH is enabled and if not bail out.
Fixes: ff57b454ddb9 ("powerpc/eeh: Do probe on pci_dn")
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
---
arch/powerpc/kernel/eeh.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/powerpc/kernel/eeh.c b/arch/powerpc/kernel/eeh.c
index 76253eb146be..a4c62eb0ee48 100644
--- a/arch/powerpc/kernel/eeh.c
+++ b/arch/powerpc/kernel/eeh.c
@@ -1053,7 +1053,7 @@ void eeh_add_device_early(struct pci_dn *pdn)
struct pci_controller *phb;
struct eeh_dev *edev = pdn_to_eeh_dev(pdn);
- if (!edev)
+ if (!edev || !eeh_enabled())
return;
/* USB Bus children of PCI devices will not have BUID's */
--
2.1.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2] powerpc/cell: Fix iommu breakage caused by controller_ops change
2015-04-14 6:49 [PATCH 1/2] powerpc/eeh: Fix crash in eeh_add_device_early() on Cell Michael Ellerman
@ 2015-04-14 6:49 ` Michael Ellerman
2015-04-14 22:46 ` Daniel Axtens
0 siblings, 1 reply; 3+ messages in thread
From: Michael Ellerman @ 2015-04-14 6:49 UTC (permalink / raw)
To: linuxppc-dev; +Cc: gwshan, dja
The recent patch to convert cell to use pci_controller_ops had a small
bug which broke machines using an iommu.
The set of phb->controller_ops was added after the check for name !=
"pci", meaning pcix/pcie PHBs weren't getting their ops set correctly.
Fixes: 9c1368fc50e7 ("powerpc/cell: Move controller ops from ppc_md to controller_ops")
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
---
arch/powerpc/platforms/cell/setup.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/powerpc/platforms/cell/setup.c b/arch/powerpc/platforms/cell/setup.c
index d1be268b1e6e..36cff28d0293 100644
--- a/arch/powerpc/platforms/cell/setup.c
+++ b/arch/powerpc/platforms/cell/setup.c
@@ -127,13 +127,13 @@ static int cell_setup_phb(struct pci_controller *phb)
if (rc)
return rc;
+ phb->controller_ops = cell_pci_controller_ops;
+
np = phb->dn;
model = of_get_property(np, "model", NULL);
if (model == NULL || strcmp(np->name, "pci"))
return 0;
- phb->controller_ops = cell_pci_controller_ops;
-
/* Setup workarounds for spider */
if (strcmp(model, "Spider"))
return 0;
--
2.1.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 2/2] powerpc/cell: Fix iommu breakage caused by controller_ops change
2015-04-14 6:49 ` [PATCH 2/2] powerpc/cell: Fix iommu breakage caused by controller_ops change Michael Ellerman
@ 2015-04-14 22:46 ` Daniel Axtens
0 siblings, 0 replies; 3+ messages in thread
From: Daniel Axtens @ 2015-04-14 22:46 UTC (permalink / raw)
To: Michael Ellerman; +Cc: linuxppc-dev, gwshan
[-- Attachment #1: Type: text/plain, Size: 574 bytes --]
On Tue, 2015-04-14 at 16:49 +1000, Michael Ellerman wrote:
> The recent patch to convert cell to use pci_controller_ops had a small
> bug which broke machines using an iommu.
>
Oops.
> The set of phb->controller_ops was added after the check for name !=
> "pci", meaning pcix/pcie PHBs weren't getting their ops set correctly.
>
> Fixes: 9c1368fc50e7 ("powerpc/cell: Move controller ops from ppc_md to controller_ops")
> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Thanks for that.
Acked-by: Daniel Axtens <dja@axtens.net>
Regards,
Daniel
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 860 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-04-14 22:46 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-14 6:49 [PATCH 1/2] powerpc/eeh: Fix crash in eeh_add_device_early() on Cell Michael Ellerman
2015-04-14 6:49 ` [PATCH 2/2] powerpc/cell: Fix iommu breakage caused by controller_ops change Michael Ellerman
2015-04-14 22:46 ` Daniel Axtens
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).