arm64: meson: g12-common: add the MIPI DSI nodes
authorNeil Armstrong <neil.armstrong@linaro.org>
Wed, 3 Apr 2024 07:46:36 +0000 (09:46 +0200)
committerNeil Armstrong <neil.armstrong@linaro.org>
Wed, 10 Apr 2024 08:53:24 +0000 (10:53 +0200)
Add the MIPI DSI Analog & Digital PHY nodes and the DSI control
nodes with proper port endpoint to the VPU.

Link: https://lore.kernel.org/r/20240403-amlogic-v6-4-upstream-dsi-ccf-vim3-v12-5-99ecdfdc87fc@linaro.org
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
arch/arm64/boot/dts/amlogic/meson-g12-common.dtsi

index 9d5eab6595d022647ceb77a2f48c854f213cc2ed..b058ed78faf00682791ce38ca60c1b0d6ff8db66 100644 (file)
                                                                       <250000000>,
                                                                       <0>; /* Do Nothing */
                                        };
+
+                                       mipi_analog_dphy: phy {
+                                               compatible = "amlogic,g12a-mipi-dphy-analog";
+                                               #phy-cells = <0>;
+                                               status = "disabled";
+                                       };
                                };
                        };
 
+                       mipi_dphy: phy@44000 {
+                               compatible = "amlogic,axg-mipi-dphy";
+                               reg = <0x0 0x44000 0x0 0x2000>;
+                               clocks = <&clkc CLKID_MIPI_DSI_PHY>;
+                               clock-names = "pclk";
+                               resets = <&reset RESET_MIPI_DSI_PHY>;
+                               reset-names = "phy";
+                               phys = <&mipi_analog_dphy>;
+                               phy-names = "analog";
+                               #phy-cells = <0>;
+                               status = "disabled";
+                       };
+
                        usb3_pcie_phy: phy@46000 {
                                compatible = "amlogic,g12a-usb3-pcie-phy";
                                reg = <0x0 0x46000 0x0 0x2000>;
                                        remote-endpoint = <&hdmi_tx_in>;
                                };
                        };
+
+                       /* DPI output port */
+                       dpi_port: port@2 {
+                               reg = <2>;
+
+                               dpi_out: endpoint {
+                                       remote-endpoint = <&mipi_dsi_in>;
+                               };
+                       };
                };
 
                gic: interrupt-controller@ffc01000 {
                                amlogic,channel-interrupts = <64 65 66 67 68 69 70 71>;
                        };
 
+                       mipi_dsi: dsi@7000 {
+                               compatible = "amlogic,meson-g12a-dw-mipi-dsi";
+                               reg = <0x0 0x7000 0x0 0x1000>;
+                               resets = <&reset RESET_MIPI_DSI_HOST>;
+                               reset-names = "top";
+                               clocks = <&clkc CLKID_MIPI_DSI_HOST>,
+                                        <&clkc CLKID_MIPI_DSI_PXCLK>,
+                                        <&clkc CLKID_CTS_ENCL>;
+                               clock-names = "pclk", "bit", "px";
+                               phys = <&mipi_dphy>;
+                               phy-names = "dphy";
+                               #address-cells = <1>;
+                               #size-cells = <0>;
+                               status = "disabled";
+
+                               assigned-clocks = <&clkc CLKID_MIPI_DSI_PXCLK_SEL>,
+                                        <&clkc CLKID_CTS_ENCL_SEL>,
+                                        <&clkc CLKID_VCLK2_SEL>;
+                               assigned-clock-parents = <&clkc CLKID_GP0_PLL>,
+                                        <&clkc CLKID_VCLK2_DIV1>,
+                                        <&clkc CLKID_GP0_PLL>;
+
+                               ports {
+                                       #address-cells = <1>;
+                                       #size-cells = <0>;
+
+                                       /* VPU VENC Input */
+                                       mipi_dsi_venc_port: port@0 {
+                                               reg = <0>;
+
+                                               mipi_dsi_in: endpoint {
+                                                       remote-endpoint = <&dpi_out>;
+                                               };
+                                       };
+
+                                       /* DSI Output */
+                                       mipi_dsi_panel_port: port@1 {
+                                               reg = <1>;
+                                       };
+                               };
+                       };
+
                        watchdog: watchdog@f0d0 {
                                compatible = "amlogic,meson-gxbb-wdt";
                                reg = <0x0 0xf0d0 0x0 0x10>;