]> git.baikalelectronics.ru Git - kernel.git/commit
rtc: rv3028: factorize EERD bit handling
authorAlexandre Belloni <alexandre.belloni@bootlin.com>
Fri, 9 Oct 2020 15:31:00 +0000 (17:31 +0200)
committerAlexandre Belloni <alexandre.belloni@bootlin.com>
Thu, 15 Oct 2020 10:09:35 +0000 (12:09 +0200)
commit557a7d56a95db4acc7a48c490d0c7d3262c7546f
treee5ce8990ee1ae0af06ba3d53b275a1a44eb7f6be
parenta6387aeca1acfdae9dfeba2f058742ce9faa6991
rtc: rv3028: factorize EERD bit handling

Both rv3028_eeprom_write and rv3028_eeprom_read enable EERD before sending
commands to the EEPROM and restore it afterwards. Factorize this code.

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