summaryrefslogtreecommitdiff
path: root/arch/arm/plat-iop
diff options
context:
space:
mode:
authorMikael Pettersson <mikpe@it.uu.se>2009-10-29 11:46:55 -0700
committerDan Williams <dan.j.williams@intel.com>2009-10-29 11:46:55 -0700
commit980f2296b5a8dfe589f023fd34229dcfdcf280fa (patch)
tree033746bf0eb178c0c86ddb365a0d93645c3e930f /arch/arm/plat-iop
parent469d30448dad13600cdd246024f9db8e80614c45 (diff)
downloadlinux-3.10-980f2296b5a8dfe589f023fd34229dcfdcf280fa.tar.gz
linux-3.10-980f2296b5a8dfe589f023fd34229dcfdcf280fa.tar.bz2
linux-3.10-980f2296b5a8dfe589f023fd34229dcfdcf280fa.zip
iop: enable generic time
This updates the IOP platform to use the kernel's generic time framework. With clockevent support in place, this reduces to selecting GENERIC_TIME and removing the platform's private timer ->offset() operation (iop_gettimeoffset). Tested on n2100, compile-tested for all plat-iop machines. Signed-off-by: Mikael Pettersson <mikpe@it.uu.se> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'arch/arm/plat-iop')
-rw-r--r--arch/arm/plat-iop/time.c29
1 files changed, 0 insertions, 29 deletions
diff --git a/arch/arm/plat-iop/time.c b/arch/arm/plat-iop/time.c
index a550e96394a..aaaef3b4bc6 100644
--- a/arch/arm/plat-iop/time.c
+++ b/arch/arm/plat-iop/time.c
@@ -140,33 +140,6 @@ static void __init iop_clockevent_set_hz(struct clock_event_device *ce, unsigned
ce->name, ce->shift, ce->mult);
}
-static unsigned long ticks_per_usec;
-static unsigned long next_jiffy_time;
-
-unsigned long iop_gettimeoffset(void)
-{
- unsigned long offset, temp;
-
- /* enable cp6, if necessary, to avoid taking the overhead of an
- * undefined instruction trap
- */
- asm volatile (
- "mrc p15, 0, %0, c15, c1, 0\n\t"
- "tst %0, #(1 << 6)\n\t"
- "orreq %0, %0, #(1 << 6)\n\t"
- "mcreq p15, 0, %0, c15, c1, 0\n\t"
-#ifdef CONFIG_CPU_XSCALE
- "mrceq p15, 0, %0, c15, c1, 0\n\t"
- "moveq %0, %0\n\t"
- "subeq pc, pc, #4\n\t"
-#endif
- : "=r"(temp) : : "cc");
-
- offset = next_jiffy_time - read_tcr1();
-
- return offset / ticks_per_usec;
-}
-
static irqreturn_t
iop_timer_interrupt(int irq, void *dev_id)
{
@@ -196,8 +169,6 @@ void __init iop_init_time(unsigned long tick_rate)
u32 timer_ctl;
ticks_per_jiffy = DIV_ROUND_CLOSEST(tick_rate, HZ);
- ticks_per_usec = tick_rate / 1000000;
- next_jiffy_time = 0xffffffff;
iop_tick_rate = tick_rate;
timer_ctl = IOP_TMR_EN | IOP_TMR_PRIVILEGED |