Commit 1ba4c3cb authored by Russell King's avatar Russell King

ARM: update sa1100 to reflect PXA updates

Update sa1100 clockevents code to reflect what its later derivative
does with clockevents_calc_mult_shift().  Use OSSR_M* constants too.
Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
parent 111c7751
...@@ -92,7 +92,6 @@ sa1100_osmr0_set_mode(enum clock_event_mode mode, struct clock_event_device *c) ...@@ -92,7 +92,6 @@ sa1100_osmr0_set_mode(enum clock_event_mode mode, struct clock_event_device *c)
static struct clock_event_device ckevt_sa1100_osmr0 = { static struct clock_event_device ckevt_sa1100_osmr0 = {
.name = "osmr0", .name = "osmr0",
.features = CLOCK_EVT_FEAT_ONESHOT, .features = CLOCK_EVT_FEAT_ONESHOT,
.shift = 32,
.rating = 200, .rating = 200,
.set_next_event = sa1100_osmr0_set_next_event, .set_next_event = sa1100_osmr0_set_next_event,
.set_mode = sa1100_osmr0_set_mode, .set_mode = sa1100_osmr0_set_mode,
...@@ -120,14 +119,13 @@ static struct irqaction sa1100_timer_irq = { ...@@ -120,14 +119,13 @@ static struct irqaction sa1100_timer_irq = {
static void __init sa1100_timer_init(void) static void __init sa1100_timer_init(void)
{ {
OIER = 0; /* disable any timer interrupts */ OIER = 0;
OSSR = 0xf; /* clear status on all timers */ OSSR = OSSR_M0 | OSSR_M1 | OSSR_M2 | OSSR_M3;
init_fixed_sched_clock(&cd, sa1100_update_sched_clock, 32, init_fixed_sched_clock(&cd, sa1100_update_sched_clock, 32,
3686400, SC_MULT, SC_SHIFT); 3686400, SC_MULT, SC_SHIFT);
ckevt_sa1100_osmr0.mult = clockevents_calc_mult_shift(&ckevt_sa1100_osmr0, 3686400, 4);
div_sc(3686400, NSEC_PER_SEC, ckevt_sa1100_osmr0.shift);
ckevt_sa1100_osmr0.max_delta_ns = ckevt_sa1100_osmr0.max_delta_ns =
clockevent_delta2ns(0x7fffffff, &ckevt_sa1100_osmr0); clockevent_delta2ns(0x7fffffff, &ckevt_sa1100_osmr0);
ckevt_sa1100_osmr0.min_delta_ns = ckevt_sa1100_osmr0.min_delta_ns =
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment