[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1455015447-13886-1-git-send-email-jbe@pengutronix.de>
Date: Tue, 9 Feb 2016 11:57:24 +0100
From: Juergen Borleis <jbe@...gutronix.de>
To: rtc-linux@...glegroups.com
Cc: Alessandro Zummo <a.zummo@...ertech.it>,
Alexandre Belloni <alexandre.belloni@...e-electrons.com>,
linux-kernel@...r.kernel.org, kernel@...gutronix.de
Subject: [PATCH v2] RTC/PCF85063: fix reading/setting time/date
The PCF85063 RTC needs special treatment while setting or reading the
time/date:
- when reading the 7 time/date registers they are blocked from updating by
the 'one second' pulse internally. So reading all time/date registers
should happen in one turn to ensure reading is an atomic operation
- to let setting the time/date be an atomic operation as well, the clock
dividers must be kept in reset state to avoid a 'one second' pulse during
writing the 7 time/date registers
Changes from v1:
- using high level I2C access functions instead of the low level i2c_transfer()
to simplify the code
Comments are welcome
Juergen
Please keep me on CC since I'm not subscribed to the list.
Powered by blists - more mailing lists