diff options
| author | AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> | 2023-02-23 15:54:26 +0100 |
|---|---|---|
| committer | Matthias Brugger <matthias.bgg@gmail.com> | 2023-03-31 12:45:11 +0200 |
| commit | ee508454fd555099d51f3c704fc2ff292c5e152f (patch) | |
| tree | 9c22d2f12153cc952d795381c9671450a15c023c | |
| parent | b86b9464467de6687f58f6ef9a866696a69be5f3 (diff) | |
| download | linux-ee508454fd555099d51f3c704fc2ff292c5e152f.tar.gz linux-ee508454fd555099d51f3c704fc2ff292c5e152f.zip | |
arm64: dts: mediatek: cherry: Add configuration for display backlight
Configure the hardware PWM for the integrated display's backlight:
all Cherry devices enable the backlight with GPIO82 and manage the
PWM via MediaTek disp-pwm on GPIO97.
Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Reviewed-by: Chen-Yu Tsai <wenst@chromium.org>
Tested-by: Chen-Yu Tsai <wenst@chromium.org>
Link: https://lore.kernel.org/r/20230223145426.193590-5-angelogioacchino.delregno@collabora.com
Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
| -rw-r--r-- | arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi b/arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi index 24669093fbed..8ac80a136c37 100644 --- a/arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi @@ -22,6 +22,16 @@ serial0 = &uart0; }; + backlight_lcd0: backlight-lcd0 { + compatible = "pwm-backlight"; + brightness-levels = <0 1023>; + default-brightness-level = <576>; + enable-gpios = <&pio 82 GPIO_ACTIVE_HIGH>; + num-interpolated-steps = <1023>; + pwms = <&disp_pwm0 0 500000>; + power-supply = <&ppvar_sys>; + }; + chosen { stdout-path = "serial0:115200n8"; }; @@ -212,6 +222,13 @@ }; }; +&disp_pwm0 { + status = "okay"; + + pinctrl-names = "default"; + pinctrl-0 = <&disp_pwm0_pin_default>; +}; + &dp_tx { status = "okay"; @@ -653,6 +670,13 @@ }; }; + disp_pwm0_pin_default: disp-pwm0-default-pins { + pins-disp-pwm { + pinmux = <PINMUX_GPIO82__FUNC_GPIO82>, + <PINMUX_GPIO97__FUNC_DISP_PWM0>; + }; + }; + dptx_pin: dptx-default-pins { pins-cmd-dat { pinmux = <PINMUX_GPIO18__FUNC_DP_TX_HPD>; |
