summaryrefslogtreecommitdiff
path: root/arch/arm/cpu
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2012-12-13 20:48:37 +0000
committerTom Rini <trini@ti.com>2013-02-01 15:07:50 -0500
commitb4d51db86b783f0c6950803f8cced2c15d812327 (patch)
tree8680a1cdf26b9a5421ea9cfcc22848e79b86d811 /arch/arm/cpu
parent5f70714c2feb94318f2c2a153f4089e32f353548 (diff)
downloadu-boot-imx-b4d51db86b783f0c6950803f8cced2c15d812327.zip
u-boot-imx-b4d51db86b783f0c6950803f8cced2c15d812327.tar.gz
u-boot-imx-b4d51db86b783f0c6950803f8cced2c15d812327.tar.bz2
ixp: Move timestamp 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')
-rw-r--r--arch/arm/cpu/ixp/timer.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/arm/cpu/ixp/timer.c b/arch/arm/cpu/ixp/timer.c
index 0450b51..663d989 100644
--- a/arch/arm/cpu/ixp/timer.c
+++ b/arch/arm/cpu/ixp/timer.c
@@ -70,14 +70,14 @@ unsigned long long get_ticks(void)
if (readl(IXP425_OSST) & IXP425_OSST_TIMER_TS_PEND) {
/* rollover of timestamp timer register */
- gd->timestamp += (0xFFFFFFFF - gd->arch.lastinc) + now + 1;
+ gd->arch.timestamp += (0xFFFFFFFF - gd->arch.lastinc) + now + 1;
writel(IXP425_OSST_TIMER_TS_PEND, IXP425_OSST);
} else {
/* move stamp forward with absolut diff ticks */
- gd->timestamp += (now - gd->arch.lastinc);
+ gd->arch.timestamp += (now - gd->arch.lastinc);
}
gd->arch.lastinc = now;
- return gd->timestamp;
+ return gd->arch.timestamp;
}
@@ -86,7 +86,7 @@ void reset_timer_masked(void)
/* capture current timestamp counter */
gd->arch.lastinc = readl(IXP425_OSTS_B);
/* start "advancing" time stamp from 0 */
- gd->timestamp = 0;
+ gd->arch.timestamp = 0;
}
ulong get_timer_masked(void)