summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNĂ­colas F. R. A. Prado <nfraprado@collabora.com>2022-06-29 18:59:49 +0300
committerMatthias Brugger <matthias.bgg@gmail.com>2022-07-07 17:39:17 +0300
commit6812f4ed6e77f422be5a17e5cebf14bd51411c5e (patch)
tree12e55df91a25479e91712890bc3b8444fc665b89
parentcbd4af081a216025dd5c8a8f6a653c47c8a02353 (diff)
downloadlinux-6812f4ed6e77f422be5a17e5cebf14bd51411c5e.tar.xz
arm64: dts: mediatek: spherion: Add keyboard backlight
The Spherion board has keyboard backlight controlled by the PWM signal generated by the ChromeOS EC. Enable PWM output for ChromeOS EC and add a PWM controlled LED node for the keyboard backlight. Signed-off-by: NĂ­colas F. R. A. Prado <nfraprado@collabora.com> Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Tested-by: Chen-Yu Tsai <wenst@chromium.org> Link: https://lore.kernel.org/r/20220629155956.1138955-13-nfraprado@collabora.com Signed-off-by: Matthias Brugger <matthias.bgg@gmail.com>
-rw-r--r--arch/arm64/boot/dts/mediatek/mt8192-asurada-spherion-r0.dts16
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/arm64/boot/dts/mediatek/mt8192-asurada-spherion-r0.dts b/arch/arm64/boot/dts/mediatek/mt8192-asurada-spherion-r0.dts
index 42db81e95fae..fa3d9573f37a 100644
--- a/arch/arm64/boot/dts/mediatek/mt8192-asurada-spherion-r0.dts
+++ b/arch/arm64/boot/dts/mediatek/mt8192-asurada-spherion-r0.dts
@@ -4,12 +4,28 @@
*/
/dts-v1/;
#include "mt8192-asurada.dtsi"
+#include <dt-bindings/leds/common.h>
/ {
model = "Google Spherion (rev0 - 3)";
compatible = "google,spherion-rev3", "google,spherion-rev2",
"google,spherion-rev1", "google,spherion-rev0",
"google,spherion", "mediatek,mt8192";
+
+ pwmleds {
+ compatible = "pwm-leds";
+
+ led {
+ function = LED_FUNCTION_KBD_BACKLIGHT;
+ color = <LED_COLOR_ID_WHITE>;
+ pwms = <&cros_ec_pwm 0>;
+ max-brightness = <1023>;
+ };
+ };
+};
+
+&cros_ec_pwm {
+ status = "okay";
};
&keyboard_controller {