[PATCH v3 4/7] backlight: qcom-wled: Change PM8950 WLED configurations

Barnabás Czémán posted 7 patches 3 weeks, 2 days ago
[PATCH v3 4/7] backlight: qcom-wled: Change PM8950 WLED configurations
Posted by Barnabás Czémán 3 weeks, 2 days ago
PMI8950 WLED needs same configurations as PMI8994 WLED.

Fixes: 10258bf4534b ("backlight: qcom-wled: Add PMI8950 compatible")
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
---
 drivers/video/backlight/qcom-wled.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/video/backlight/qcom-wled.c b/drivers/video/backlight/qcom-wled.c
index 5decbd39b789..8054e4787725 100644
--- a/drivers/video/backlight/qcom-wled.c
+++ b/drivers/video/backlight/qcom-wled.c
@@ -1455,7 +1455,8 @@ static int wled_configure(struct wled *wled)
 		break;
 
 	case 4:
-		if (of_device_is_compatible(dev->of_node, "qcom,pmi8994-wled")) {
+		if (of_device_is_compatible(dev->of_node, "qcom,pmi8950-wled") ||
+		    of_device_is_compatible(dev->of_node, "qcom,pmi8994-wled")) {
 			u32_opts = pmi8994_wled_opts;
 			size = ARRAY_SIZE(pmi8994_wled_opts);
 		} else {

-- 
2.52.0

Re: [PATCH v3 4/7] backlight: qcom-wled: Change PM8950 WLED configurations
Posted by Daniel Thompson 2 weeks, 6 days ago
On Fri, Jan 16, 2026 at 08:07:36AM +0100, Barnabás Czémán wrote:
> PMI8950 WLED needs same configurations as PMI8994 WLED.
>
> Fixes: 10258bf4534b ("backlight: qcom-wled: Add PMI8950 compatible")
> Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
> Signed-off-by: Barnabás Czémán <barnabas.czeman@mainlining.org>
> ---
>  drivers/video/backlight/qcom-wled.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/video/backlight/qcom-wled.c b/drivers/video/backlight/qcom-wled.c
> index 5decbd39b789..8054e4787725 100644
> --- a/drivers/video/backlight/qcom-wled.c
> +++ b/drivers/video/backlight/qcom-wled.c
> @@ -1455,7 +1455,8 @@ static int wled_configure(struct wled *wled)
>  		break;
>
>  	case 4:
> -		if (of_device_is_compatible(dev->of_node, "qcom,pmi8994-wled")) {
> +		if (of_device_is_compatible(dev->of_node, "qcom,pmi8950-wled") ||
> +		    of_device_is_compatible(dev->of_node, "qcom,pmi8994-wled")) {
>  			u32_opts = pmi8994_wled_opts;

I still really dislike naming the structures after a single instance of
the PMIC when, at inception, that name is known to be wrong. However
if the Qualcomm devs are happy with it then I guess I can live with it.

Reviewed-by: Daniel Thompson (RISCstar) <danielt@kernel.org>


Thanks

Daniel.