diff options
author | Adamski, Krzysztof (Nokia - PL/Wroclaw) | 2019-05-29 16:33:52 +0200 |
---|---|---|
committer | Guenter Roeck | 2019-06-06 03:36:27 +0200 |
commit | 38463721ec3c39acdabed3a89016ce6bb32a7543 (patch) | |
tree | 4154a311c4aee5f43ada5b80fc0e148bec4c5b58 /drivers/gpu/drm | |
parent | hwmon: (core) add thermal sensors only if dev->of_node is present (diff) | |
download | kernel-qcow2-linux-38463721ec3c39acdabed3a89016ce6bb32a7543.tar.gz kernel-qcow2-linux-38463721ec3c39acdabed3a89016ce6bb32a7543.tar.xz kernel-qcow2-linux-38463721ec3c39acdabed3a89016ce6bb32a7543.zip |
hwmon: (pmbus/core) mutex_lock write in pmbus_set_samples
update_lock is a mutex intended to protect write operations. It was not
taken, however, when _pmbus_write_word_data is called from
pmbus_set_samples() function which may cause problems especially when
some PMBUS_VIRT_* operation is implemented as a read-modify-write cycle.
This patch makes sure the lock is held during the operation.
Fixes: 49c4455dccf2 ("hwmon: (pmbus) Introduce PMBUS_VIRT_*_SAMPLES registers")
Signed-off-by: Krzysztof Adamski <krzysztof.adamski@nokia.com>
Reviewed-by: Alexander Sverdlin <alexander.sverdlin@nokia.com>
[groeck: Declared and initialized missing 'data' variable]
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'drivers/gpu/drm')
0 files changed, 0 insertions, 0 deletions