gpiolib: cdev: Refactor allocation of linereq events kfifo
authorKent Gibson <warthog618@gmail.com>
Wed, 29 May 2024 13:19:52 +0000 (21:19 +0800)
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>
Thu, 30 May 2024 09:29:10 +0000 (11:29 +0200)
commit4ce5ca654a761462a222164e96b8ab953b8cacab
tree4713967dfd8c6f28265068f27704742fa5949f04
parent35d848e7a1cbba2649ed98cf58e0cdc7ee560c7a
gpiolib: cdev: Refactor allocation of linereq events kfifo

The allocation of the linereq events kfifo is performed in two separate
places.  Add a helper function to remove the duplication.

Signed-off-by: Kent Gibson <warthog618@gmail.com>
Link: https://lore.kernel.org/r/20240529131953.195777-3-warthog618@gmail.com
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
drivers/gpio/gpiolib-cdev.c