]> git.baikalelectronics.ru Git - uboot.git/commit
led: gpio: Use NOP uclass driver for top-level node
authorMarek Vasut <marex@denx.de>
Fri, 22 Apr 2022 13:34:00 +0000 (15:34 +0200)
committerTom Rini <trini@konsulko.com>
Thu, 28 Apr 2022 13:26:43 +0000 (09:26 -0400)
commit920f001434b7895c5efc9a3c1ffc648757e85600
treecb70616ba6e61fa923c36f2d8be7bcc551984bb7
parent120383efe8689283f14374cb25ccfcd0dc7d872e
led: gpio: Use NOP uclass driver for top-level node

The top level DT node of gpio-leds is not a LED itself, bind NOP uclass
driver to it, and bind different LED uclass driver to its subnodes which
represent the actual LEDs. This simplifies the probe() implementation
and fixes the bogus top-level not-an-LED in 'led list' command output:

```
=> led list
led             Error -121 <--- This is removed/fixed by this patch
green:user0     off
```

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Patrice Chotard <patrice.chotard@foss.st.com>
Cc: Patrick Delaunay <patrick.delaunay@foss.st.com>
Cc: Sean Anderson <seanga2@gmail.com>
Cc: Simon Glass <sjg@chromium.org>
Cc: Steven Lawrance <steven.lawrance@softathome.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
Tested-by: Patrice Chotard <patrice.chotard@foss.st.com>
drivers/led/led_gpio.c