arm64: dts: qcom: sc7180-trogdor: Disable pwmleds node where unused
BugLink: https://bugs.launchpad.net/bugs/2083196
[ Upstream commit 99e94768c890c7522af020ff0e5e5317b2d046d9 ]
Currently the keyboard backlight is described in the common
sc7180-trogdor dtsi as an led node below a pwmleds node, and the led
node is set to disabled. Only the boards that have a keyboard backlight
enable it.
However, since the parent pwmleds node is still enabled everywhere, even
on boards that don't have keyboard backlight it is probed and fails,
resulting in an error:
leds_pwm pwmleds: probe with driver leds_pwm failed with error -22
as well as a failure in the DT kselftest:
not ok 45 /pwmleds
Fix this by controlling the status of the parent pwmleds node instead of
the child led, based on the presence of keyboard backlight. This is what
is done on sc7280 already.
While at it add a missing blank line before the child node to follow the
coding style.
Fixes: 7ec3e67307 ("arm64: dts: qcom: sc7180-trogdor: add initial trogdor and lazor dt")
Signed-off-by: Nícolas F. R. A. Prado <nfraprado@collabora.com>
Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Link: https://lore.kernel.org/r/20240614-sc7180-pwmleds-probe-v1-1-e2c3f1b42a43@collabora.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Portia Stephens <portia.stephens@canonical.com>
Signed-off-by: Roxana Nicolescu <roxana.nicolescu@canonical.com>
This commit is contained in:
committed by
Mehmet Basaran
parent
9e07e845df
commit
3e4743af78
@@ -12,6 +12,6 @@
|
||||
compatible = "google,lazor-rev1-sku2", "google,lazor-rev2-sku2", "qcom,sc7180";
|
||||
};
|
||||
|
||||
&keyboard_backlight {
|
||||
&pwmleds {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -17,6 +17,6 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&keyboard_backlight {
|
||||
&pwmleds {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -18,6 +18,6 @@
|
||||
compatible = "google,lazor-sku2", "qcom,sc7180";
|
||||
};
|
||||
|
||||
&keyboard_backlight {
|
||||
&pwmleds {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -22,6 +22,6 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&keyboard_backlight {
|
||||
&pwmleds {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -21,6 +21,6 @@
|
||||
"qcom,sc7180";
|
||||
};
|
||||
|
||||
&keyboard_backlight {
|
||||
&pwmleds {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -25,6 +25,6 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&keyboard_backlight {
|
||||
&pwmleds {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -18,6 +18,6 @@
|
||||
compatible = "google,lazor-rev9-sku2", "qcom,sc7180";
|
||||
};
|
||||
|
||||
&keyboard_backlight {
|
||||
&pwmleds {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -22,6 +22,6 @@
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&keyboard_backlight {
|
||||
&pwmleds {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
@@ -359,10 +359,11 @@
|
||||
#sound-dai-cells = <0>;
|
||||
};
|
||||
|
||||
pwmleds {
|
||||
pwmleds: pwmleds {
|
||||
compatible = "pwm-leds";
|
||||
status = "disabled";
|
||||
|
||||
keyboard_backlight: led-0 {
|
||||
status = "disabled";
|
||||
label = "cros_ec::kbd_backlight";
|
||||
function = LED_FUNCTION_KBD_BACKLIGHT;
|
||||
pwms = <&cros_ec_pwm 0>;
|
||||
|
||||
Reference in New Issue
Block a user