[PATCH v2 0/7] regulator: core: locking cleanups, part 1/inf

From: Michał Mirosław
Date: Wed Aug 30 2023 - 14:55:56 EST


This series aims to reduce regulator locking code complexity. There is
a consmetic fix (patch #6) included (applies to unexpected/unlikely
errors only). v2 adds a regulator_lock_contended() function to make the
ww_mutex locking sequence easier to understand.

Michał Mirosław (7):
regulator/core: regulator_lock_nested: remove `lock`
regulator/core: regulator_lock_nested: skip extra lock for -EDEADLK
regulator/core: regulator_lock_nested: simplify nested locking
regulator/core: regulator_resolve_supply: remove gotos
regulator/core: regulator_lock_contended: wrap ww_mutex lock sequence
restart
regulator/core: regulator_lock_two: propagate error up
regulator/core: regulator_lock_two: remove duplicate locking code

drivers/regulator/core.c | 133 +++++++++++++++++----------------------
1 file changed, 59 insertions(+), 74 deletions(-)

--
2.39.2