arm64: dts: renesas: Consolidate Salvator-X(S) HDMI0 handling
authorGeert Uytterhoeven <geert+renesas@glider.be>
Wed, 3 Mar 2021 14:05:29 +0000 (15:05 +0100)
committerGeert Uytterhoeven <geert+renesas@glider.be>
Wed, 10 Mar 2021 09:59:11 +0000 (10:59 +0100)
Now all Salvator-X(S) SoC/board combinations have support for HDMI
sound, all HDMI0 connector and sound descriptions are identical.
Replace them by shared descriptions in salvator-common.dtsi, to reduce
duplication.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/20210303140529.3941670-1-geert+renesas@glider.be
arch/arm64/boot/dts/renesas/r8a77950-salvator-x.dts
arch/arm64/boot/dts/renesas/r8a77951-salvator-x.dts
arch/arm64/boot/dts/renesas/r8a77951-salvator-xs.dts
arch/arm64/boot/dts/renesas/r8a77960-salvator-x.dts
arch/arm64/boot/dts/renesas/r8a77960-salvator-xs.dts
arch/arm64/boot/dts/renesas/r8a77961-salvator-xs.dts
arch/arm64/boot/dts/renesas/r8a77965-salvator-x.dts
arch/arm64/boot/dts/renesas/r8a77965-salvator-xs.dts
arch/arm64/boot/dts/renesas/salvator-common.dtsi

index 2438825c9b22e26d9f1a5ae8ba5d40706d17ea01..3e3b954a4a9defe83bb9d756332989465ed14658 100644 (file)
        status = "okay";
 };
 
-&hdmi0 {
-       status = "okay";
-
-       ports {
-               port@1 {
-                       reg = <1>;
-                       rcar_dw_hdmi0_out: endpoint {
-                               remote-endpoint = <&hdmi0_con>;
-                       };
-               };
-               port@2 {
-                       reg = <2>;
-                       dw_hdmi0_snd_in: endpoint {
-                               remote-endpoint = <&rsnd_endpoint1>;
-                       };
-               };
-       };
-};
-
-&hdmi0_con {
-       remote-endpoint = <&rcar_dw_hdmi0_out>;
-};
-
 &hdmi1 {
        status = "okay";
 
 
 &rcar_sound {
        ports {
-               /* rsnd_port0 is on salvator-common */
-               rsnd_port1: port@1 {
-                       reg = <1>;
-                       rsnd_endpoint1: endpoint {
-                               remote-endpoint = <&dw_hdmi0_snd_in>;
-
-                               dai-format = "i2s";
-                               bitclock-master = <&rsnd_endpoint1>;
-                               frame-master = <&rsnd_endpoint1>;
-
-                               playback = <&ssi2>;
-                       };
-               };
+               /* rsnd_port0/1 are described in salvator-common.dtsi */
                rsnd_port2: port@2 {
                        reg = <2>;
                        rsnd_endpoint2: endpoint {
index a402a2fb6e3c313b550daaa3d74f71e354350a6e..cf2165bdf62511ffa65f16355ad6fe9717fa75f8 100644 (file)
        status = "okay";
 };
 
-&hdmi0 {
-       status = "okay";
-
-       ports {
-               port@1 {
-                       reg = <1>;
-                       rcar_dw_hdmi0_out: endpoint {
-                               remote-endpoint = <&hdmi0_con>;
-                       };
-               };
-               port@2 {
-                       reg = <2>;
-                       dw_hdmi0_snd_in: endpoint {
-                               remote-endpoint = <&rsnd_endpoint1>;
-                       };
-               };
-       };
-};
-
-&hdmi0_con {
-       remote-endpoint = <&rcar_dw_hdmi0_out>;
-};
-
 &hdmi1 {
        status = "okay";
 
 
 &rcar_sound {
        ports {
-               /* rsnd_port0 is on salvator-common */
-               rsnd_port1: port@1 {
-                       reg = <1>;
-                       rsnd_endpoint1: endpoint {
-                               remote-endpoint = <&dw_hdmi0_snd_in>;
-
-                               dai-format = "i2s";
-                               bitclock-master = <&rsnd_endpoint1>;
-                               frame-master = <&rsnd_endpoint1>;
-
-                               playback = <&ssi2>;
-                       };
-               };
+               /* rsnd_port0/1 are described in salvator-common.dtsi */
                rsnd_port2: port@2 {
                        reg = <2>;
                        rsnd_endpoint2: endpoint {
index e5922329a4b896e4655550b79c9f4deaee2dc1f9..37202fcdc35bc7739e13b17ffad2a7caf11c0b86 100644 (file)
        status = "okay";
 };
 
-&hdmi0 {
-       status = "okay";
-
-       ports {
-               port@1 {
-                       reg = <1>;
-                       rcar_dw_hdmi0_out: endpoint {
-                               remote-endpoint = <&hdmi0_con>;
-                       };
-               };
-               port@2 {
-                       reg = <2>;
-                       dw_hdmi0_snd_in: endpoint {
-                               remote-endpoint = <&rsnd_endpoint1>;
-                       };
-               };
-       };
-};
-
-&hdmi0_con {
-       remote-endpoint = <&rcar_dw_hdmi0_out>;
-};
-
 &hdmi1 {
        status = "okay";
 
 
 &rcar_sound {
        ports {
-               /* rsnd_port0 is on salvator-common */
-               rsnd_port1: port@1 {
-                       reg = <1>;
-                       rsnd_endpoint1: endpoint {
-                               remote-endpoint = <&dw_hdmi0_snd_in>;
-
-                               dai-format = "i2s";
-                               bitclock-master = <&rsnd_endpoint1>;
-                               frame-master = <&rsnd_endpoint1>;
-
-                               playback = <&ssi2>;
-                       };
-               };
+               /* rsnd_port0/1 are described in salvator-common.dtsi */
                rsnd_port2: port@2 {
                        reg = <2>;
                        rsnd_endpoint2: endpoint {
index ecfbeafeaf367f15ef9c9d0f8d7c582e6a358da5..d5543f26c4720cea6a7d85594102c5eb1a4b4b75 100644 (file)
        clock-names = "du.0", "du.1", "du.2",
                      "dclkin.0", "dclkin.1", "dclkin.2";
 };
-
-&hdmi0 {
-       status = "okay";
-
-       ports {
-               port@1 {
-                       reg = <1>;
-                       rcar_dw_hdmi0_out: endpoint {
-                               remote-endpoint = <&hdmi0_con>;
-                       };
-               };
-               port@2 {
-                       reg = <2>;
-                       dw_hdmi0_snd_in: endpoint {
-                               remote-endpoint = <&rsnd_endpoint1>;
-                       };
-               };
-       };
-};
-
-&hdmi0_con {
-       remote-endpoint = <&rcar_dw_hdmi0_out>;
-};
-
-&rcar_sound {
-       ports {
-               /* rsnd_port0 is on salvator-common */
-               rsnd_port1: port@1 {
-                       reg = <1>;
-                       rsnd_endpoint1: endpoint {
-                               remote-endpoint = <&dw_hdmi0_snd_in>;
-
-                               dai-format = "i2s";
-                               bitclock-master = <&rsnd_endpoint1>;
-                               frame-master = <&rsnd_endpoint1>;
-
-                               playback = <&ssi2>;
-                       };
-               };
-       };
-};
-
-&sound_card {
-       dais = <&rsnd_port0     /* ak4613 */
-               &rsnd_port1>;   /* HDMI0  */
-};
index 249896a38fdcc7a83d24579a8aa664fcf009b252..9ebb47b6bf2dcbc1415c71f43751751dc4ce53c9 100644 (file)
        clock-names = "du.0", "du.1", "du.2",
                      "dclkin.0", "dclkin.1", "dclkin.2";
 };
-
-&hdmi0 {
-       status = "okay";
-
-       ports {
-               port@1 {
-                       reg = <1>;
-                       rcar_dw_hdmi0_out: endpoint {
-                               remote-endpoint = <&hdmi0_con>;
-                       };
-               };
-               port@2 {
-                       reg = <2>;
-                       dw_hdmi0_snd_in: endpoint {
-                               remote-endpoint = <&rsnd_endpoint1>;
-                       };
-               };
-       };
-};
-
-&hdmi0_con {
-       remote-endpoint = <&rcar_dw_hdmi0_out>;
-};
-
-&rcar_sound {
-       ports {
-               /* rsnd_port0 is on salvator-common */
-               rsnd_port1: port@1 {
-                       reg = <1>;
-                       rsnd_endpoint1: endpoint {
-                               remote-endpoint = <&dw_hdmi0_snd_in>;
-
-                               dai-format = "i2s";
-                               bitclock-master = <&rsnd_endpoint1>;
-                               frame-master = <&rsnd_endpoint1>;
-
-                               playback = <&ssi2>;
-                       };
-               };
-       };
-};
-
-&sound_card {
-       dais = <&rsnd_port0     /* ak4613 */
-               &rsnd_port1>;   /* HDMI0  */
-};
index 1e76033651062c3945212688a267bb807db166fb..c7f14177f7b95b5a714dfe5a67200190980d45b8 100644 (file)
        clock-names = "du.0", "du.1", "du.2",
                      "dclkin.0", "dclkin.1", "dclkin.2";
 };
-
-&hdmi0 {
-       status = "okay";
-
-       ports {
-               port@1 {
-                       reg = <1>;
-                       rcar_dw_hdmi0_out: endpoint {
-                               remote-endpoint = <&hdmi0_con>;
-                       };
-               };
-               port@2 {
-                       reg = <2>;
-                       dw_hdmi0_snd_in: endpoint {
-                               remote-endpoint = <&rsnd_endpoint1>;
-                       };
-               };
-       };
-};
-
-&hdmi0_con {
-       remote-endpoint = <&rcar_dw_hdmi0_out>;
-};
-
-&rcar_sound {
-       ports {
-               /* rsnd_port0 is on salvator-common */
-               rsnd_port1: port@1 {
-                       reg = <1>;
-                       rsnd_endpoint1: endpoint {
-                               remote-endpoint = <&dw_hdmi0_snd_in>;
-
-                               dai-format = "i2s";
-                               bitclock-master = <&rsnd_endpoint1>;
-                               frame-master = <&rsnd_endpoint1>;
-
-                               playback = <&ssi2>;
-                       };
-               };
-       };
-};
-
-&sound_card {
-       dais = <&rsnd_port0     /* ak4613 */
-               &rsnd_port1>;   /* HDMI0  */
-};
index 660a0240eec56268cd6ad661562f496b93cb0c94..f84c64ed4df7b0459fe43bb7f03770a1542eca86 100644 (file)
        clock-names = "du.0", "du.1", "du.3",
                      "dclkin.0", "dclkin.1", "dclkin.3";
 };
-
-&hdmi0 {
-       status = "okay";
-
-       ports {
-               port@1 {
-                       reg = <1>;
-                       rcar_dw_hdmi0_out: endpoint {
-                               remote-endpoint = <&hdmi0_con>;
-                       };
-               };
-               port@2 {
-                       reg = <2>;
-                       dw_hdmi0_snd_in: endpoint {
-                               remote-endpoint = <&rsnd_endpoint1>;
-                       };
-               };
-       };
-};
-
-&hdmi0_con {
-       remote-endpoint = <&rcar_dw_hdmi0_out>;
-};
-
-&rcar_sound {
-       ports {
-               rsnd_port1: port@1 {
-                       reg = <1>;
-                       rsnd_endpoint1: endpoint {
-                               remote-endpoint = <&dw_hdmi0_snd_in>;
-
-                               dai-format = "i2s";
-                               bitclock-master = <&rsnd_endpoint1>;
-                               frame-master = <&rsnd_endpoint1>;
-
-                               playback = <&ssi2>;
-                       };
-               };
-       };
-};
-
-&sound_card {
-       dais = <&rsnd_port0     /* ak4613 */
-               &rsnd_port1>;   /* HDMI0  */
-};
index d7e621101af7e6311d83145fe8834286118545bb..729756c24c7479a3474cfac18dccd86d70cf0635 100644 (file)
                      "dclkin.0", "dclkin.1", "dclkin.3";
 };
 
-&hdmi0 {
-       status = "okay";
-
-       ports {
-               port@1 {
-                       reg = <1>;
-                       rcar_dw_hdmi0_out: endpoint {
-                               remote-endpoint = <&hdmi0_con>;
-                       };
-               };
-               port@2 {
-                       reg = <2>;
-                       dw_hdmi0_snd_in: endpoint {
-                               remote-endpoint = <&rsnd_endpoint1>;
-                       };
-               };
-       };
-};
-
-&hdmi0_con {
-       remote-endpoint = <&rcar_dw_hdmi0_out>;
-};
-
 &pca9654 {
        pcie-sata-switch-hog {
                gpio-hog;
        };
 };
 
-&rcar_sound {
-       ports {
-               rsnd_port1: port@1 {
-                       reg = <1>;
-                       rsnd_endpoint1: endpoint {
-                               remote-endpoint = <&dw_hdmi0_snd_in>;
-
-                               dai-format = "i2s";
-                               bitclock-master = <&rsnd_endpoint1>;
-                               frame-master = <&rsnd_endpoint1>;
-
-                               playback = <&ssi2>;
-                       };
-               };
-       };
-};
-
 /* SW12-7 must be set 'Off' (MD12 set to 1) which is not the default! */
 &sata {
        status = "okay";
 };
-
-&sound_card {
-       dais = <&rsnd_port0     /* ak4613 */
-               &rsnd_port1>;   /* HDMI0  */
-};
index c02a167f2ee469be6a42df7c915f382fbc1e1f2c..810497c746d79700a5b3d1f523c53a6619cdb1ac 100644 (file)
 
                label = "rcar-sound";
 
-               dais = <&rsnd_port0>;
+               dais = <&rsnd_port0     /* ak4613 */
+                       &rsnd_port1>;   /* HDMI0  */
        };
 
        vbus0_usb2: regulator-vbus0-usb2 {
        clock-frequency = <32768>;
 };
 
+&hdmi0 {
+       status = "okay";
+
+       ports {
+               port@1 {
+                       reg = <1>;
+                       rcar_dw_hdmi0_out: endpoint {
+                               remote-endpoint = <&hdmi0_con>;
+                       };
+               };
+               port@2 {
+                       reg = <2>;
+                       dw_hdmi0_snd_in: endpoint {
+                               remote-endpoint = <&rsnd_endpoint1>;
+                       };
+               };
+       };
+};
+
+&hdmi0_con {
+       remote-endpoint = <&rcar_dw_hdmi0_out>;
+};
+
 &hscif1 {
        pinctrl-0 = <&hscif1_pins>;
        pinctrl-names = "default";
                                capture  = <&ssi1>, <&src1>, <&dvc1>;
                        };
                };
+
+               rsnd_port1: port@1 {
+                       reg = <1>;
+                       rsnd_endpoint1: endpoint {
+                               remote-endpoint = <&dw_hdmi0_snd_in>;
+
+                               dai-format = "i2s";
+                               bitclock-master = <&rsnd_endpoint1>;
+                               frame-master = <&rsnd_endpoint1>;
+
+                               playback = <&ssi2>;
+                       };
+               };
        };
 };