rtc: rv3029: remove race condition when update STATUS
authorAlexandre Belloni <alexandre.belloni@bootlin.com>
Sat, 14 Dec 2019 22:10:10 +0000 (23:10 +0100)
committerAlexandre Belloni <alexandre.belloni@bootlin.com>
Wed, 18 Dec 2019 09:37:52 +0000 (10:37 +0100)
commit54c5970df449103ec1181b92d41a2d14a79fe562
treea0add8400bd06b4f4d9c2045b5b3da32e9108072
parent609e97fe31a4d1acf7bc0411277e43a4de13db44
rtc: rv3029: remove race condition when update STATUS

There is no lock preventing concurrent access to the status register from
bth the rtc subsystem and the hwmon subsystem. Use regmap_update_bits to
ensure updating RV3029_STATUS is properly locked.

Link: https://lore.kernel.org/r/20191214221022.622482-5-alexandre.belloni@bootlin.com
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
drivers/rtc/rtc-rv3029c2.c