Skip to content

cleanup: provide and use a locking guard for nested read semaphores

Bartosz Golaszewski linux-gpio lkml 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3cleanup: provide DEFINE_LOCK_GUARD_ARGS()include/linux/cleanup.h+6 -01 reply
2/3locking/rwsem: provide a lock guard for down_read_nested()include/linux/rwsem.h+6 -00 replies
3/3gpiolib: pin GPIO devices in place during descriptor lookupdrivers/gpio/gpiolib.c+24 -180 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/3] cleanup: provide and use a locking guard for nested read semaphores

From: Bartosz Golaszewski <[email protected]>

This series adds cleanup infrastructure for defining locking guards with additional arguments, then uses it to provide a guard for down_read_nested() with RW semaphores and finally uses the new guard in GPIOLIB.

Patch 3/3 of this series is a second attempt, this time with lockdep-correct nesting.

The first two patches can either be picked up into the relevant maintainer trees and I can pull an immutable tag or can be acked and go directly through the GPIO tree.

Bartosz Golaszewski (3):
cleanup: provide DEFINE_LOCK_GUARD_ARGS() locking/rwsem: provide a lock guard for down_read_nested()
gpiolib: pin GPIO devices in place during descriptor lookup

 drivers/gpio/gpiolib.c  | 42 +++++++++++++++++++++++------------------
 include/linux/cleanup.h |  6 ++++++
 include/linux/rwsem.h   |  6 ++++++
 3 files changed, 36 insertions(+), 18 deletions(-)
Signature · 1 line
2.40.1