]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
gpio: grgpio: call request_irq after incrementing the reference count
authorAlex Tran <alex.t.tran@gmail.com>
Thu, 2 Oct 2025 05:57:27 +0000 (22:57 -0700)
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Mon, 13 Oct 2025 15:33:50 +0000 (17:33 +0200)
commit411b39bd1ac68c44f9e3c7dce5e095f6a71598c1
tree1418590cf1efa0897bbd1fbbfad09d9980fa4323
parent383760e3faa4d3df6e399d207e2930a785380c4e
gpio: grgpio: call request_irq after incrementing the reference count

Remove extraneous dropping of the lock just to call 'request_irq'
and locking again afterwards. Increment reference count
before calling 'request_irq'. Rollback reference count if
'request_irq' fails.

Suggested-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Signed-off-by: Alex Tran <alex.t.tran@gmail.com>
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
drivers/gpio/gpio-grgpio.c