]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
arm64: dts: amlogic: g12: switch to the new PWM controller binding
authorMartin Blumenstingl <martin.blumenstingl@googlemail.com>
Fri, 27 Dec 2024 21:25:14 +0000 (22:25 +0100)
committerNeil Armstrong <neil.armstrong@linaro.org>
Fri, 28 Feb 2025 08:16:50 +0000 (09:16 +0100)
Use the new PWM controller binding which now relies on passing all
clock inputs available on the SoC (instead of passing the "wanted"
clock input for a given board).

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>
Link: https://lore.kernel.org/r/20241227212514.1376682-6-martin.blumenstingl@googlemail.com
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
19 files changed:
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi
arch/arm64/boot/dts/amlogic/meson-g12a-fbx8am.dts
arch/arm64/boot/dts/amlogic/meson-g12a-radxa-zero.dts
arch/arm64/boot/dts/amlogic/meson-g12a-sei510.dts
arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts
arch/arm64/boot/dts/amlogic/meson-g12a-x96-max.dts
arch/arm64/boot/dts/amlogic/meson-g12b-a311d-libretech-cc.dts
arch/arm64/boot/dts/amlogic/meson-g12b-bananapi-cm4.dtsi
arch/arm64/boot/dts/amlogic/meson-g12b-bananapi.dtsi
arch/arm64/boot/dts/amlogic/meson-g12b-khadas-vim3.dtsi
arch/arm64/boot/dts/amlogic/meson-g12b-odroid.dtsi
arch/arm64/boot/dts/amlogic/meson-g12b-radxa-zero2.dts
arch/arm64/boot/dts/amlogic/meson-g12b-w400.dtsi
arch/arm64/boot/dts/amlogic/meson-libretech-cottonwood.dtsi
arch/arm64/boot/dts/amlogic/meson-sm1-ac2xx.dtsi
arch/arm64/boot/dts/amlogic/meson-sm1-bananapi.dtsi
arch/arm64/boot/dts/amlogic/meson-sm1-khadas-vim3l.dts
arch/arm64/boot/dts/amlogic/meson-sm1-odroid.dtsi
arch/arm64/boot/dts/amlogic/meson-sm1-sei610.dts

index 49b51c54013f155f78ebe50ea7c13b5a5663afae..ab2b3f15ef19463b0baa17fdee0c0952beca2ca4 100644 (file)
                        };
 
                        pwm_AO_cd: pwm@2000 {
-                               compatible = "amlogic,meson-g12a-ao-pwm-cd";
+                               compatible = "amlogic,meson-g12-pwm-v2",
+                                            "amlogic,meson8-pwm-v2";
                                reg = <0x0 0x2000 0x0 0x20>;
+                               clocks = <&xtal>,
+                                        <&clkc_AO CLKID_AO_CLK81>;
                                #pwm-cells = <3>;
                                status = "disabled";
                        };
                        };
 
                        pwm_AO_ab: pwm@7000 {
-                               compatible = "amlogic,meson-g12a-ao-pwm-ab";
+                               compatible = "amlogic,meson-g12-pwm-v2",
+                                            "amlogic,meson8-pwm-v2";
                                reg = <0x0 0x7000 0x0 0x20>;
+                               clocks = <&xtal>,
+                                        <&clkc_AO CLKID_AO_CLK81>,
+                                        <&clkc CLKID_FCLK_DIV4>,
+                                        <&clkc CLKID_FCLK_DIV5>;
                                #pwm-cells = <3>;
                                status = "disabled";
                        };
                        };
 
                        pwm_ef: pwm@19000 {
-                               compatible = "amlogic,meson-g12a-ee-pwm";
+                               compatible = "amlogic,meson-g12-pwm-v2",
+                                            "amlogic,meson8-pwm-v2";
                                reg = <0x0 0x19000 0x0 0x20>;
+                               clocks = <&xtal>,
+                                        <>, /* unknown/untested, the datasheet calls it "vid_pll" */
+                                        <&clkc CLKID_FCLK_DIV4>,
+                                        <&clkc CLKID_FCLK_DIV3>;
                                #pwm-cells = <3>;
                                status = "disabled";
                        };
 
                        pwm_cd: pwm@1a000 {
-                               compatible = "amlogic,meson-g12a-ee-pwm";
+                               compatible = "amlogic,meson-g12-pwm-v2",
+                                            "amlogic,meson8-pwm-v2";
                                reg = <0x0 0x1a000 0x0 0x20>;
+                               clocks = <&xtal>,
+                                        <>, /* unknown/untested, the datasheet calls it "vid_pll" */
+                                        <&clkc CLKID_FCLK_DIV4>,
+                                        <&clkc CLKID_FCLK_DIV3>;
                                #pwm-cells = <3>;
                                status = "disabled";
                        };
 
                        pwm_ab: pwm@1b000 {
-                               compatible = "amlogic,meson-g12a-ee-pwm";
+                               compatible = "amlogic,meson-g12-pwm-v2",
+                                            "amlogic,meson8-pwm-v2";
                                reg = <0x0 0x1b000 0x0 0x20>;
+                               clocks = <&xtal>,
+                                        <>, /* unknown/untested, the datasheet calls it "vid_pll" */
+                                        <&clkc CLKID_FCLK_DIV4>,
+                                        <&clkc CLKID_FCLK_DIV3>;
                                #pwm-cells = <3>;
                                status = "disabled";
                        };
index a457b3f4397b33d1e327fb2f13e2c8d49253ae5f..9aa36f17ffa2d0d16bb6f14ed4488dede5ff3d78 100644 (file)
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
        status = "okay";
        pinctrl-0 = <&pwm_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &pdm {
index c779a5da7d1ea06f4b7dfb626928f4cb1b90f7e8..952b8d02e5c262ff24139344fccfe4a174571038 100644 (file)
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
        status = "okay";
        pinctrl-0 = <&pwm_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &saradc {
index ea51341f031b5cc3dfc45e2618fb054a47fffbdb..52fbc5103e45015a07e894f147d67075a9c674c5 100644 (file)
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
        status = "okay";
        pinctrl-0 = <&pwm_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &pdm {
index f70a46967e2b450b0a072c4e8df10300a6417b47..5407049d264706c6e44def460d1c6e9c3ceb7e44 100644 (file)
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
index 32f98a1924942fb6162d53ca16f1e5d25621a1ae..01da83658ae3a7844caf4d1b141d96cbce424910 100644 (file)
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
        status = "okay";
        pinctrl-0 = <&pwm_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &uart_A {
index 65b963d794cd579d15797195852ea2a68d987955..adedc1340c78478521f462a18fc5280ba11e7023 100644 (file)
 
 &pwm_ab {
        pinctrl-0 = <&pwm_a_e_pins>, <&pwm_b_x7_pins>;
-       clocks = <&xtal>, <&xtal>;
-       clock-names = "clkin0", "clkin1";
 };
index 08c33ec7e9f1debac17d244b1d4eb2fbc5cf56e6..92e8b26eccccba1e2aa83378b74870a68344071b 100644 (file)
 &pwm_ab {
        pinctrl-0 = <&pwm_a_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 
        status = "okay";
 };
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
 
        status = "okay";
 };
index d4e1990b5f26b8129fb5cc1617e759c568006a1e..54663c55a20e68213c480e7fa7dac7624946cf6f 100644 (file)
        status = "okay";
        pinctrl-0 = <&pwm_a_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &pwm_ef {
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
index 16dd409051b400c91819b71cbd2f66bfd642191d..48650bad230da20baa1fb8618021708bbe53f63f 100644 (file)
 &pwm_ab {
        pinctrl-0 = <&pwm_a_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
        status = "okay";
 };
 
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
index 09d959aefb1843d8513881815b7127c1a5bfcfc6..7e8964bacfce705a3de4c208543324569c5cb3d5 100644 (file)
 &pwm_ab {
        pinctrl-0 = <&pwm_a_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
        status = "okay";
 };
 
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
index 39feba7f2d0830c72233824dbe08f98b073722a7..fc05ecf90714dd999276d751ec565ab7dcfb1db3 100644 (file)
 &pwm_ab {
        pinctrl-0 = <&pwm_a_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
        status = "okay";
 };
 
 &pwm_ef {
        pinctrl-0 = <&pwm_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
        status = "okay";
 };
 
 &pwm_AO_ab {
        pinctrl-0 = <&pwm_ao_a_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
        status = "okay";
 };
 
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
index 4cb6930ffb19620de9eef45029cfa43b08640a30..a7a0fc264cdcf0f66565f9a52144f583dbbf16bf 100644 (file)
 &pwm_ab {
        pinctrl-0 = <&pwm_a_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
        status = "okay";
 };
 
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
 &pwm_ef {
        pinctrl-0 = <&pwm_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
        status = "okay";
 };
 
index 929e4720ae7683dd2a9d0ba4cb0aaff14d388257..ac9c4c2673b1e28762606bb18791a19e2fd250ae 100644 (file)
        status = "okay";
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
 };
 
 &pwm_ab {
        status = "okay";
        pinctrl-0 = <&pwm_b_x7_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
 };
 
 &pwm_cd {
        status = "okay";
        pinctrl-0 = <&pwm_d_x3_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
 };
 
 &saradc {
index d1fa8b8bf7959da7cdbe119ae379a90562741c9b..a3463149db3d2ce670cce5a7b42308bcd3cc771a 100644 (file)
        status = "okay";
        pinctrl-0 = <&pwm_ao_a_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
        status = "okay";
        pinctrl-0 = <&pwm_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &saradc {
index 81dce862902adeabaaf5a1007894bf9b4091eb5a..40db95f64636d29294ba24d1a335435c74a87729 100644 (file)
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
index 9c0b544e2209874ee8b7c32a8141da5bf4658c19..5d75ad3f3e46b7d8f5a036df0c42f0af1ffa2f31 100644 (file)
@@ -78,8 +78,6 @@
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
index 7b0e9817a615dd3949bdbc54530318d8f17be6d4..ad8d0788376039e622f303f3c7a6b4dddf0521cf 100644 (file)
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
index 2e3397e55da2b47bf3b1b388b8b1821aa0f1816c..37d7f64b6d5d8ffa4aca0c4c56741da29dcf943f 100644 (file)
        status = "okay";
        pinctrl-0 = <&pwm_ao_a_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &pwm_AO_cd {
        pinctrl-0 = <&pwm_ao_d_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin1";
        status = "okay";
 };
 
        status = "okay";
        pinctrl-0 = <&pwm_e_pins>;
        pinctrl-names = "default";
-       clocks = <&xtal>;
-       clock-names = "clkin0";
 };
 
 &saradc {