From: Nicolai Stange <nicstange@gmail.com>
To: John Stultz <john.stultz@linaro.org>
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>,
Thomas Gleixner <tglx@linutronix.de>,
Yoshinori Sato <ysato@users.sourceforge.jp>,
Magnus Damm <damm@opensource.se>,
linux-kernel@vger.kernel.org,
uclinux-h8-devel@lists.sourceforge.jp,
Nicolai Stange <nicstange@gmail.com>
Subject: [PATCH 6/6] clockevents: make clockevents_config() static
Date: Mon, 6 Feb 2017 22:12:04 +0100 [thread overview]
Message-ID: <20170206211204.25251-7-nicstange@gmail.com> (raw)
In-Reply-To: <20170206211204.25251-1-nicstange@gmail.com>
A clockevent device's rate should be configured before or at registration
and changed afterwards through clockevents_update_freq() only.
For the configuration at registration, we already have
clockevents_config_and_register().
Right now, there are no clockevents_config() users outside of the
clockevents core.
To mitigiate the risk of drivers errorneously reconfiguring their rates
through clockevents_config() *after* device registration, make
clockevents_config() static.
Signed-off-by: Nicolai Stange <nicstange@gmail.com>
---
include/linux/clockchips.h | 1 -
kernel/time/clockevents.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/include/linux/clockchips.h b/include/linux/clockchips.h
index 0d442e34c349..a116926598fd 100644
--- a/include/linux/clockchips.h
+++ b/include/linux/clockchips.h
@@ -182,7 +182,6 @@ extern u64 clockevent_delta2ns(unsigned long latch, struct clock_event_device *e
extern void clockevents_register_device(struct clock_event_device *dev);
extern int clockevents_unbind_device(struct clock_event_device *ced, int cpu);
-extern void clockevents_config(struct clock_event_device *dev, u32 freq);
extern void clockevents_config_and_register(struct clock_event_device *dev,
u32 freq, unsigned long min_delta,
unsigned long max_delta);
diff --git a/kernel/time/clockevents.c b/kernel/time/clockevents.c
index 97ac0951f164..4237e0744e26 100644
--- a/kernel/time/clockevents.c
+++ b/kernel/time/clockevents.c
@@ -468,7 +468,7 @@ void clockevents_register_device(struct clock_event_device *dev)
}
EXPORT_SYMBOL_GPL(clockevents_register_device);
-void clockevents_config(struct clock_event_device *dev, u32 freq)
+static void clockevents_config(struct clock_event_device *dev, u32 freq)
{
u64 sec;
--
2.11.1
prev parent reply other threads:[~2017-02-06 21:12 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-06 21:11 [PATCH 0/6] adapt clockevents frequencies to mono clock: prerequisites 1 Nicolai Stange
2017-02-06 21:11 ` [PATCH 1/6] clocksource: sh_cmt: compute rate before registration again Nicolai Stange
2017-02-14 4:35 ` John Stultz
2017-02-06 21:12 ` [PATCH 2/6] clocksource: sh_tmu: " Nicolai Stange
2017-02-06 21:12 ` [PATCH 3/6] clocksource: em_sti: split clock prepare and enable steps Nicolai Stange
2017-02-06 21:12 ` [PATCH 4/6] clocksource: em_sti: compute rate before registration Nicolai Stange
2017-02-06 21:12 ` [PATCH 5/6] clocksource: h8300_timer8: don't reset rate in ->set_state_oneshot() Nicolai Stange
2017-02-06 21:12 ` Nicolai Stange [this message]
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=20170206211204.25251-7-nicstange@gmail.com \
--to=nicstange@gmail.com \
--cc=damm@opensource.se \
--cc=daniel.lezcano@linaro.org \
--cc=john.stultz@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=uclinux-h8-devel@lists.sourceforge.jp \
--cc=ysato@users.sourceforge.jp \
/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®