[PATCH] mtd: rawnand: atmel: Fix HSMC clock leak in legacy controller init

krzk at kernel.org krzk at kernel.org
Mon Sep 21 08:17:46 PDT 2026


On Thu, 17 Sep 2026 10:28:04 +0000, Wentao Liang wrote:
> atmel_hsmc_nand_controller_legacy_init() takes a reference to the
> HSMC clock with of_clk_get() and enables it, but the error paths
> that follow only release the device node, so both the reference and
> the enable are leaked whenever the controller cannot be fully
> initialized.  The probe fails in that case and never reaches
> atmel_hsmc_nand_controller_remove(), which is where the clock is
> normally disabled and put.
> 
> Add an err_disable_clk path that disables and releases the clock
> before jumping to the existing out path.
> 
> Fixes: f88fc122cc34 ("mtd: nand: Cleanup/rework the atmel_nand driver")
> Cc: stable at vger.kernel.org
> Signed-off-by: Wentao Liang <vulab at iscas.ac.cn>
> ---
>  drivers/mtd/nand/raw/atmel/nand-controller.c | 25 +++++++++++++-------
>  1 file changed, 16 insertions(+), 9 deletions(-)
> 


You sent multiple independent patches, to multiple independent
subsystems. The amount of these patches clearly suggest this was
AI generated and most likely not tested.

More importantly, you sent all this work without properly organizing
relevant patches into patchsets. This makes reviewing difficult
and might cause multiple reviewers to address the same issue.
Replying to the entire set is impossible and requires handling each
patch independently, instead of applying or discarding the set.
Maintainers also won't see the bigger picture of your work. Quite
worrying.

This is on the verge of hostile patch: bomb us with so many
contributions, we won't be able to handle them in efficient manner,
like responding ONCE to ask you to slow down.  Considering all this
is untested and LLM generated, I have even more doubts whether this
should be considered for review.

Please read kernel documentation BEFORE posting more work. It will
explain you how to identify subsystems, how to organize your work per
subsystem, how to document usage of LLM and how what you should not
do if this was posted in a good faith.

Best regards,
Krzysztof






More information about the linux-arm-kernel mailing list