ARM: dts: Update the NSPIRE DTS files for DRM
authorLinus Walleij <linus.walleij@linaro.org>
Sat, 10 Aug 2019 07:42:30 +0000 (09:42 +0200)
committerArnd Bergmann <arnd@arndb.de>
Tue, 13 Aug 2019 13:28:34 +0000 (15:28 +0200)
The DRM subsystem graphics drivers require more granular
definition of the connection between display drivers and
panels, and a proper panel compatible. This utilizes the
bindings merged to the DRM subsystem to properly define
the display on the NSPIRE devices.

We also do away with the undocumented DT binding
"lcd-type".

We add both the clocks to the CLCD block so the driver
have full control over its clocking.

Link: https://lore.kernel.org/r/20190810074230.6492-1-linus.walleij@linaro.org
Cc: Daniel Tang <dt.tangr@gmail.com>
Cc: Fabian Vogt <fabian@ritter-vogt.de>
Tested-by: Fabian Vogt <fabian@ritter-vogt.de>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
arch/arm/boot/dts/nspire-classic.dtsi
arch/arm/boot/dts/nspire-cx.dts
arch/arm/boot/dts/nspire.dtsi

index c53f427..41744cc 100644 (file)
@@ -8,7 +8,11 @@
 /include/ "nspire.dtsi"
 
 &lcd {
-       lcd-type = "classic";
+       port {
+               clcd_pads: endpoint {
+                       remote-endpoint = <&panel_in>;
+               };
+       };
 };
 
 &fast_timer {
                        #interrupt-cells = <1>;
                };
        };
+
+       panel {
+               compatible = "ti,nspire-classic-lcd-panel";
+               port {
+                       panel_in: endpoint {
+                               remote-endpoint = <&clcd_pads>;
+                       };
+               };
+       };
        chosen {
                bootargs = "debug earlyprintk console=tty0 console=ttyS0,115200n8 root=/dev/ram0";
        };
index da95c37..0c16b04 100644 (file)
@@ -9,7 +9,11 @@
 /include/ "nspire.dtsi"
 
 &lcd {
-       lcd-type = "cx";
+       port {
+               clcd_pads: endpoint {
+                       remote-endpoint = <&panel_in>;
+               };
+       };
 };
 
 &fast_timer {
                        };
                };
        };
+
+       panel {
+               compatible = "ti,nspire-cx-lcd-panel";
+               port {
+                       panel_in: endpoint {
+                               remote-endpoint = <&clcd_pads>;
+                       };
+               };
+       };
        chosen {
                bootargs = "debug earlyprintk console=tty0 console=ttyAMA0,115200n8 root=/dev/ram0";
        };
index c35fd66..d9a0fd7 100644 (file)
                        reg = <0xC0000000 0x1000>;
                        interrupts = <21>;
 
-                       clocks = <&apb_pclk>;
-                       clock-names = "apb_pclk";
+                       /*
+                        * We assume the same clock is fed to APB and CLCDCLK.
+                        * There is some code to scale the clock down by a factor
+                        * 48 for the display so likely the frequency to the
+                        * display is 1MHz and the CLCDCLK is 48 MHz.
+                        */
+                       clocks = <&apb_pclk>, <&apb_pclk>;
+                       clock-names = "clcdclk", "apb_pclk";
                };
 
                adc: adc@C4000000 {