diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2010-08-19 08:08:05 -0400 |
---|---|---|
committer | Uwe Kleine-König <u.kleine-koenig@pengutronix.de> | 2010-09-27 06:52:59 -0400 |
commit | bd45140d98b60c8ddef8f053ad1645dc1572a15a (patch) | |
tree | e8bf678b277d6cb3b316c309213c95c8e645b59f | |
parent | f2b8901d3efe5e1603c8f6a102b2d5c851c108c6 (diff) |
ARM: mx3/imx35: Add EPIT support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Michael Grzeschik <m.grzeschik@pengutronix.de>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
-rw-r--r-- | arch/arm/mach-mx3/Kconfig | 1 | ||||
-rw-r--r-- | arch/arm/mach-mx3/clock-imx35.c | 13 |
2 files changed, 10 insertions, 4 deletions
diff --git a/arch/arm/mach-mx3/Kconfig b/arch/arm/mach-mx3/Kconfig index 2ae10885635a..5cee1a5c4bd2 100644 --- a/arch/arm/mach-mx3/Kconfig +++ b/arch/arm/mach-mx3/Kconfig | |||
@@ -9,6 +9,7 @@ config ARCH_MX35 | |||
9 | bool | 9 | bool |
10 | select ARCH_MXC_IOMUX_V3 | 10 | select ARCH_MXC_IOMUX_V3 |
11 | select ARCH_MXC_AUDMUX_V2 | 11 | select ARCH_MXC_AUDMUX_V2 |
12 | select HAVE_EPIT | ||
12 | 13 | ||
13 | comment "MX3 platforms:" | 14 | comment "MX3 platforms:" |
14 | 15 | ||
diff --git a/arch/arm/mach-mx3/clock-imx35.c b/arch/arm/mach-mx3/clock-imx35.c index 7a62e744a8b0..f11ef990120c 100644 --- a/arch/arm/mach-mx3/clock-imx35.c +++ b/arch/arm/mach-mx3/clock-imx35.c | |||
@@ -364,8 +364,8 @@ DEFINE_CLOCK(cspi2_clk, 1, CCM_CGR0, 12, get_rate_ipg, NULL); | |||
364 | DEFINE_CLOCK(ect_clk, 0, CCM_CGR0, 14, get_rate_ipg, NULL); | 364 | DEFINE_CLOCK(ect_clk, 0, CCM_CGR0, 14, get_rate_ipg, NULL); |
365 | DEFINE_CLOCK(edio_clk, 0, CCM_CGR0, 16, NULL, NULL); | 365 | DEFINE_CLOCK(edio_clk, 0, CCM_CGR0, 16, NULL, NULL); |
366 | DEFINE_CLOCK(emi_clk, 0, CCM_CGR0, 18, get_rate_ipg, NULL); | 366 | DEFINE_CLOCK(emi_clk, 0, CCM_CGR0, 18, get_rate_ipg, NULL); |
367 | DEFINE_CLOCK(epit1_clk, 0, CCM_CGR0, 20, get_rate_ipg_per, NULL); | 367 | DEFINE_CLOCK(epit1_clk, 0, CCM_CGR0, 20, get_rate_ipg, NULL); |
368 | DEFINE_CLOCK(epit2_clk, 1, CCM_CGR0, 22, get_rate_ipg_per, NULL); | 368 | DEFINE_CLOCK(epit2_clk, 1, CCM_CGR0, 22, get_rate_ipg, NULL); |
369 | DEFINE_CLOCK(esai_clk, 0, CCM_CGR0, 24, NULL, NULL); | 369 | DEFINE_CLOCK(esai_clk, 0, CCM_CGR0, 24, NULL, NULL); |
370 | DEFINE_CLOCK(esdhc1_clk, 0, CCM_CGR0, 26, get_rate_sdhc, NULL); | 370 | DEFINE_CLOCK(esdhc1_clk, 0, CCM_CGR0, 26, get_rate_sdhc, NULL); |
371 | DEFINE_CLOCK(esdhc2_clk, 1, CCM_CGR0, 28, get_rate_sdhc, NULL); | 371 | DEFINE_CLOCK(esdhc2_clk, 1, CCM_CGR0, 28, get_rate_sdhc, NULL); |
@@ -456,8 +456,8 @@ static struct clk_lookup lookups[] = { | |||
456 | _REGISTER_CLOCK(NULL, "ect", ect_clk) | 456 | _REGISTER_CLOCK(NULL, "ect", ect_clk) |
457 | _REGISTER_CLOCK(NULL, "edio", edio_clk) | 457 | _REGISTER_CLOCK(NULL, "edio", edio_clk) |
458 | _REGISTER_CLOCK(NULL, "emi", emi_clk) | 458 | _REGISTER_CLOCK(NULL, "emi", emi_clk) |
459 | _REGISTER_CLOCK(NULL, "epit", epit1_clk) | 459 | _REGISTER_CLOCK("imx-epit.0", NULL, epit1_clk) |
460 | _REGISTER_CLOCK(NULL, "epit", epit2_clk) | 460 | _REGISTER_CLOCK("imx-epit.1", NULL, epit2_clk) |
461 | _REGISTER_CLOCK(NULL, "esai", esai_clk) | 461 | _REGISTER_CLOCK(NULL, "esai", esai_clk) |
462 | _REGISTER_CLOCK(NULL, "sdhc", esdhc1_clk) | 462 | _REGISTER_CLOCK(NULL, "sdhc", esdhc1_clk) |
463 | _REGISTER_CLOCK(NULL, "sdhc", esdhc2_clk) | 463 | _REGISTER_CLOCK(NULL, "sdhc", esdhc2_clk) |
@@ -535,8 +535,13 @@ int __init mx35_clocks_init() | |||
535 | __raw_writel(cgr2, CCM_BASE + CCM_CGR2); | 535 | __raw_writel(cgr2, CCM_BASE + CCM_CGR2); |
536 | __raw_writel(cgr3, CCM_BASE + CCM_CGR3); | 536 | __raw_writel(cgr3, CCM_BASE + CCM_CGR3); |
537 | 537 | ||
538 | #ifdef CONFIG_MXC_USE_EPIT | ||
539 | epit_timer_init(&epit1_clk, | ||
540 | MX35_IO_ADDRESS(MX35_EPIT1_BASE_ADDR), MX35_INT_EPIT1); | ||
541 | #else | ||
538 | mxc_timer_init(&gpt_clk, | 542 | mxc_timer_init(&gpt_clk, |
539 | MX35_IO_ADDRESS(MX35_GPT1_BASE_ADDR), MX35_INT_GPT); | 543 | MX35_IO_ADDRESS(MX35_GPT1_BASE_ADDR), MX35_INT_GPT); |
544 | #endif | ||
540 | 545 | ||
541 | return 0; | 546 | return 0; |
542 | } | 547 | } |