Re: [PATCH 1/2] devm-helpers: Add resource managed version of mutex init

From: Bartosz Golaszewski
Date: Thu Feb 22 2024 - 10:11:53 EST


On Thu, Feb 22, 2024 at 3:58 PM Marek Behún <kabel@xxxxxxxxxx> wrote:
>
> A few drivers are doing resource-managed mutex initialization by
> implementing ad-hoc one-liner mutex dropping functions and using them
> with devm_add_action_or_reset(). Help drivers avoid these repeated
> one-liners by adding managed version of mutex initialization.
>
> Use the new function devm_mutex_init() in the following drivers:
> drivers/gpio/gpio-pisosr.c
> drivers/gpio/gpio-sim.c

Yes, please!

For GPIO part:

Acked-by: Bartosz Golaszewski <bartosz.golaszewski@xxxxxxxxxx>