[PATCH 1/2] gpio: sifive: Unregister the GPIO chip on unbind

Bartosz Golaszewski brgl at kernel.org
Mon Nov 30 07:14:19 PST 2026


On Sat, Nov 28, 2026 at 07:02:28PM +0800, Tian Xuechen wrote:
> From: Tian Xuechen <202300460064 at mail.sdu.edu.cn>
> 
> The SiFive driver registers a GPIO chip embedded in managed storage.
> The chip remains registered when the driver unbinds and that storage
> is released.
> 
> Use devm_gpiochip_add_data() to unregister the chip on unbind.
> 
> This issue was found by our static analysis tool under development.
>

Please stop adding this line to your commit message, I keep having to
remove them manually.

Bart



More information about the linux-riscv mailing list