diff options
| author | Tom Rini <[email protected]> | 2025-10-17 08:58:10 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2025-10-17 08:58:10 -0600 |
| commit | a46a2e2227b5d5010ac5837a104040ce9474ef95 (patch) | |
| tree | 35d90271aa999077f71d35970ef5ec1b28c4f9ba | |
| parent | bf1d8c1fec863b7da2f0d1ed4bd5526275d70dc2 (diff) | |
| parent | 827ccb84ff433001b59168d81a59489e339ec2c0 (diff) | |
Merge patch series "led: fixes"
Patrice Chotard <[email protected]> says:
- Update led_get_by_label()
- Fix led Kconfig
Link: https://lore.kernel.org/r/[email protected]
| -rw-r--r-- | drivers/led/Kconfig | 2 | ||||
| -rw-r--r-- | drivers/led/led-uclass.c | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/drivers/led/Kconfig b/drivers/led/Kconfig index a37ec633fb6..1cd3638cb16 100644 --- a/drivers/led/Kconfig +++ b/drivers/led/Kconfig @@ -11,6 +11,7 @@ config LED config LED_BOOT bool "Enable LED boot support" + depends on LED help Enable LED boot support. @@ -22,6 +23,7 @@ config LED_BOOT config LED_ACTIVITY bool "Enable LED activity support" + depends on LED help Enable LED activity support. diff --git a/drivers/led/led-uclass.c b/drivers/led/led-uclass.c index edcdeee1e9a..1efdbe272c3 100644 --- a/drivers/led/led-uclass.c +++ b/drivers/led/led-uclass.c @@ -65,6 +65,9 @@ int led_get_by_label(const char *label, struct udevice **devp) /* Ignore the top-level LED node */ if (uc_plat->label && !strcmp(label, uc_plat->label)) return uclass_get_device_tail(dev, 0, devp); + + if (!strcmp(label, ofnode_get_name(dev_ofnode(dev)))) + return uclass_get_device_tail(dev, 0, devp); } return -ENODEV; |
