MLK-16973-7 arm64: dts: fsl-imx8qm-lpddr4-arm2: Add LVDS0/1 PWM backlight support
authorLiu Ying <victor.liu@nxp.com>
Fri, 24 Nov 2017 02:39:34 +0000 (10:39 +0800)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 20:55:44 +0000 (15:55 -0500)
This patch adds LVDS0/1 PWM backlight support
for the i.MX8QM LPDDR4 ARM2 platform.

Signed-off-by: Liu Ying <victor.liu@nxp.com>
arch/arm64/boot/dts/freescale/fsl-imx8qm-lpddr4-arm2.dts

index caccbf7..7b509aa 100644 (file)
                audio-cpu = <&sai_hdmi_tx>;
                protocol = <1>;
        };
+
+       lvds_backlight0: lvds_backlight@0 {
+               compatible = "pwm-backlight";
+               pwms = <&lvds0_pwm 0 100000 0>;
+
+               brightness-levels = < 0  1  2  3  4  5  6  7  8  9
+                                    10 11 12 13 14 15 16 17 18 19
+                                    20 21 22 23 24 25 26 27 28 29
+                                    30 31 32 33 34 35 36 37 38 39
+                                    40 41 42 43 44 45 46 47 48 49
+                                    50 51 52 53 54 55 56 57 58 59
+                                    60 61 62 63 64 65 66 67 68 69
+                                    70 71 72 73 74 75 76 77 78 79
+                                    80 81 82 83 84 85 86 87 88 89
+                                    90 91 92 93 94 95 96 97 98 99
+                                   100>;
+               default-brightness-level = <80>;
+       };
+
+       lvds_backlight1: lvds_backlight@1 {
+               compatible = "pwm-backlight";
+               pwms = <&lvds1_pwm 0 100000 0>;
+
+               brightness-levels = < 0  1  2  3  4  5  6  7  8  9
+                                    10 11 12 13 14 15 16 17 18 19
+                                    20 21 22 23 24 25 26 27 28 29
+                                    30 31 32 33 34 35 36 37 38 39
+                                    40 41 42 43 44 45 46 47 48 49
+                                    50 51 52 53 54 55 56 57 58 59
+                                    60 61 62 63 64 65 66 67 68 69
+                                    70 71 72 73 74 75 76 77 78 79
+                                    80 81 82 83 84 85 86 87 88 89
+                                    90 91 92 93 94 95 96 97 98 99
+                                   100>;
+               default-brightness-level = <80>;
+       };
 };
 
 &acm {
                                SC_P_USB_SS3_TC0_CONN_USB_OTG1_PWR              0x00000021
                        >;
                };
+
+               pinctrl_lvds0_pwm0: lvds0pwm0grp {
+                       fsl,pins = <
+                               SC_P_LVDS0_GPIO00_LVDS0_PWM0_OUT        0x00000020
+                       >;
+               };
+
+               pinctrl_lvds1_pwm0: lvds1pwm0grp {
+                       fsl,pins = <
+                               SC_P_LVDS1_GPIO00_LVDS1_PWM0_OUT        0x00000020
+                       >;
+               };
        };
 };
 
        status = "okay";
 };
 
+&lvds0_pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_lvds0_pwm0>;
+       status = "okay";
+};
+
+&lvds1_pwm {
+       pinctrl-names = "default";
+       pinctrl-0 = <&pinctrl_lvds1_pwm0>;
+       status = "okay";
+};
+
 &ldb1_phy {
        status = "okay";
 };