diff options
author | Mark A. Greer <mgreer@mvista.com> | 2009-04-15 15:39:23 -0400 |
---|---|---|
committer | Kevin Hilman <khilman@deeprootsystems.com> | 2009-05-26 11:14:59 -0400 |
commit | 66e0c3991c5a1735dd8add77ab8aff5005f57681 (patch) | |
tree | 9437a2cea15b2abbdd3e440f9be3809311f3d30d /arch/arm | |
parent | b9ab12797e74d93a3656ea0bf5591f8b3e094fd5 (diff) |
davinci: Add clock init call to common init routine
All of the davinci SoCs need to call davinci_clk_init() so
put the call in the common init routine.
Signed-off-by: Mark A. Greer <mgreer@mvista.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-davinci/common.c | 9 | ||||
-rw-r--r-- | arch/arm/mach-davinci/dm355.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-davinci/dm644x.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-davinci/dm646x.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-davinci/include/mach/common.h | 1 |
5 files changed, 13 insertions, 3 deletions
diff --git a/arch/arm/mach-davinci/common.c b/arch/arm/mach-davinci/common.c index 29b3a8d51211..2e5b888e6ca6 100644 --- a/arch/arm/mach-davinci/common.c +++ b/arch/arm/mach-davinci/common.c | |||
@@ -17,6 +17,8 @@ | |||
17 | #include <mach/common.h> | 17 | #include <mach/common.h> |
18 | #include <mach/cputype.h> | 18 | #include <mach/cputype.h> |
19 | 19 | ||
20 | #include "clock.h" | ||
21 | |||
20 | struct davinci_soc_info davinci_soc_info; | 22 | struct davinci_soc_info davinci_soc_info; |
21 | EXPORT_SYMBOL(davinci_soc_info); | 23 | EXPORT_SYMBOL(davinci_soc_info); |
22 | 24 | ||
@@ -75,6 +77,13 @@ void __init davinci_common_init(struct davinci_soc_info *soc_info) | |||
75 | davinci_soc_info.cpu_id = dip->cpu_id; | 77 | davinci_soc_info.cpu_id = dip->cpu_id; |
76 | pr_info("DaVinci %s variant 0x%x\n", dip->name, dip->variant); | 78 | pr_info("DaVinci %s variant 0x%x\n", dip->name, dip->variant); |
77 | 79 | ||
80 | if (davinci_soc_info.cpu_clks) { | ||
81 | ret = davinci_clk_init(davinci_soc_info.cpu_clks); | ||
82 | |||
83 | if (ret != 0) | ||
84 | goto err; | ||
85 | } | ||
86 | |||
78 | return; | 87 | return; |
79 | 88 | ||
80 | err: | 89 | err: |
diff --git a/arch/arm/mach-davinci/dm355.c b/arch/arm/mach-davinci/dm355.c index 0f724c060084..e93840a814ed 100644 --- a/arch/arm/mach-davinci/dm355.c +++ b/arch/arm/mach-davinci/dm355.c | |||
@@ -551,12 +551,12 @@ static struct davinci_soc_info davinci_soc_info_dm355 = { | |||
551 | .jtag_id_base = IO_ADDRESS(0x01c40028), | 551 | .jtag_id_base = IO_ADDRESS(0x01c40028), |
552 | .ids = dm355_ids, | 552 | .ids = dm355_ids, |
553 | .ids_num = ARRAY_SIZE(dm355_ids), | 553 | .ids_num = ARRAY_SIZE(dm355_ids), |
554 | .cpu_clks = dm355_clks, | ||
554 | }; | 555 | }; |
555 | 556 | ||
556 | void __init dm355_init(void) | 557 | void __init dm355_init(void) |
557 | { | 558 | { |
558 | davinci_common_init(&davinci_soc_info_dm355); | 559 | davinci_common_init(&davinci_soc_info_dm355); |
559 | davinci_clk_init(dm355_clks); | ||
560 | davinci_mux_register(dm355_pins, ARRAY_SIZE(dm355_pins));; | 560 | davinci_mux_register(dm355_pins, ARRAY_SIZE(dm355_pins));; |
561 | } | 561 | } |
562 | 562 | ||
diff --git a/arch/arm/mach-davinci/dm644x.c b/arch/arm/mach-davinci/dm644x.c index 9bcd98c6820b..648160c2960d 100644 --- a/arch/arm/mach-davinci/dm644x.c +++ b/arch/arm/mach-davinci/dm644x.c | |||
@@ -491,12 +491,12 @@ static struct davinci_soc_info davinci_soc_info_dm644x = { | |||
491 | .jtag_id_base = IO_ADDRESS(0x01c40028), | 491 | .jtag_id_base = IO_ADDRESS(0x01c40028), |
492 | .ids = dm644x_ids, | 492 | .ids = dm644x_ids, |
493 | .ids_num = ARRAY_SIZE(dm644x_ids), | 493 | .ids_num = ARRAY_SIZE(dm644x_ids), |
494 | .cpu_clks = dm644x_clks, | ||
494 | }; | 495 | }; |
495 | 496 | ||
496 | void __init dm644x_init(void) | 497 | void __init dm644x_init(void) |
497 | { | 498 | { |
498 | davinci_common_init(&davinci_soc_info_dm644x); | 499 | davinci_common_init(&davinci_soc_info_dm644x); |
499 | davinci_clk_init(dm644x_clks); | ||
500 | davinci_mux_register(dm644x_pins, ARRAY_SIZE(dm644x_pins)); | 500 | davinci_mux_register(dm644x_pins, ARRAY_SIZE(dm644x_pins)); |
501 | } | 501 | } |
502 | 502 | ||
diff --git a/arch/arm/mach-davinci/dm646x.c b/arch/arm/mach-davinci/dm646x.c index cd86bb78e0c1..7cf9705be9ce 100644 --- a/arch/arm/mach-davinci/dm646x.c +++ b/arch/arm/mach-davinci/dm646x.c | |||
@@ -471,12 +471,12 @@ static struct davinci_soc_info davinci_soc_info_dm646x = { | |||
471 | .jtag_id_base = IO_ADDRESS(0x01c40028), | 471 | .jtag_id_base = IO_ADDRESS(0x01c40028), |
472 | .ids = dm646x_ids, | 472 | .ids = dm646x_ids, |
473 | .ids_num = ARRAY_SIZE(dm646x_ids), | 473 | .ids_num = ARRAY_SIZE(dm646x_ids), |
474 | .cpu_clks = dm646x_clks, | ||
474 | }; | 475 | }; |
475 | 476 | ||
476 | void __init dm646x_init(void) | 477 | void __init dm646x_init(void) |
477 | { | 478 | { |
478 | davinci_common_init(&davinci_soc_info_dm646x); | 479 | davinci_common_init(&davinci_soc_info_dm646x); |
479 | davinci_clk_init(dm646x_clks); | ||
480 | davinci_mux_register(dm646x_pins, ARRAY_SIZE(dm646x_pins)); | 480 | davinci_mux_register(dm646x_pins, ARRAY_SIZE(dm646x_pins)); |
481 | } | 481 | } |
482 | 482 | ||
diff --git a/arch/arm/mach-davinci/include/mach/common.h b/arch/arm/mach-davinci/include/mach/common.h index ece1cd42738f..97782a765882 100644 --- a/arch/arm/mach-davinci/include/mach/common.h +++ b/arch/arm/mach-davinci/include/mach/common.h | |||
@@ -33,6 +33,7 @@ struct davinci_soc_info { | |||
33 | void __iomem *jtag_id_base; | 33 | void __iomem *jtag_id_base; |
34 | struct davinci_id *ids; | 34 | struct davinci_id *ids; |
35 | unsigned long ids_num; | 35 | unsigned long ids_num; |
36 | struct davinci_clk *cpu_clks; | ||
36 | }; | 37 | }; |
37 | 38 | ||
38 | extern struct davinci_soc_info davinci_soc_info; | 39 | extern struct davinci_soc_info davinci_soc_info; |