Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1613471
| From | John Stultz <john.stultz@linaro.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 5/9] clocksource: h8300_timer8: Don't reset rate in ->set_state_oneshot() |
| Date | 2017-03-30 23:10 +0200 |
| Message-ID | <tqPup-3KZ-9@gated-at.bofh.it> (permalink) |
| References | <tqPup-3KZ-1@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
From: Nicolai Stange <nicstange@gmail.com>
With the upcoming NTP correction related rate adjustments to be implemented
in the clockevents core, the latter needs to get informed about every rate
change of a clockevent device made after its registration.
Currently, h8300_timer8 violates this requirement in that it registers its
clockevent device with the correct rate, but resets its ->mult and ->rate
values in timer8_clock_event_start(), called from its ->set_state_oneshot()
function.
It seems like
commit 4633f4cac85a ("clocksource/drivers/h8300: Cleanup startup and
remove module code."),
which introduced the rate initialization at registration, missed to remove
the manual setting of ->mult and ->shift from timer8_clock_event_start().
Purge the setting of ->mult, ->shift, ->min_delta_ns and ->max_delta_ns
from timer8_clock_event_start().
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>
Cc: Richard Cochran <richardcochran@gmail.com>
Cc: Prarit Bhargava <prarit@redhat.com>
Cc: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Nicolai Stange <nicstange@gmail.com>
Signed-off-by: John Stultz <john.stultz@linaro.org>
---
drivers/clocksource/h8300_timer8.c | 8 --------
1 file changed, 8 deletions(-)
diff --git a/drivers/clocksource/h8300_timer8.c b/drivers/clocksource/h8300_timer8.c
index 546bb18..804c489 100644
--- a/drivers/clocksource/h8300_timer8.c
+++ b/drivers/clocksource/h8300_timer8.c
@@ -101,15 +101,7 @@ static inline struct timer8_priv *ced_to_priv(struct clock_event_device *ced)
static void timer8_clock_event_start(struct timer8_priv *p, unsigned long delta)
{
- struct clock_event_device *ced = &p->ced;
-
timer8_start(p);
-
- ced->shift = 32;
- ced->mult = div_sc(p->rate, NSEC_PER_SEC, ced->shift);
- ced->max_delta_ns = clockevent_delta2ns(0xffff, ced);
- ced->min_delta_ns = clockevent_delta2ns(0x0001, ced);
-
timer8_set_next(p, delta);
}
--
2.7.4
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[GIT PULL][PATCH 0/9] Timekeeping changes for 4.12 John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 5/9] clocksource: h8300_timer8: Don't reset rate in ->set_state_oneshot() John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 3/9] clocksource: em_sti: Split clock prepare and enable steps John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 9/9] sysrq: Reset the watchdog timers while displaying high-resolution timers John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 7/9] MAINTAINERS: Add Stephen Boyd as timekeeping reviewer John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 8/9] timers, sched_clock: Update timeout for clock wrap John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 2/9] clocksource: sh_tmu: Compute rate before registration again John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 4/9] clocksource: em_sti: Compute rate before registration John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 1/9] clocksource: sh_cmt: Compute rate before registration again John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200 [PATCH 6/9] clockevents: Make clockevents_config() static John Stultz <john.stultz@linaro.org> - 2017-03-30 23:10 +0200
csiph-web