rtc: rs5c372: Fix reading from rtc when the oscillator got interrupted.
authorOliver.Rohe@wago.com <Oliver.Rohe@wago.com>
Fri, 8 Feb 2019 13:20:44 +0000 (13:20 +0000)
committerAlexandre Belloni <alexandre.belloni@bootlin.com>
Mon, 11 Feb 2019 08:41:21 +0000 (09:41 +0100)
commit09832dc0594ee264b658b7239d3d963b111e8faf
tree9dc60a2feeb2c94a6803a40ea5ebc794baf60a7b
parent7dd63ec076cfc1a7c46742e2d820554a6fb42fc6
rtc: rs5c372: Fix reading from rtc when the oscillator got interrupted.

When the oscillator of the rtc gets interrupted,
e.g. due to an empty battery, reading from the rtc will now return an error
and the oscillator bit will be cleared, once the rtc is successfully reset.

Signed-off-by: Oliver Rohe <oliver.rohe@wago.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
drivers/rtc/rtc-rs5c372.c