diff options
Diffstat (limited to 'arch/arm/plat-iop/time.c')
-rw-r--r-- | arch/arm/plat-iop/time.c | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/arch/arm/plat-iop/time.c b/arch/arm/plat-iop/time.c index a550e96394ab..aaaef3b4bc65 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 | |||
140 | ce->name, ce->shift, ce->mult); | 140 | ce->name, ce->shift, ce->mult); |
141 | } | 141 | } |
142 | 142 | ||
143 | static unsigned long ticks_per_usec; | ||
144 | static unsigned long next_jiffy_time; | ||
145 | |||
146 | unsigned long iop_gettimeoffset(void) | ||
147 | { | ||
148 | unsigned long offset, temp; | ||
149 | |||
150 | /* enable cp6, if necessary, to avoid taking the overhead of an | ||
151 | * undefined instruction trap | ||
152 | */ | ||
153 | asm volatile ( | ||
154 | "mrc p15, 0, %0, c15, c1, 0\n\t" | ||
155 | "tst %0, #(1 << 6)\n\t" | ||
156 | "orreq %0, %0, #(1 << 6)\n\t" | ||
157 | "mcreq p15, 0, %0, c15, c1, 0\n\t" | ||
158 | #ifdef CONFIG_CPU_XSCALE | ||
159 | "mrceq p15, 0, %0, c15, c1, 0\n\t" | ||
160 | "moveq %0, %0\n\t" | ||
161 | "subeq pc, pc, #4\n\t" | ||
162 | #endif | ||
163 | : "=r"(temp) : : "cc"); | ||
164 | |||
165 | offset = next_jiffy_time - read_tcr1(); | ||
166 | |||
167 | return offset / ticks_per_usec; | ||
168 | } | ||
169 | |||
170 | static irqreturn_t | 143 | static irqreturn_t |
171 | iop_timer_interrupt(int irq, void *dev_id) | 144 | iop_timer_interrupt(int irq, void *dev_id) |
172 | { | 145 | { |
@@ -196,8 +169,6 @@ void __init iop_init_time(unsigned long tick_rate) | |||
196 | u32 timer_ctl; | 169 | u32 timer_ctl; |
197 | 170 | ||
198 | ticks_per_jiffy = DIV_ROUND_CLOSEST(tick_rate, HZ); | 171 | ticks_per_jiffy = DIV_ROUND_CLOSEST(tick_rate, HZ); |
199 | ticks_per_usec = tick_rate / 1000000; | ||
200 | next_jiffy_time = 0xffffffff; | ||
201 | iop_tick_rate = tick_rate; | 172 | iop_tick_rate = tick_rate; |
202 | 173 | ||
203 | timer_ctl = IOP_TMR_EN | IOP_TMR_PRIVILEGED | | 174 | timer_ctl = IOP_TMR_EN | IOP_TMR_PRIVILEGED | |