[OpenWrt-Devel] kirkwood: define ethernet aliases in the device tree
diff mbox

Message ID BLU436-SMTP67EE2EB064A18305691DCCAC370@phx.gbl
State Changes Requested
Delegated to: Luka Perkov
Headers show

Commit Message

Nathan Hintz Jan. 24, 2015, 4:59 a.m. UTC
The aliases are needed for u-boot to update the ethernet mac addresses
using the values from the u-boot environment.

Signed-off-by: Nathan Hintz <nlhintz@hotmail.com>
---
 .../patches-3.14/180-kirkwood-ethernetn.patch      | 33 ++++++++++++++++++++++
 .../patches-3.18/180-kirkwood-ethernetn.patch      | 17 +++++++++++
 2 files changed, 50 insertions(+)
 create mode 100644 target/linux/kirkwood/patches-3.14/180-kirkwood-ethernetn.patch
 create mode 100644 target/linux/kirkwood/patches-3.18/180-kirkwood-ethernetn.patch

Patch
diff mbox

diff --git a/target/linux/kirkwood/patches-3.14/180-kirkwood-ethernetn.patch b/target/linux/kirkwood/patches-3.14/180-kirkwood-ethernetn.patch
new file mode 100644
index 0000000..137fc98
--- /dev/null
+++ b/target/linux/kirkwood/patches-3.14/180-kirkwood-ethernetn.patch
@@ -0,0 +1,33 @@ 
+--- a/arch/arm/boot/dts/kirkwood.dtsi
++++ b/arch/arm/boot/dts/kirkwood.dtsi
+@@ -22,8 +22,10 @@
+ 	};
+ 
+ 	aliases {
+-	       gpio0 = &gpio0;
+-	       gpio1 = &gpio1;
++		gpio0 = &gpio0;
++		gpio1 = &gpio1;
++		ethernet0 = &eth0port;
++		ethernet1 = &eth1port;
+ 	};
+ 
+ 	mbus {
+@@ -242,7 +244,7 @@
+ 			marvell,tx-checksum-limit = <1600>;
+ 			status = "disabled";
+ 
+-			ethernet0-port@0 {
++			eth0port: ethernet0-port@0 {
+ 				compatible = "marvell,kirkwood-eth-port";
+ 				reg = <0>;
+ 				interrupts = <11>;
+@@ -273,7 +275,7 @@
+ 			marvell,tx-checksum-limit = <1600>;
+ 			status = "disabled";
+ 
+-			ethernet1-port@0 {
++			eth1port: ethernet1-port@0 {
+ 				compatible = "marvell,kirkwood-eth-port";
+ 				reg = <0>;
+ 				interrupts = <15>;
diff --git a/target/linux/kirkwood/patches-3.18/180-kirkwood-ethernetn.patch b/target/linux/kirkwood/patches-3.18/180-kirkwood-ethernetn.patch
new file mode 100644
index 0000000..93608c4
--- /dev/null
+++ b/target/linux/kirkwood/patches-3.18/180-kirkwood-ethernetn.patch
@@ -0,0 +1,17 @@ 
+--- a/arch/arm/boot/dts/kirkwood.dtsi
++++ b/arch/arm/boot/dts/kirkwood.dtsi
+@@ -22,9 +22,11 @@
+ 	};
+ 
+ 	aliases {
+-	       gpio0 = &gpio0;
+-	       gpio1 = &gpio1;
+-	       i2c0 = &i2c0;
++		gpio0 = &gpio0;
++		gpio1 = &gpio1;
++		i2c0 = &i2c0;
++		ethernet0 = &eth0port;
++		ethernet1 = &eth1port;
+ 	};
+ 
+ 	mbus {