powerpc/8313erdb: fix kernel crash
Subsystems (2)
PATCH 1/1 powerpc/8313erdb: fix kernel crash
Probe the new mdio node added by b31a1d8b. Fix kernel panic problem when gianfar driver wants to get the of_platform_device of that mdio.
--- arch/powerpc/boot/dts/mpc8313erdb.dts | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
arch/powerpc/boot/dts/mpc8313erdb.dts +1 -1
@@ -222,7 +222,7 @@ cell-index = <1>; device_type = "network"; model = "eTSEC"; - compatible = "gianfar"; + compatible = "gianfar", "simple-bus"; reg = <0x25000 0x1000>; local-mac-address = [ 00 00 00 00 00 00 ]; interrupts = <34 0x8 33 0x8 32 0x8>;
Signature · 1 line
1.5.4
Quoted 13 lines · Li Yang
Probe the new mdio node added by
b31a1d8b. Fix kernel panic problem when gianfar driver wants to get theof_platform_deviceof that mdio.Signed-off-by Li Yang <[email protected]>---
arch/powerpc/boot/dts/mpc8313erdb.dts| 2 +-1 files changed, 1 insertions(+), 1 deletions(-)arch/powerpc/boot/dts/mpc8313erdb.dts +0
-0
arch/powerpc/boot/dts/mpc8313erdb.dts line 228
Quoted 8 lines
arch/powerpc/boot/dts/mpc8313erdb.dts +1
-1@@ -222,7 +222,7 @@ cell-index = <1>; device_type = "network"; model = "eTSEC"; - compatible = "gianfar"; + compatible = "gianfar", "simple-bus"; reg = <0x25000 0x1000>; local-mac-address = [ 00 00 00 00 00 00 ]; interrupts = <34 0x8 33 0x8 32 0x8>;
This isn't correct at all. Not sure what the panic is but adding "simple-bus" isn't correct.
- k
Quoted 21 lines · Kumar Gala
Quoted 18 lines · Li Yang
Probe the new mdio node added by
b31a1d8b. Fix kernel panic problem when
gianfar driver wants to get theof_platform_deviceof that mdio.Signed-off-by Li Yang <[email protected]>---
arch/powerpc/boot/dts/mpc8313erdb.dts| 2 +-1 files changed, 1 insertions(+), 1 deletions(-)arch/powerpc/ renamed from arch/powerpc/boot/dts/mpc8313erdb.dts +0
-0
boot/dts/mpc8313erdb.dts
index d4df8b6..917d466 100644arch/powerpc/boot/dts/mpc8313erdb.dts +0
-0@@ -222,7 +222,7 @@ cell-index = <1>; device_type = "network"; model = "eTSEC";
Quoted 8 lines
arch/powerpc/boot/dts/mpc8313erdb.dts line 228
Quoted 5 lines
arch/powerpc/boot/dts/mpc8313erdb.dts +1
-1- compatible = "gianfar"; + compatible = "gianfar", "simple-bus"; reg = <0x25000 0x1000>; local-mac-address = [ 00 00 00 00 00 00 ]; interrupts = <34 0x8 33 0x8 32 0x8>;This isn't correct at all. Not sure what the panic is but adding "simple-bus" isn't correct.
It looks like the mdio node got added in the wrong place on 8313erdb, relative to where it went on all other boards -- though if we were to ignore existing practice, it probably does belong under the gianfar node (and not as a freestanding device).
-Scott
Quoted 20 lines
-----Original Message-----
From: Kumar Gala [mailto:[email protected]]=20
Sent: Tuesday, January 06, 2009 12:25 AM
To: Li Yang-R58472
Cc: [email protected]
Subject: Re: [PATCH] powerpc/8313erdb: fix kernel crash =20
=20
On Jan 5, 2009, at 4:47 AM, Li Yang wrote:
=20Quoted 1 line
Probe the new mdio node added by
b31a1d8b. Fix kernel=20panic problem=20
Quoted 1 line
when gianfar driver wants to get the
of_platform_deviceof=20that mdio.
Quoted 6 lines
Signed-off-by Li Yang <[email protected]>---
arch/powerpc/boot/dts/mpc8313erdb.dts| 2 +-1 files changed, 1 insertions(+), 1 deletions(-)
Quoted 16 lines
arch/powerpc/boot/dts/mpc8313erdb.dts line 228
Quoted 13 lines
arch/powerpc/=20 renamed from arch/powerpc/boot/dts/mpc8313erdb.dts +0
-0
boot/dts/mpc8313erdb.dtsindex d4df8b6..917d466 100644arch/powerpc/boot/dts/mpc8313erdb.dts +1
-1@@ -222,7 +222,7 @@ cell-index =3D <1>; device_type =3D "network"; model =3D "eTSEC"; - compatible =3D "gianfar"; + compatible =3D "gianfar", "simple-bus"; reg =3D <0x25000 0x1000>; local-mac-address =3D [ 00 00 00 00 00 00 ]; interrupts =3D <34 0x8 33 0x8 32 0x8>;=20
This isn't correct at all. Not sure what the panic is but=20 adding "simple-bus" isn't correct.
The panic is caused because mdio node associated with this TSEC is not probed. It may be better to have more exception check in the gianfar driver rather than panic directly. Anyway, mdio need to be probed as of_platform_device for it to work correctly with phy driver.
I'm not sure if adding "simple-bus" is the preferred solution. It is being discussed in a separate mail thread.
- Leo
Quoted 31 lines · Scott Wood
Quoted 21 lines · Kumar Gala
Quoted 18 lines · Li Yang
Probe the new mdio node added by
b31a1d8b. Fix kernel panic problem when
gianfar driver wants to get theof_platform_deviceof that mdio.Signed-off-by Li Yang <[email protected]>---
arch/powerpc/boot/dts/mpc8313erdb.dts| 2 +-1 files changed, 1 insertions(+), 1 deletions(-)arch/powerpc/ renamed from arch/powerpc/boot/dts/mpc8313erdb.dts +0
-0
boot/dts/mpc8313erdb.dts
index d4df8b6..917d466 100644arch/powerpc/boot/dts/mpc8313erdb.dts +0
-0@@ -222,7 +222,7 @@ cell-index = <1>; device_type = "network"; model = "eTSEC";Quoted 8 lines
arch/powerpc/boot/dts/mpc8313erdb.dts line 228
Quoted 5 lines
arch/powerpc/boot/dts/mpc8313erdb.dts +1
-1- compatible = "gianfar"; + compatible = "gianfar", "simple-bus"; reg = <0x25000 0x1000>; local-mac-address = [ 00 00 00 00 00 00 ]; interrupts = <34 0x8 33 0x8 32 0x8>;This isn't correct at all. Not sure what the panic is but adding "simple-bus" isn't correct.
Quoted 4 lines
It looks like the mdio node got added in the wrong place on 8313erdb, relative to where it went on all other boards -- though if we were to ignore existing practice, it probably does belong under the gianfar node (and not as a freestanding device).
Is there any reason that we can't change the 8313 dts to make the mdio standalone like all the other .dts? (not sure if there is some pwr mgmt impact)
- k