Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit bc352686 authored by Krzysztof Kozlowski's avatar Krzysztof Kozlowski Committed by Sebastian Reichel
Browse files

power_supply: max17042: Use regmap_update_bits instead read and write



Consolidate regmap_read() and regmap_write() into one
regmap_update_bits() call. This is more readable and safer because
regmap's mutex will prevent any concurrent access to modified registers
(the concurrent access could happen through max17042_init_chip() in
scheduled work).

Signed-off-by: default avatarKrzysztof Kozlowski <k.kozlowski@samsung.com>
Signed-off-by: default avatarSebastian Reichel <sre@kernel.org>
parent 52fa74ee
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment