summaryrefslogtreecommitdiff
path: root/arch/arm/cpu/armv7
diff options
context:
space:
mode:
authorTom Rini <trini@ti.com>2013-08-28 09:00:28 -0400
committerTom Rini <trini@ti.com>2013-11-01 15:30:22 -0400
commit155d424a9a0228e2f38ce21a92b20c31896d61d2 (patch)
tree787d83dfc4399221718262f540b61a961d9e48e0 /arch/arm/cpu/armv7
parent5d4d38d1cc89f523118219b1a38713d94fe72b3b (diff)
downloadu-boot-imx-155d424a9a0228e2f38ce21a92b20c31896d61d2.zip
u-boot-imx-155d424a9a0228e2f38ce21a92b20c31896d61d2.tar.gz
u-boot-imx-155d424a9a0228e2f38ce21a92b20c31896d61d2.tar.bz2
am33xx, davinci: Create and use <asm/davinci_rtc.h>
Create a common header file for the RTC IP block that is shared between davinci and am33xx. Signed-off-by: Tom Rini <trini@ti.com>
Diffstat (limited to 'arch/arm/cpu/armv7')
-rw-r--r--arch/arm/cpu/armv7/am33xx/board.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/arm/cpu/armv7/am33xx/board.c b/arch/arm/cpu/armv7/am33xx/board.c
index a31bf40..453effa 100644
--- a/arch/arm/cpu/armv7/am33xx/board.c
+++ b/arch/arm/cpu/armv7/am33xx/board.c
@@ -32,6 +32,7 @@
#include <linux/usb/gadget.h>
#include <linux/usb/musb.h>
#include <asm/omap_musb.h>
+#include <asm/davinci_rtc.h>
DECLARE_GLOBAL_DATA_PTR;
@@ -150,15 +151,15 @@ __weak void am33xx_spl_board_init(void)
static void rtc32k_enable(void)
{
- struct rtc_regs *rtc = (struct rtc_regs *)RTC_BASE;
+ struct davinci_rtc *rtc = (struct davinci_rtc *)RTC_BASE;
/*
* Unlock the RTC's registers. For more details please see the
* RTC_SS section of the TRM. In order to unlock we need to
* write these specific values (keys) in this order.
*/
- writel(0x83e70b13, &rtc->kick0r);
- writel(0x95a4f1e0, &rtc->kick1r);
+ writel(RTC_KICK0R_WE, &rtc->kick0r);
+ writel(RTC_KICK1R_WE, &rtc->kick1r);
/* Enable the RTC 32K OSC by setting bits 3 and 6. */
writel((1 << 3) | (1 << 6), &rtc->osc);