Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1285319

[PATCH] RTC/PCF85063: fix reading/setting time/date

From Juergen Borleis <jbe@pengutronix.de>
Newsgroups linux.kernel
Subject [PATCH] RTC/PCF85063: fix reading/setting time/date
Date 2015-12-07 15:00 +0100
Message-ID <qD4kW-56d-13@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


The PCF85063 RTC needs special treatment while setting or reading the
time/date:

 - while 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

Patch 1 and 2 change reading the time/date. I have kept them separately for
easier review. Squasching both into one patch render it more or less
unreadable.
Patch 3 changes setting the time/date.

Comments are welcome
Juergen

Please keep me on CC as I'm not subscribed to the list.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

[PATCH] RTC/PCF85063: fix reading/setting time/date Juergen Borleis <jbe@pengutronix.de> - 2015-12-07 15:00 +0100
  [PATCH 2/3] RTC/PCF85063: fix time/date reading (part II) Juergen Borleis <jbe@pengutronix.de> - 2015-12-07 15:00 +0100

csiph-web