summaryrefslogtreecommitdiffstats
path: root/arch/arm/cpu/arm926ejs/at91
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2012-12-13 20:48:34 +0000
committerTom Rini <trini@ti.com>2013-02-01 15:07:50 -0500
commit66ee69234795c0596f84b25f06b7fbc2e8ed214c (patch)
treee67321700886c597591624f825379a2d76dbd99c /arch/arm/cpu/arm926ejs/at91
parent8ff43b03e9f38a6e136e2e20eec4e8b2eb4a1d3d (diff)
downloadblackbird-obmc-uboot-66ee69234795c0596f84b25f06b7fbc2e8ed214c.tar.gz
blackbird-obmc-uboot-66ee69234795c0596f84b25f06b7fbc2e8ed214c.zip
arm: Move tbl to arch_global_data
Move this field into arch_global_data and tidy up. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'arch/arm/cpu/arm926ejs/at91')
-rw-r--r--arch/arm/cpu/arm926ejs/at91/timer.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/arm/cpu/arm926ejs/at91/timer.c b/arch/arm/cpu/arm926ejs/at91/timer.c
index f691518c74..4443fefb64 100644
--- a/arch/arm/cpu/arm926ejs/at91/timer.c
+++ b/arch/arm/cpu/arm926ejs/at91/timer.c
@@ -80,7 +80,7 @@ int timer_init(void)
writel(TIMER_LOAD_VAL | AT91_PIT_MR_EN , &pit->mr);
gd->arch.timer_rate_hz = gd->arch.mck_rate_hz / 16;
- gd->arch.tbu = gd->tbl = 0;
+ gd->arch.tbu = gd->arch.tbl = 0;
return 0;
}
@@ -95,10 +95,10 @@ unsigned long long get_ticks(void)
ulong now = readl(&pit->piir);
/* increment tbu if tbl has rolled over */
- if (now < gd->tbl)
+ if (now < gd->arch.tbl)
gd->arch.tbu++;
- gd->tbl = now;
- return (((unsigned long long)gd->arch.tbu) << 32) | gd->tbl;
+ gd->arch.tbl = now;
+ return (((unsigned long long)gd->arch.tbu) << 32) | gd->arch.tbl;
}
void __udelay(unsigned long usec)
OpenPOWER on IntegriCloud