]> Gentwo Git Trees - linux/.git/commit
mtd: rawnand: lpc32xx_slc: Convert to use devm_gpiod_get_optional()
authorHaotian Zhang <vulab@iscas.ac.cn>
Tue, 4 Nov 2025 10:08:41 +0000 (18:08 +0800)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Mon, 17 Nov 2025 10:52:17 +0000 (11:52 +0100)
commit1f3dcfe5fcf57739b4a82811c12e55c48d794f86
tree6d93947356c2953d70277f6a425154941e237569
parent88fd4e4deae87fa66e0e00e2bf6a4c362d241215
mtd: rawnand: lpc32xx_slc: Convert to use devm_gpiod_get_optional()

The initial fix for a GPIO descriptor leak added manual gpiod_put()
calls in the error path and remove function.

This follow-up patch improves upon the fix by switching to the
resource-managed devm_gpiod_get_optional() API.

Suggested-by: Vladimir Zapolskiy <vz@mleia.com>
Signed-off-by: Haotian Zhang <vulab@iscas.ac.cn>
Reviewed-by: Vladimir Zapolskiy <vz@mleia.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
drivers/mtd/nand/raw/lpc32xx_slc.c