Skip to content

Commit

Permalink
ARM: PXA: update clock source registration
Browse files Browse the repository at this point in the history
In d7e81c2 (clocksource: Add clocksource_register_hz/khz interface) new
interfaces were added which simplify (and optimize) the selection of the
divisor shift/mult constants.  Switch over to using this new interface.

Tested-by: Eric Miao <eric.y.miao@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Russell King committed Dec 22, 2010
1 parent 8437c25 commit f62ae0c
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions arch/arm/mach-pxa/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,6 @@ static struct clocksource cksrc_pxa_oscr0 = {
.rating = 200,
.read = pxa_read_oscr,
.mask = CLOCKSOURCE_MASK(32),
.shift = 20,
.flags = CLOCK_SOURCE_IS_CONTINUOUS,
};

Expand Down Expand Up @@ -155,12 +154,9 @@ static void __init pxa_timer_init(void)
clockevent_delta2ns(MIN_OSCR_DELTA * 2, &ckevt_pxa_osmr0) + 1;
ckevt_pxa_osmr0.cpumask = cpumask_of(0);

cksrc_pxa_oscr0.mult =
clocksource_hz2mult(clock_tick_rate, cksrc_pxa_oscr0.shift);

setup_irq(IRQ_OST0, &pxa_ost0_irq);

clocksource_register(&cksrc_pxa_oscr0);
clocksource_register_hz(&cksrc_pxa_oscr0, clock_tick_rate);
clockevents_register_device(&ckevt_pxa_osmr0);
}

Expand Down

0 comments on commit f62ae0c

Please sign in to comment.