summaryrefslogtreecommitdiff
path: root/arch/arm/include
diff options
context:
space:
mode:
authorAndrew Ruder <andrew.ruder@elecsyscorp.com>2014-08-12 09:26:00 -0500
committerStefano Babic <sbabic@denx.de>2014-09-16 12:51:46 +0200
commit93a0ea501e1eca1ae5d7d2624906b656c765e5e8 (patch)
treebb92988867941e0b54333a825ff5bea04e6e6bc5 /arch/arm/include
parent4c97f16911e229f6d5bbea5bee52449916e5fa92 (diff)
downloadu-boot-imx-93a0ea501e1eca1ae5d7d2624906b656c765e5e8.zip
u-boot-imx-93a0ea501e1eca1ae5d7d2624906b656c765e5e8.tar.gz
u-boot-imx-93a0ea501e1eca1ae5d7d2624906b656c765e5e8.tar.bz2
arm: mx31: use common timer functions
This patch moves mx31 to the common timer functions added in commit 8dfafdd - Introduce common timer functions <Rob Herring> The (removed) mx31 timer code (specifically __udelay()) could deadlock at the 32-bit boundary of get_ticks(). get_ticks() returned a 32-bit value cast up to a 64-bit value. If get_ticks() + tmo in __udelay() crossed the 32-bit boundary, the while condition became unconditionally true and locks the processor. Rather than patch the specific mx31 issues, simply move everything over to the common code. Signed-off-by: Andrew Ruder <andrew.ruder@elecsyscorp.com> Cc: Marek Vasut <marex@denx.de> Cc: Linus Walleij <linus.walleij@linaro.org> Cc: Wolfgang Denk <wd@denx.de> Cc: Fabio Estevam <fabio.estevam@freescale.com> Cc: Helmut Raiger <helmut.raiger@hale.at>
Diffstat (limited to 'arch/arm/include')
-rw-r--r--arch/arm/include/asm/arch-mx31/imx-regs.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/arch/arm/include/asm/arch-mx31/imx-regs.h b/arch/arm/include/asm/arch-mx31/imx-regs.h
index f23350e..71ebd24 100644
--- a/arch/arm/include/asm/arch-mx31/imx-regs.h
+++ b/arch/arm/include/asm/arch-mx31/imx-regs.h
@@ -909,9 +909,19 @@ struct esdc_regs {
#define MXC_CSPIPERIOD_32KHZ (1 << 15)
#define MAX_SPI_BYTES 4
+
#define MXC_SPI_BASE_ADDRESSES \
0x43fa4000, \
0x50010000, \
0x53f84000,
+/*
+ * Generic timer support
+ */
+#ifdef CONFIG_MX31_CLK32
+#define CONFIG_SYS_TIMER_RATE CONFIG_MX31_CLK32
+#else
+#define CONFIG_SYS_TIMER_RATE 32768
+#endif
+
#endif /* __ASM_ARCH_MX31_IMX_REGS_H */