From: Shiji Yang Date: Sat, 8 Oct 2022 08:06:00 +0000 (+0800) Subject: ath79: move reference clock node to SoC dtsi X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=520c90854ca73eb6c3d8feeda59766c90bdd4144;p=openwrt%2Fstaging%2Fansuel.git ath79: move reference clock node to SoC dtsi AR7161, AR724x, AR9132 and QCA95xx only support fixed frequency external crystal oscillator, so move reference clock node to SoC dtsi files. Signed-off-by: Shiji Yang --- diff --git a/target/linux/ath79/dts/ar7100.dtsi b/target/linux/ath79/dts/ar7100.dtsi index 12ab7e5039..d91ef91ebd 100644 --- a/target/linux/ath79/dts/ar7100.dtsi +++ b/target/linux/ath79/dts/ar7100.dtsi @@ -21,6 +21,13 @@ }; }; + extosc: ref { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-output-names = "ref"; + clock-frequency = <40000000>; + }; + ahb { apb { ddr_ctrl: memory-controller@18000000 { @@ -73,8 +80,8 @@ compatible = "qca,ar7100-pll", "syscon"; reg = <0x18050000 0x20>; + clocks = <&extosc>; clock-names = "ref"; - /* The board must provides the ref clock */ #clock-cells = <1>; clock-output-names = "cpu", "ddr", "ahb"; diff --git a/target/linux/ath79/dts/ar7161_aruba_ap-105.dts b/target/linux/ath79/dts/ar7161_aruba_ap-105.dts index da68ada2c0..949d70ec07 100644 --- a/target/linux/ath79/dts/ar7161_aruba_ap-105.dts +++ b/target/linux/ath79/dts/ar7161_aruba_ap-105.dts @@ -21,13 +21,6 @@ label-mac-device = ð0; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; diff --git a/target/linux/ath79/dts/ar7161_buffalo_wzr-hp-ag300h.dtsi b/target/linux/ath79/dts/ar7161_buffalo_wzr-hp-ag300h.dtsi index 35e083bc61..4fe8d51a00 100644 --- a/target/linux/ath79/dts/ar7161_buffalo_wzr-hp-ag300h.dtsi +++ b/target/linux/ath79/dts/ar7161_buffalo_wzr-hp-ag300h.dtsi @@ -12,13 +12,6 @@ led-upgrade = &led_diag; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; @@ -218,10 +211,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay"; diff --git a/target/linux/ath79/dts/ar7161_dlink_dir-825-b1.dts b/target/linux/ath79/dts/ar7161_dlink_dir-825-b1.dts index b701f15421..fb5ab1adcb 100644 --- a/target/linux/ath79/dts/ar7161_dlink_dir-825-b1.dts +++ b/target/linux/ath79/dts/ar7161_dlink_dir-825-b1.dts @@ -16,13 +16,6 @@ led-upgrade = &led_power_orange; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; @@ -174,10 +167,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay"; diff --git a/target/linux/ath79/dts/ar7161_jjplus_ja76pf2.dts b/target/linux/ath79/dts/ar7161_jjplus_ja76pf2.dts index dca226d262..7f2a118b84 100644 --- a/target/linux/ath79/dts/ar7161_jjplus_ja76pf2.dts +++ b/target/linux/ath79/dts/ar7161_jjplus_ja76pf2.dts @@ -26,13 +26,6 @@ led-upgrade = &led_d2; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - i2c { compatible = "i2c-gpio"; sda-gpios = <&gpio 1 GPIO_ACTIVE_HIGH>; diff --git a/target/linux/ath79/dts/ar7161_meraki_mr16.dts b/target/linux/ath79/dts/ar7161_meraki_mr16.dts index eb27e16e56..7a19da82e3 100644 --- a/target/linux/ath79/dts/ar7161_meraki_mr16.dts +++ b/target/linux/ath79/dts/ar7161_meraki_mr16.dts @@ -16,13 +16,6 @@ led-upgrade = &led_power_orange; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; @@ -100,10 +93,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &mdio0 { status = "okay"; diff --git a/target/linux/ath79/dts/ar7161_netgear_wndap360.dts b/target/linux/ath79/dts/ar7161_netgear_wndap360.dts index 37a475d3ac..35c5dd36d2 100644 --- a/target/linux/ath79/dts/ar7161_netgear_wndap360.dts +++ b/target/linux/ath79/dts/ar7161_netgear_wndap360.dts @@ -16,13 +16,6 @@ led-upgrade = &led_power_orange; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; diff --git a/target/linux/ath79/dts/ar7161_netgear_wndr.dtsi b/target/linux/ath79/dts/ar7161_netgear_wndr.dtsi index c66348e71e..d3d22b5d2d 100644 --- a/target/linux/ath79/dts/ar7161_netgear_wndr.dtsi +++ b/target/linux/ath79/dts/ar7161_netgear_wndr.dtsi @@ -14,13 +14,6 @@ led-upgrade = &led_power_orange; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - reset-leds { compatible = "reset-leds"; diff --git a/target/linux/ath79/dts/ar7161_siemens_ws-ap3610.dts b/target/linux/ath79/dts/ar7161_siemens_ws-ap3610.dts index 2cdcce0d15..56a2cfab67 100644 --- a/target/linux/ath79/dts/ar7161_siemens_ws-ap3610.dts +++ b/target/linux/ath79/dts/ar7161_siemens_ws-ap3610.dts @@ -17,13 +17,6 @@ label-mac-device = ð0; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; diff --git a/target/linux/ath79/dts/ar7161_trendnet_tew-673gru.dts b/target/linux/ath79/dts/ar7161_trendnet_tew-673gru.dts index 8657e291bd..b6d66a08a5 100644 --- a/target/linux/ath79/dts/ar7161_trendnet_tew-673gru.dts +++ b/target/linux/ath79/dts/ar7161_trendnet_tew-673gru.dts @@ -16,13 +16,6 @@ led-upgrade = &led_wps; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; @@ -112,10 +105,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay"; diff --git a/target/linux/ath79/dts/ar7161_ubnt_routerstation.dtsi b/target/linux/ath79/dts/ar7161_ubnt_routerstation.dtsi index 172b0af1eb..b12723beb2 100644 --- a/target/linux/ath79/dts/ar7161_ubnt_routerstation.dtsi +++ b/target/linux/ath79/dts/ar7161_ubnt_routerstation.dtsi @@ -14,13 +14,6 @@ led-upgrade = &led_rf; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; diff --git a/target/linux/ath79/dts/ar7241_ubnt_unifi.dtsi b/target/linux/ath79/dts/ar7241_ubnt_unifi.dtsi index d05ed080a8..ec8c6381e7 100644 --- a/target/linux/ath79/dts/ar7241_ubnt_unifi.dtsi +++ b/target/linux/ath79/dts/ar7241_ubnt_unifi.dtsi @@ -10,12 +10,6 @@ label-mac-device = ð0; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-frequency = <40000000>; - }; - keys { compatible = "gpio-keys"; @@ -27,10 +21,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &pcie { status = "okay"; diff --git a/target/linux/ath79/dts/ar7242_buffalo_wzr-bhr.dtsi b/target/linux/ath79/dts/ar7242_buffalo_wzr-bhr.dtsi index 18e524f802..e9d1eafe24 100644 --- a/target/linux/ath79/dts/ar7242_buffalo_wzr-bhr.dtsi +++ b/target/linux/ath79/dts/ar7242_buffalo_wzr-bhr.dtsi @@ -12,12 +12,6 @@ led-upgrade = &led_diag; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-frequency = <40000000>; - }; - keys: keys { compatible = "gpio-keys"; @@ -136,10 +130,6 @@ phy-handle = <&phy0>; }; -&pll { - clocks = <&extosc>; -}; - &usb_phy { status = "okay"; }; diff --git a/target/linux/ath79/dts/ar7242_buffalo_wzr-hp-g302h-a1a0.dts b/target/linux/ath79/dts/ar7242_buffalo_wzr-hp-g302h-a1a0.dts index f454725f6a..b8aa2aa210 100644 --- a/target/linux/ath79/dts/ar7242_buffalo_wzr-hp-g302h-a1a0.dts +++ b/target/linux/ath79/dts/ar7242_buffalo_wzr-hp-g302h-a1a0.dts @@ -15,12 +15,6 @@ led-upgrade = &led_diag; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-frequency = <40000000>; - }; - keys { compatible = "gpio-keys"; @@ -211,10 +205,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &usb_phy { status = "okay"; }; diff --git a/target/linux/ath79/dts/ar7242_meraki_mr12.dts b/target/linux/ath79/dts/ar7242_meraki_mr12.dts index 5e82b5bb6b..42b4966e74 100644 --- a/target/linux/ath79/dts/ar7242_meraki_mr12.dts +++ b/target/linux/ath79/dts/ar7242_meraki_mr12.dts @@ -16,13 +16,6 @@ led-upgrade = &led_power_orange; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-output-names = "ref"; - clock-frequency = <40000000>; - }; - leds { compatible = "gpio-leds"; @@ -87,10 +80,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &mdio0 { status = "okay"; diff --git a/target/linux/ath79/dts/ar7242_tplink_tl-wr2543-v1.dts b/target/linux/ath79/dts/ar7242_tplink_tl-wr2543-v1.dts index ae4867521a..b524ea1996 100644 --- a/target/linux/ath79/dts/ar7242_tplink_tl-wr2543-v1.dts +++ b/target/linux/ath79/dts/ar7242_tplink_tl-wr2543-v1.dts @@ -21,12 +21,6 @@ bootargs = "console=ttyS0,115200n8"; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-frequency = <40000000>; - }; - keys { compatible = "gpio-keys"; @@ -95,10 +89,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay"; diff --git a/target/linux/ath79/dts/ar724x.dtsi b/target/linux/ath79/dts/ar724x.dtsi index 882b0bc51a..c090eb5e0f 100644 --- a/target/linux/ath79/dts/ar724x.dtsi +++ b/target/linux/ath79/dts/ar724x.dtsi @@ -24,6 +24,13 @@ }; }; + extosc: ref { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-output-names = "ref"; + clock-frequency = <40000000>; + }; + ahb: ahb { apb { ddr_ctrl: memory-controller@18000000 { @@ -89,8 +96,8 @@ compatible = "qca,ar7240-pll", "syscon"; reg = <0x18050000 0x3c>; + clocks = <&extosc>; clock-names = "ref"; - /* The board must provides the ref clock */ #clock-cells = <1>; clock-output-names = "cpu", "ddr", "ahb"; diff --git a/target/linux/ath79/dts/ar9132.dtsi b/target/linux/ath79/dts/ar9132.dtsi index 44a5870ad7..29891ccebb 100644 --- a/target/linux/ath79/dts/ar9132.dtsi +++ b/target/linux/ath79/dts/ar9132.dtsi @@ -24,6 +24,13 @@ }; }; + extosc: ref { + compatible = "fixed-clock"; + #clock-cells = <0>; + clock-output-names = "ref"; + clock-frequency = <40000000>; + }; + cpuintc: interrupt-controller { compatible = "qca,ar9132-cpu-intc", "qca,ar7100-cpu-intc"; @@ -94,8 +101,8 @@ "qca,ar9130-pll", "syscon"; reg = <0x18050000 0x20>; + clocks = <&extosc>; clock-names = "ref"; - /* The board must provides the ref clock */ #clock-cells = <1>; clock-output-names = "cpu", "ddr", "ahb"; diff --git a/target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi b/target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi index a84e794c0b..f3b13b5d0c 100644 --- a/target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi +++ b/target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi @@ -11,12 +11,6 @@ led-upgrade = &led_diag; }; - clock40mhz: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-frequency = <40000000>; - }; - /* There is a GPIO driven NXP 74HC153 dual 4-way multiplexer on board * used for buttons that are on top of the the device. */ @@ -250,10 +244,6 @@ status = "okay"; }; -&pll { - clocks = <&clock40mhz>; -}; - &usb { status = "okay"; diff --git a/target/linux/ath79/dts/ar9132_tplink_tl-wa901nd-v2.dts b/target/linux/ath79/dts/ar9132_tplink_tl-wa901nd-v2.dts index 354213c440..fd4a6c7a4d 100644 --- a/target/linux/ath79/dts/ar9132_tplink_tl-wa901nd-v2.dts +++ b/target/linux/ath79/dts/ar9132_tplink_tl-wa901nd-v2.dts @@ -17,12 +17,6 @@ label-mac-device = ð0; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-frequency = <40000000>; - }; - keys { compatible = "gpio-keys"; @@ -62,10 +56,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay"; diff --git a/target/linux/ath79/dts/ar9132_tplink_tl-wr1043nd-v1.dts b/target/linux/ath79/dts/ar9132_tplink_tl-wr1043nd-v1.dts index 12e417d3a4..7ff2e4f29b 100644 --- a/target/linux/ath79/dts/ar9132_tplink_tl-wr1043nd-v1.dts +++ b/target/linux/ath79/dts/ar9132_tplink_tl-wr1043nd-v1.dts @@ -17,12 +17,6 @@ label-mac-device = ð0; }; - extosc: ref { - compatible = "fixed-clock"; - #clock-cells = <0>; - clock-frequency = <40000000>; - }; - keys { compatible = "gpio-keys"; @@ -79,10 +73,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &usb { #address-cells = <1>; #size-cells = <0>; diff --git a/target/linux/ath79/dts/qca9558_netgear_ex7300.dtsi b/target/linux/ath79/dts/qca9558_netgear_ex7300.dtsi index 6c5ed4defb..c266c52dad 100644 --- a/target/linux/ath79/dts/qca9558_netgear_ex7300.dtsi +++ b/target/linux/ath79/dts/qca9558_netgear_ex7300.dtsi @@ -120,10 +120,6 @@ status = "okay"; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay"; diff --git a/target/linux/ath79/dts/qca9558_ocedo_koala.dts b/target/linux/ath79/dts/qca9558_ocedo_koala.dts index 66f8c6589b..8441e5c9a3 100644 --- a/target/linux/ath79/dts/qca9558_ocedo_koala.dts +++ b/target/linux/ath79/dts/qca9558_ocedo_koala.dts @@ -59,10 +59,6 @@ status = "okay"; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay"; diff --git a/target/linux/ath79/dts/qca9558_ocedo_ursus.dts b/target/linux/ath79/dts/qca9558_ocedo_ursus.dts index 2dc4c07e91..e99059df04 100644 --- a/target/linux/ath79/dts/qca9558_ocedo_ursus.dts +++ b/target/linux/ath79/dts/qca9558_ocedo_ursus.dts @@ -30,10 +30,6 @@ status = "okay"; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay"; diff --git a/target/linux/ath79/dts/qcn5502_netgear_ex7300-v2.dts b/target/linux/ath79/dts/qcn5502_netgear_ex7300-v2.dts index e5d897029d..4ebbdcc105 100644 --- a/target/linux/ath79/dts/qcn5502_netgear_ex7300-v2.dts +++ b/target/linux/ath79/dts/qcn5502_netgear_ex7300-v2.dts @@ -124,10 +124,6 @@ }; }; -&pll { - clocks = <&extosc>; -}; - &spi { status = "okay";