Re: [PATCH 2/2] power: supply: max17040: fail probe when requesting the alert IRQ fails

From: Krzysztof Kozlowski

Date: Mon Nov 02 2026 - 02:40:53 EST


On 02/11/2026 08:31, Jianing Li wrote:
> MAX17048 and MAX17049 skip polling work initialization when an IRQ is
> available because SOC alerts replace polling. If requesting that IRQ
> fails, max17040_probe() clears client->irq and returns success anyway.
> The driver then has neither an interrupt handler nor a polling worker.
>
> Clearing client->irq also makes the suspend and resume callbacks take
> the polling path, which operates on an uninitialized delayed work item.
>
> Propagate the IRQ request error instead of registering a device with
> inconsistent interrupt and polling state. The managed resources unwind
> the already registered power supply and, for polling models, cancel any
> queued work.

That's LLM commit msg and you are not suppose to use LLM for that.

Best regards,
Krzysztof