hwmon: (pmbus/core) Add lock and unlock functions

Debugfs operations may set the page number, which must be done
atomically with the subsequent i2c operation. Lock the update_lock
in the debugfs functions and provide a function for pmbus drivers
to lock and unlock the update_lock.

Signed-off-by: Eddie James <eajames@linux.ibm.com>
Link: https://lore.kernel.org/r/20230412161526.252294-2-eajames@linux.ibm.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
Eddie James 2023-04-12 11:15:25 -05:00 • committed by Guenter Roeck
commit a7ac37183a
2 changed files with 32 additions and 0 deletions