From: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
To: John Stultz <john.stultz@linaro.org>,
Thomas Gleixner <tglx@linutronix.de>,
Peter Zijlstra <peterz@infradead.org>,
linux-kernel@vger.kernel.org
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Subject: [PATCH 5/7] clocksource: add latch to clocksource
Date: Sat, 14 Sep 2013 12:47:59 -0700 [thread overview]
Message-ID: <1379188081-15613-6-git-send-email-mathieu.desnoyers@efficios.com> (raw)
In-Reply-To: <1379188081-15613-1-git-send-email-mathieu.desnoyers@efficios.com>
Add latch for data used by clock read operations. This is in preparation
for the clock latch synchronization scheme. "cycle_last" rely on
timekeeper seqlock synchronization, and will therefore need to be
latched.
Add:
- cycle_last_latch (array of 2 elements),
- read_latch(),
- update_latch().
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: John Stultz <john.stultz@linaro.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Peter Zijlstra <peterz@infradead.org>
---
include/linux/clocksource.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h
index dbbf8aa..ef9c2e5 100644
--- a/include/linux/clocksource.h
+++ b/include/linux/clocksource.h
@@ -180,6 +180,10 @@ struct clocksource {
#ifdef CONFIG_ARCH_CLOCKSOURCE_DATA
struct arch_clocksource_data archdata;
#endif
+ cycle_t (*read_latch)(struct clocksource *cs, int index);
+ void (*update_latch)(struct clocksource *cs, int oldindex,
+ int newindex);
+ cycle_t cycle_last_latch[2];
const char *name;
struct list_head list;
--
1.7.10.4
next prev parent reply other threads:[~2013-09-14 19:48 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-14 19:47 [RFC PATCH v2] timekeeper latch synchronization Mathieu Desnoyers
2013-09-14 19:47 ` [PATCH 1/7] Move ntp variables into struct timekeeper_ntp Mathieu Desnoyers
2013-09-14 19:47 ` [PATCH 2/7] Move PPS variables into struct timekeeper_pps Mathieu Desnoyers
2013-09-14 19:47 ` [PATCH 3/7] Move ntp structure into struct timekeeper Mathieu Desnoyers
2013-09-14 19:47 ` [PATCH 4/7] Pass struct timekeeper_ntp as parameter from timekeeper to ntp Mathieu Desnoyers
2013-09-14 19:47 ` Mathieu Desnoyers [this message]
2013-09-14 19:48 ` [PATCH 6/7] x86 tsc clock: implement clock latch Mathieu Desnoyers
2013-09-14 19:48 ` [PATCH 7/7] Introduce timekeeper latch synchronization Mathieu Desnoyers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1379188081-15613-6-git-send-email-mathieu.desnoyers@efficios.com \
--to=mathieu.desnoyers@efficios.com \
--cc=john.stultz@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=peterz@infradead.org \
--cc=tglx@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®