Re: [PATCH] mtd: rawnand: nuvoton: fix clock cleanup on probe failure

From: Miquel Raynal

Date: Fri Sep 25 2026 - 09:40:01 EST


On Wed, 16 Sep 2026 00:45:37 +0800, Guangshuo Li wrote:
> ma35_nand_probe() gets and enables the NAND clock with
> devm_clk_get_enabled(), but the ma35_nand_chips_init() failure path
> also calls clk_disable() before returning.
>
> devm_clk_get_enabled() registers a managed cleanup that calls
> clk_disable_unprepare() on probe failure and driver removal. Calling
> clk_disable() explicitly first drops the clock enable count, so the
> managed cleanup attempts to disable the clock again and triggers the
> clock framework warning for an already disabled clock.
>
> [...]

Applied to nand/next, thanks!

[1/1] mtd: rawnand: nuvoton: fix clock cleanup on probe failure
commit: 8a485a40f45a19c5fcafb5cbee7387c2762af7c4

Patche(s) should be available on mtd/linux.git and will be
part of the next PR (provided that no robot complains by then).

Kind regards,
Miquèl