From 4e5ba5076097cf10865c9d65a6fbe887dba5a467 Mon Sep 17 00:00:00 2001 From: Chuanhong Guo Date: Tue, 17 Jul 2018 17:09:14 +0800 Subject: [PATCH] ath79: ar7240: Update dts for current ag71xx driver Signed-off-by: Chuanhong Guo --- target/linux/ath79/dts/ar7240.dtsi | 24 +++++++++++++++---- .../ath79/dts/ar7240_netgear_wnr612-v2.dtsi | 11 --------- .../linux/ath79/dts/ar7240_tl-wr740n-v2.dts | 11 --------- 3 files changed, 20 insertions(+), 26 deletions(-) diff --git a/target/linux/ath79/dts/ar7240.dtsi b/target/linux/ath79/dts/ar7240.dtsi index 6805d1a786..f662b4b445 100644 --- a/target/linux/ath79/dts/ar7240.dtsi +++ b/target/linux/ath79/dts/ar7240.dtsi @@ -33,7 +33,25 @@ }; &mdio0 { + status = "okay"; + + compatible = "qca,ar7240-mdio"; builtin-switch; + + builtin_switch: switch0@1f { + compatible = "qca,ar8216-builtin"; + #address-cells = <1>; + #size-cells = <0>; + + reg = <0x1f>; + + mdio-bus { + swphy4: ethernet-phy@4 { + reg = <4>; + phy-mode = "mii"; + }; + }; + }; }; ð0 { @@ -43,10 +61,8 @@ resets = <&rst 8>, <&rst 9>; reset-names = "phy", "mac"; -}; - -&mdio1 { - builtin-switch; + phy-mode = "mii"; + phy-handle = <&swphy4>; }; ð1 { diff --git a/target/linux/ath79/dts/ar7240_netgear_wnr612-v2.dtsi b/target/linux/ath79/dts/ar7240_netgear_wnr612-v2.dtsi index 1ae9896aa4..edf209053e 100644 --- a/target/linux/ath79/dts/ar7240_netgear_wnr612-v2.dtsi +++ b/target/linux/ath79/dts/ar7240_netgear_wnr612-v2.dtsi @@ -103,8 +103,6 @@ ð0 { status = "okay"; - phy-handle = <&phy4>; - mtd-mac-address = <&uboot 0x1fc00>; mtd-mac-address-increment = <(-1)>; }; @@ -116,15 +114,6 @@ mtd-mac-address-increment = <1>; }; -&mdio0 { - status = "okay"; - - phy4: ethernet-phy@4 { - reg = <4>; - phy-mode = "mii"; - }; -}; - &pcie { status = "okay"; diff --git a/target/linux/ath79/dts/ar7240_tl-wr740n-v2.dts b/target/linux/ath79/dts/ar7240_tl-wr740n-v2.dts index 5bc78d7eef..8754537754 100644 --- a/target/linux/ath79/dts/ar7240_tl-wr740n-v2.dts +++ b/target/linux/ath79/dts/ar7240_tl-wr740n-v2.dts @@ -123,8 +123,6 @@ ð0 { status = "okay"; - phy-handle = <&phy4>; - mtd-mac-address = <&uboot 0x1fc00>; mtd-mac-address-increment = <(-1)>; }; @@ -136,15 +134,6 @@ mtd-mac-address-increment = <1>; }; -&mdio0 { - status = "okay"; - - phy4: ethernet-phy@4 { - reg = <4>; - phy-mode = "mii"; - }; -}; - &pcie { status = "okay"; -- 2.30.2