[PATCH v2 1/3] sunxi: spl: fix SPL_SUNXI_LED active low configuration

Quentin Schulz quentin.schulz at cherry.de
Wed Apr 29 11:49:12 CEST 2026


Hi Andre,

On 4/29/26 11:28 AM, Andre Przywara wrote:
> The newly introduced Allwinner SPL LED "framework" defined a
> SPL_SUNXI_LED_STATUS_STATE Kconfig symbol, that was supposed to denote
> the active-low vs. active-high polarity of the LED. However this is
> a bool symbol, so it will simply vanish if not defined, and we cannot use
> it directly inside a C statement.
> 
> Filter the symbol through the IS_ENABLED() macro, which will return 0 if
> the symbol is not defined, which is the intended value here.
> 
> Since the STATUS_STATE name is a bit confusing, rename it to ACTIVE_HIGH
> on the way, because that is its real meaning. Also the LED_STATUS_BIT
> name for the GPIO number is similarly a remnant of the old status LED
> code, so rename it to LED_STATUS_GPIO as well.
> 
> This fixes configuring LEDs with active-low polarity.
> 

Individual patches would have been better.

> Fixes: 256557dd9aae ("sunxi: remove usage of legacy LED API")

Reported-by: Paul Kocialkowski <paulk at sys-base.io>
Closes: https://lore.kernel.org/u-boot/adfMQBPdntWy1KIq@shepard/

Acked-by: Quentin Schulz <quentin.schulz at cherry.de>

Thanks!
Quentin


More information about the U-Boot mailing list