diff --git a/arch/arm/boot/dts/overlays/README b/arch/arm/boot/dts/overlays/README index 2640a5678432a3..b4282cbcd72cc1 100644 --- a/arch/arm/boot/dts/overlays/README +++ b/arch/arm/boot/dts/overlays/README @@ -5980,8 +5980,10 @@ Params: brightness Set the initial brightness for the LEDs. The a single byte to offset 0 of the device. Note that brightness is a multiplier for the pixel values, and only white pixels can reach the - maximum visible brightness. (range 0-255, - default 255) + maximum visible brightness. N.B. Setting + brightness to 0 acctivates pass-through mode, + disabling all brightness and gamma processing. + (range 0-255, default 255) dev_name The name for the /dev/ device entry. Note that if the name includes '%d' it will be replaced by the instance number. (default 'leds%d') diff --git a/drivers/misc/ws2812-pio-rp1.c b/drivers/misc/ws2812-pio-rp1.c index ee840c6b33122e..311446a3262147 100644 --- a/drivers/misc/ws2812-pio-rp1.c +++ b/drivers/misc/ws2812-pio-rp1.c @@ -142,8 +142,8 @@ static uint8_t ws2812_apply_gamma(uint8_t brightness, uint8_t val) { int bright; - if (!val) - return 0; + if (!val || !brightness) + return val; bright = (val * brightness) / 255; return ws2812_gamma[bright]; }