Skip to contentSkip to conversation

ARM: keystone: enable mdio support

PATCH New Grygorii Strashko 2 participants 7 messages Jul 9, 2014 – Jul 17, 2014

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover ARM: keystone: enable mdio support

Add DT definitions for Keystone 2 MDIO module and Ethernet PHYs for Keystone EVMK2HX evm. And enable MDIO support for Keystone 2 SoCs.

Grygorii Strashko (3):
ARM: dts: keystone: add mdio devices entries
ARM: dts: keystone-evm: add 1g ethernet phys nodes
ARM: keystone_defconfig: enable mdio and marvell eth phys

 arch/arm/boot/dts/k2hk-evm.dts      |   12 ++++++++++++
 arch/arm/boot/dts/keystone.dtsi     |   11 +++++++++++
 arch/arm/configs/keystone_defconfig |    2 ++
 3 files changed, 25 insertions(+)
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 1/3 ARM: dts: keystone: add mdio devices entries

The Keystone 2 has MDIO HW block which are compatible to Davinci SoCs:
See "Gigabit Ethernet (GbE) Switch Subsystem"
See http://www.ti.com/lit/ug/sprugv9d/sprugv9d.pdf

Hence, add corresponding DT entry for Keystone 2.

---
 arch/arm/boot/dts/keystone.dtsi |   11 +++++++++++
 1 file changed, 11 insertions(+)
arch/arm/boot/dts/keystone.dtsi +11 -0
index c1414cb..89256fc 100644
@@ -266,5 +266,16 @@
 			ranges = <0 0 0x30000000 0x10000000
 				  1 0 0x21000A00 0x00000100>;
 		};
+
+		mdio: mdio at 02090300 {
+			compatible	= "ti,keystone-mdio", "ti,davinci_mdio";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			reg		= <0x02090300 0x100>;
+			status = "disabled";
+			clocks = <&clkpa>;
+			clock-names = "fck";
+			bus_freq	= <2500000>;
+		};
 	};
 };
Signature · 1 line
1.7.9.5
#2 lore raw

PATCH 1/3 ARM: dts: keystone: add mdio devices entries

The Keystone 2 has MDIO HW block which are compatible to Davinci SoCs:
See "Gigabit Ethernet (GbE) Switch Subsystem"
See http://www.ti.com/lit/ug/sprugv9d/sprugv9d.pdf

Hence, add corresponding DT entry for Keystone 2.

---
 arch/arm/boot/dts/keystone.dtsi |   11 +++++++++++
 1 file changed, 11 insertions(+)
arch/arm/boot/dts/keystone.dtsi +11 -0
index c1414cb..9e31fe7 100644
@@ -266,5 +266,16 @@
 			ranges = <0 0 0x30000000 0x10000000
 				  1 0 0x21000A00 0x00000100>;
 		};
+
+		mdio: mdio at 02090300 {
+			compatible	= "ti,keystone_mdio", "ti,davinci_mdio";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			reg		= <0x02090300 0x100>;
+			status = "disabled";
+			clocks = <&clkpa>;
+			clock-names = "fck";
+			bus_freq	= <2500000>;
+		};
 	};
 };
Signature · 1 line
1.7.9.5
#3 lore raw

PATCH 1/3 ARM: dts: keystone: add mdio devices entries

Hi Santosh,

Quoted 6 lines · Grygorii Strashko

The Keystone 2 has MDIO HW block which are compatible to Davinci SoCs:
See "Gigabit Ethernet (GbE) Switch Subsystem"
See http://www.ti.com/lit/ug/sprugv9d/sprugv9d.pdf

Hence, add corresponding DT entry for Keystone 2.

This is updated version of patch (missed v2 in subj).

Quoted 28 lines
---
  arch/arm/boot/dts/keystone.dtsi |   11 +++++++++++
  1 file changed, 11 insertions(+)
arch/arm/boot/dts/keystone.dtsi +11 -0
index c1414cb..9e31fe7 100644
@@ -266,5 +266,16 @@
  			ranges = <0 0 0x30000000 0x10000000
  				  1 0 0x21000A00 0x00000100>;
  		};
+
+		mdio: mdio at 02090300 {
+			compatible	= "ti,keystone_mdio", "ti,davinci_mdio";
+			#address-cells = <1>;
+			#size-cells = <0>;
+			reg		= <0x02090300 0x100>;
+			status = "disabled";
+			clocks = <&clkpa>;
+			clock-names = "fck";
+			bus_freq	= <2500000>;
+		};
  	};
  };
#4 lore raw

PATCH 2/3 ARM: dts: keystone-evm: add 1g ethernet phys nodes

In reply to Grygorii Strashko

Keystone EVMK2HX has two 1G Marvell 88E1111 Ethernet PHYs installed, so add corresponding child nodes for 1G MDIO bus and enable it.

For more information see schematics:
http://wfcache.advantech.com/www/support/TI-EVM/download/Schematics/PDF/K2H_K2EVM-HK_SCH_A102_Rev1_0.pdf

---
 arch/arm/boot/dts/k2hk-evm.dts |   12 ++++++++++++
 1 file changed, 12 insertions(+)
arch/arm/boot/dts/k2hk-evm.dts +12 -0
index 1f90cbf..3223cc1 100644
@@ -167,3 +167,15 @@
 		};
 	};
 };
+
+&mdio {
+	ethphy0: ethernet-phy at 0 {
+		compatible = "marvell,88E1111", "ethernet-phy-ieee802.3-c22";
+		reg = <0>;
+	};
+
+	ethphy1: ethernet-phy at 1 {
+		compatible = "marvell,88E1111", "ethernet-phy-ieee802.3-c22";
+		reg = <1>;
+	};
+};
Signature · 1 line
1.7.9.5
#5 lore raw

PATCH 3/3 ARM: keystone_defconfig: enable mdio and marvell eth phys

In reply to Grygorii Strashko

Enable MDIO support for Keystone 2 SoCs and also enable Marvell Ethernet PHYs support for Keystone 2 K2H EVM which has two 1G Marvell 88E1111-B2 PHYs installed.

For more information see:
- http://www.advantech.com/Support/TI-EVM/EVMK2HX.aspx

---
 arch/arm/configs/keystone_defconfig |    2 ++
 1 file changed, 2 insertions(+)
arch/arm/configs/keystone_defconfig +2 -0
index 932ae40..e31e4d8 100644
@@ -194,3 +194,5 @@ CONFIG_LEDS_TRIGGER_ONESHOT=y
 CONFIG_LEDS_TRIGGER_HEARTBEAT=y
 CONFIG_LEDS_TRIGGER_BACKLIGHT=y
 CONFIG_LEDS_TRIGGER_GPIO=y
+CONFIG_TI_DAVINCI_MDIO=y
+CONFIG_MARVELL_PHY=y
Signature · 1 line
1.7.9.5
#6 lore raw

cover ARM: keystone: enable mdio support

In reply to Grygorii Strashko
Quoted 8 lines · Grygorii

Add DT definitions for Keystone 2 MDIO module and Ethernet PHYs for Keystone EVMK2HX evm. And enable MDIO support for Keystone 2 SoCs.

Grygorii Strashko (3):
ARM: dts: keystone: add mdio devices entries
ARM: dts: keystone-evm: add 1g ethernet phys nodes
ARM: keystone_defconfig: enable mdio and marvell eth phys

Series looks good. I will merge it when the driver changes gets merged. Please ping me just in case I forget about it.

Thanks !!

Regards,
Santosh