Input: atkbd - use guard notation when acquiring mutex
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Sun, 25 Aug 2024 05:16:07 +0000 (22:16 -0700)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Fri, 6 Sep 2024 05:53:11 +0000 (22:53 -0700)
commit934976f61eceab661cce492831448e01d1b89e4b
tree7c9ee229f8ec81328c68bebf39a1ea83bb4c37d4
parentd5322d537c2355fb2e7b1b0362a21e9c87c4b585
Input: atkbd - use guard notation when acquiring mutex

This makes the code more compact and error handling more robust
by ensuring that mutexes are released in all code paths when control
leaves critical section.

Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20240825051627.2848495-4-dmitry.torokhov@gmail.com
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/keyboard/atkbd.c