Re: [PATCH v5 0/9] leds: st1202: fix multiple bugs in pattern engine and brightness handling

Manuel Fombuena <[email protected]>
Newsgroups org.kernel.vger.linux-leds,org.kernel.vger.linux-kernel
Message-ID <GV1PR08MB8497A2A52ECED19DE611337BC5F52@GV1PR08MB8497.eurprd08.prod.outlook.com>
On Thu, 2 Jul 2026, Lee Jones wrote:

> 
> Still a few potential issues highlighted - are they yours?
> 
> https://sashiko.dev/#/patchset/GV1PR08MB8497ABC8E6AEFF8AAA1AF883C5E32@GV1PR08MB8497.eurprd08.prod.outlook.com
> 

Thank you for looking into this.

I have sent a v6 addressing the Sashiko feedback on patch 4 and 6:

https://lore.kernel.org/all/GV1PR08MB84972A16ED557BFB96D63F57C5F52@GV1PR08MB8497.eurprd08.prod.outlook.com/

For the sake of clarity, these are the responses to the non-pre-existing 
issues.

Patch 1 comment: stopping the global sequencer in pattern_clear()
does halt all channels simultaneously, not just the one being cleared.

Response: this is an inherent hardware constraint. The LED1202 has a
single shared sequencer and, per section 4.8 of the datasheet, register
writes are silently ignored while it is running. There is no way to stop
it selectively per channel. This limitation is noted in the commit 
message.

Patch 4 comment: pattern_clear() set Pattern0 PWM to FULL but left
Patterns 1-7 at LED_OFF. If another channel subsequently starts the
global sequencer, this channel cycles through its uneven PWM slots
and blinks.

Response: fix in v6. Set all 8 slots to ST1202_PATTERN_PWM_FULL,
simplifying to a single loop from 0.

Patch 6 comment: brightness_set() stops the global sequencer via
CONFIG_REG, disrupting patterns on all other channels.

Response: fix in v6. Set all 8 PWM slots for the channel to
ST1202_PATTERN_PWM_FULL instead, so the channel outputs steady ILED
regardless of which sequencer step is active, without touching
CONFIG_REG.

--
Manuel Fombuena
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.