diff options
author | Tero Kristo <t-kristo@ti.com> | 2014-11-21 08:51:37 -0500 |
---|---|---|
committer | Tero Kristo <t-kristo@ti.com> | 2015-03-31 14:26:50 -0400 |
commit | 425dc8b2dff222ffd88f31f589dc647409cae0ce (patch) | |
tree | 43a3919b84c1119fda11fb22b48c828bc934eda6 /arch/arm | |
parent | 48e0c1148d18de677f1b2aec179f36fb7c1e3839 (diff) |
ARM: OMAP2+: CM: move SoC specific init calls within a generic API
This gets rid of need for some exported driver APIs, and simplifies the
initialization of the CM driver. Done in preparation to make CM a
separate driver. The init data is now also passed to the SoC specific
implementations, allowing future expansion to add feature flags etc.
Signed-off-by: Tero Kristo <t-kristo@ti.com>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-omap2/cm2xxx.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-omap2/cm2xxx.h | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap2/cm33xx.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-omap2/cm33xx.h | 3 | ||||
-rw-r--r-- | arch/arm/mach-omap2/cm3xxx.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-omap2/cm3xxx.h | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap2/cm44xx.h | 2 | ||||
-rw-r--r-- | arch/arm/mach-omap2/cm_common.c | 64 | ||||
-rw-r--r-- | arch/arm/mach-omap2/cminst44xx.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-omap2/io.c | 16 | ||||
-rw-r--r-- | arch/arm/mach-omap2/prm_common.c | 8 |
11 files changed, 75 insertions, 34 deletions
diff --git a/arch/arm/mach-omap2/cm2xxx.c b/arch/arm/mach-omap2/cm2xxx.c index f18c844353bc..3e5fd3587eb1 100644 --- a/arch/arm/mach-omap2/cm2xxx.c +++ b/arch/arm/mach-omap2/cm2xxx.c | |||
@@ -393,9 +393,8 @@ static struct cm_ll_data omap2xxx_cm_ll_data = { | |||
393 | .wait_module_ready = &omap2xxx_cm_wait_module_ready, | 393 | .wait_module_ready = &omap2xxx_cm_wait_module_ready, |
394 | }; | 394 | }; |
395 | 395 | ||
396 | int __init omap2xxx_cm_init(void) | 396 | int __init omap2xxx_cm_init(const struct omap_prcm_init_data *data) |
397 | { | 397 | { |
398 | omap2_cm_base_init(); | ||
399 | return cm_register(&omap2xxx_cm_ll_data); | 398 | return cm_register(&omap2xxx_cm_ll_data); |
400 | } | 399 | } |
401 | 400 | ||
diff --git a/arch/arm/mach-omap2/cm2xxx.h b/arch/arm/mach-omap2/cm2xxx.h index 83b6c597b0e1..7b8c79c0ce27 100644 --- a/arch/arm/mach-omap2/cm2xxx.h +++ b/arch/arm/mach-omap2/cm2xxx.h | |||
@@ -63,7 +63,7 @@ extern u32 omap2xxx_cm_get_core_pll_config(void); | |||
63 | extern void omap2xxx_cm_set_mod_dividers(u32 mpu, u32 dsp, u32 gfx, u32 core, | 63 | extern void omap2xxx_cm_set_mod_dividers(u32 mpu, u32 dsp, u32 gfx, u32 core, |
64 | u32 mdm); | 64 | u32 mdm); |
65 | 65 | ||
66 | extern int __init omap2xxx_cm_init(void); | 66 | int __init omap2xxx_cm_init(const struct omap_prcm_init_data *data); |
67 | 67 | ||
68 | #endif | 68 | #endif |
69 | 69 | ||
diff --git a/arch/arm/mach-omap2/cm33xx.c b/arch/arm/mach-omap2/cm33xx.c index 221bca3fbfa6..7b181f929525 100644 --- a/arch/arm/mach-omap2/cm33xx.c +++ b/arch/arm/mach-omap2/cm33xx.c | |||
@@ -352,9 +352,8 @@ static struct cm_ll_data am33xx_cm_ll_data = { | |||
352 | .module_disable = &am33xx_cm_module_disable, | 352 | .module_disable = &am33xx_cm_module_disable, |
353 | }; | 353 | }; |
354 | 354 | ||
355 | int __init am33xx_cm_init(void) | 355 | int __init am33xx_cm_init(const struct omap_prcm_init_data *data) |
356 | { | 356 | { |
357 | omap2_cm_base_init(); | ||
358 | return cm_register(&am33xx_cm_ll_data); | 357 | return cm_register(&am33xx_cm_ll_data); |
359 | } | 358 | } |
360 | 359 | ||
diff --git a/arch/arm/mach-omap2/cm33xx.h b/arch/arm/mach-omap2/cm33xx.h index 046b4b2bc9d9..a91f7d282455 100644 --- a/arch/arm/mach-omap2/cm33xx.h +++ b/arch/arm/mach-omap2/cm33xx.h | |||
@@ -19,6 +19,7 @@ | |||
19 | 19 | ||
20 | #include "cm.h" | 20 | #include "cm.h" |
21 | #include "cm-regbits-33xx.h" | 21 | #include "cm-regbits-33xx.h" |
22 | #include "prcm-common.h" | ||
22 | 23 | ||
23 | /* CM base address */ | 24 | /* CM base address */ |
24 | #define AM33XX_CM_BASE 0x44e00000 | 25 | #define AM33XX_CM_BASE 0x44e00000 |
@@ -374,6 +375,6 @@ | |||
374 | 375 | ||
375 | 376 | ||
376 | #ifndef __ASSEMBLER__ | 377 | #ifndef __ASSEMBLER__ |
377 | int am33xx_cm_init(void); | 378 | int am33xx_cm_init(const struct omap_prcm_init_data *data); |
378 | #endif /* ASSEMBLER */ | 379 | #endif /* ASSEMBLER */ |
379 | #endif | 380 | #endif |
diff --git a/arch/arm/mach-omap2/cm3xxx.c b/arch/arm/mach-omap2/cm3xxx.c index 88e6cb619861..187fa4386718 100644 --- a/arch/arm/mach-omap2/cm3xxx.c +++ b/arch/arm/mach-omap2/cm3xxx.c | |||
@@ -671,10 +671,9 @@ static struct cm_ll_data omap3xxx_cm_ll_data = { | |||
671 | .wait_module_ready = &omap3xxx_cm_wait_module_ready, | 671 | .wait_module_ready = &omap3xxx_cm_wait_module_ready, |
672 | }; | 672 | }; |
673 | 673 | ||
674 | int __init omap3xxx_cm_init(void) | 674 | int __init omap3xxx_cm_init(const struct omap_prcm_init_data *data) |
675 | { | 675 | { |
676 | omap2_clk_legacy_provider_init(TI_CLKM_CM, cm_base + OMAP3430_IVA2_MOD); | 676 | omap2_clk_legacy_provider_init(TI_CLKM_CM, cm_base + OMAP3430_IVA2_MOD); |
677 | omap2_cm_base_init(); | ||
678 | return cm_register(&omap3xxx_cm_ll_data); | 677 | return cm_register(&omap3xxx_cm_ll_data); |
679 | } | 678 | } |
680 | 679 | ||
diff --git a/arch/arm/mach-omap2/cm3xxx.h b/arch/arm/mach-omap2/cm3xxx.h index 734a8581c0c4..bc444e2080a1 100644 --- a/arch/arm/mach-omap2/cm3xxx.h +++ b/arch/arm/mach-omap2/cm3xxx.h | |||
@@ -72,7 +72,7 @@ extern void omap3_cm_save_context(void); | |||
72 | extern void omap3_cm_restore_context(void); | 72 | extern void omap3_cm_restore_context(void); |
73 | extern void omap3_cm_save_scratchpad_contents(u32 *ptr); | 73 | extern void omap3_cm_save_scratchpad_contents(u32 *ptr); |
74 | 74 | ||
75 | extern int __init omap3xxx_cm_init(void); | 75 | int __init omap3xxx_cm_init(const struct omap_prcm_init_data *data); |
76 | 76 | ||
77 | #endif | 77 | #endif |
78 | 78 | ||
diff --git a/arch/arm/mach-omap2/cm44xx.h b/arch/arm/mach-omap2/cm44xx.h index ad6e263c5a6b..309a4c913448 100644 --- a/arch/arm/mach-omap2/cm44xx.h +++ b/arch/arm/mach-omap2/cm44xx.h | |||
@@ -23,6 +23,6 @@ | |||
23 | #define OMAP4_CM_CLKSTCTRL 0x0000 | 23 | #define OMAP4_CM_CLKSTCTRL 0x0000 |
24 | #define OMAP4_CM_STATICDEP 0x0004 | 24 | #define OMAP4_CM_STATICDEP 0x0004 |
25 | 25 | ||
26 | int omap4_cm_init(void); | 26 | int omap4_cm_init(const struct omap_prcm_init_data *data); |
27 | 27 | ||
28 | #endif | 28 | #endif |
diff --git a/arch/arm/mach-omap2/cm_common.c b/arch/arm/mach-omap2/cm_common.c index 32af8fc749f0..ff24fdfb3bb2 100644 --- a/arch/arm/mach-omap2/cm_common.c +++ b/arch/arm/mach-omap2/cm_common.c | |||
@@ -20,6 +20,7 @@ | |||
20 | 20 | ||
21 | #include "cm2xxx.h" | 21 | #include "cm2xxx.h" |
22 | #include "cm3xxx.h" | 22 | #include "cm3xxx.h" |
23 | #include "cm33xx.h" | ||
23 | #include "cm44xx.h" | 24 | #include "cm44xx.h" |
24 | #include "clock.h" | 25 | #include "clock.h" |
25 | 26 | ||
@@ -37,6 +38,7 @@ void __iomem *cm_base; | |||
37 | void __iomem *cm2_base; | 38 | void __iomem *cm2_base; |
38 | 39 | ||
39 | #define CM_NO_CLOCKS 0x1 | 40 | #define CM_NO_CLOCKS 0x1 |
41 | #define CM_SINGLE_INSTANCE 0x2 | ||
40 | 42 | ||
41 | /** | 43 | /** |
42 | * omap2_set_globals_cm - set the CM/CM2 base addresses (for early use) | 44 | * omap2_set_globals_cm - set the CM/CM2 base addresses (for early use) |
@@ -218,21 +220,32 @@ int cm_unregister(struct cm_ll_data *cld) | |||
218 | return 0; | 220 | return 0; |
219 | } | 221 | } |
220 | 222 | ||
221 | static struct omap_prcm_init_data cm_data = { | 223 | #if defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5) || \ |
224 | defined(CONFIG_SOC_DRA7XX) | ||
225 | static struct omap_prcm_init_data cm_data __initdata = { | ||
222 | .index = TI_CLKM_CM, | 226 | .index = TI_CLKM_CM, |
227 | .init = omap4_cm_init, | ||
223 | }; | 228 | }; |
224 | 229 | ||
225 | static struct omap_prcm_init_data cm2_data = { | 230 | static struct omap_prcm_init_data cm2_data __initdata = { |
226 | .index = TI_CLKM_CM2, | 231 | .index = TI_CLKM_CM2, |
232 | .init = omap4_cm_init, | ||
227 | }; | 233 | }; |
234 | #endif | ||
228 | 235 | ||
229 | static struct omap_prcm_init_data omap2_prcm_data = { | 236 | #ifdef CONFIG_ARCH_OMAP2 |
237 | static struct omap_prcm_init_data omap2_prcm_data __initdata = { | ||
230 | .index = TI_CLKM_CM, | 238 | .index = TI_CLKM_CM, |
231 | .flags = CM_NO_CLOCKS, | 239 | .init = omap2xxx_cm_init, |
240 | .flags = CM_NO_CLOCKS | CM_SINGLE_INSTANCE, | ||
232 | }; | 241 | }; |
242 | #endif | ||
233 | 243 | ||
234 | static struct omap_prcm_init_data omap3_cm_data = { | 244 | #ifdef CONFIG_ARCH_OMAP3 |
245 | static struct omap_prcm_init_data omap3_cm_data __initdata = { | ||
235 | .index = TI_CLKM_CM, | 246 | .index = TI_CLKM_CM, |
247 | .init = omap3xxx_cm_init, | ||
248 | .flags = CM_SINGLE_INSTANCE, | ||
236 | 249 | ||
237 | /* | 250 | /* |
238 | * IVA2 offset is a negative value, must offset the cm_base address | 251 | * IVA2 offset is a negative value, must offset the cm_base address |
@@ -240,28 +253,53 @@ static struct omap_prcm_init_data omap3_cm_data = { | |||
240 | */ | 253 | */ |
241 | .offset = -OMAP3430_IVA2_MOD, | 254 | .offset = -OMAP3430_IVA2_MOD, |
242 | }; | 255 | }; |
256 | #endif | ||
243 | 257 | ||
244 | static struct omap_prcm_init_data am3_prcm_data = { | 258 | #if defined(CONFIG_SOC_AM33XX) || defined(CONFIG_SOC_TI81XX) |
259 | static struct omap_prcm_init_data am3_prcm_data __initdata = { | ||
245 | .index = TI_CLKM_CM, | 260 | .index = TI_CLKM_CM, |
246 | .flags = CM_NO_CLOCKS, | 261 | .flags = CM_NO_CLOCKS | CM_SINGLE_INSTANCE, |
262 | .init = am33xx_cm_init, | ||
247 | }; | 263 | }; |
264 | #endif | ||
248 | 265 | ||
249 | static struct omap_prcm_init_data am4_prcm_data = { | 266 | #ifdef CONFIG_SOC_AM43XX |
267 | static struct omap_prcm_init_data am4_prcm_data __initdata = { | ||
250 | .index = TI_CLKM_CM, | 268 | .index = TI_CLKM_CM, |
251 | .flags = CM_NO_CLOCKS, | 269 | .flags = CM_NO_CLOCKS | CM_SINGLE_INSTANCE, |
270 | .init = omap4_cm_init, | ||
252 | }; | 271 | }; |
272 | #endif | ||
253 | 273 | ||
254 | static const struct of_device_id omap_cm_dt_match_table[] = { | 274 | static const struct of_device_id omap_cm_dt_match_table[] __initconst = { |
275 | #ifdef CONFIG_ARCH_OMAP2 | ||
255 | { .compatible = "ti,omap2-prcm", .data = &omap2_prcm_data }, | 276 | { .compatible = "ti,omap2-prcm", .data = &omap2_prcm_data }, |
277 | #endif | ||
278 | #ifdef CONFIG_ARCH_OMAP3 | ||
256 | { .compatible = "ti,omap3-cm", .data = &omap3_cm_data }, | 279 | { .compatible = "ti,omap3-cm", .data = &omap3_cm_data }, |
280 | #endif | ||
281 | #ifdef CONFIG_ARCH_OMAP4 | ||
257 | { .compatible = "ti,omap4-cm1", .data = &cm_data }, | 282 | { .compatible = "ti,omap4-cm1", .data = &cm_data }, |
258 | { .compatible = "ti,omap4-cm2", .data = &cm2_data }, | 283 | { .compatible = "ti,omap4-cm2", .data = &cm2_data }, |
284 | #endif | ||
285 | #ifdef CONFIG_SOC_OMAP5 | ||
259 | { .compatible = "ti,omap5-cm-core-aon", .data = &cm_data }, | 286 | { .compatible = "ti,omap5-cm-core-aon", .data = &cm_data }, |
260 | { .compatible = "ti,omap5-cm-core", .data = &cm2_data }, | 287 | { .compatible = "ti,omap5-cm-core", .data = &cm2_data }, |
288 | #endif | ||
289 | #ifdef CONFIG_SOC_DRA7XX | ||
261 | { .compatible = "ti,dra7-cm-core-aon", .data = &cm_data }, | 290 | { .compatible = "ti,dra7-cm-core-aon", .data = &cm_data }, |
262 | { .compatible = "ti,dra7-cm-core", .data = &cm2_data }, | 291 | { .compatible = "ti,dra7-cm-core", .data = &cm2_data }, |
292 | #endif | ||
293 | #ifdef CONFIG_SOC_AM33XX | ||
263 | { .compatible = "ti,am3-prcm", .data = &am3_prcm_data }, | 294 | { .compatible = "ti,am3-prcm", .data = &am3_prcm_data }, |
295 | #endif | ||
296 | #ifdef CONFIG_SOC_AM43XX | ||
264 | { .compatible = "ti,am4-prcm", .data = &am4_prcm_data }, | 297 | { .compatible = "ti,am4-prcm", .data = &am4_prcm_data }, |
298 | #endif | ||
299 | #ifdef CONFIG_SOC_TI81XX | ||
300 | { .compatible = "ti,dm814-prcm", .data = &am3_prcm_data }, | ||
301 | { .compatible = "ti,dm816-prcm", .data = &am3_prcm_data }, | ||
302 | #endif | ||
265 | { } | 303 | { } |
266 | }; | 304 | }; |
267 | 305 | ||
@@ -293,6 +331,12 @@ int __init omap2_cm_base_init(void) | |||
293 | cm2_base = mem + data->offset; | 331 | cm2_base = mem + data->offset; |
294 | 332 | ||
295 | data->mem = mem; | 333 | data->mem = mem; |
334 | |||
335 | data->np = np; | ||
336 | |||
337 | if (data->init && (data->flags & CM_SINGLE_INSTANCE || | ||
338 | (cm_base && cm2_base))) | ||
339 | data->init(data); | ||
296 | } | 340 | } |
297 | 341 | ||
298 | return 0; | 342 | return 0; |
diff --git a/arch/arm/mach-omap2/cminst44xx.c b/arch/arm/mach-omap2/cminst44xx.c index 4aed22dbe558..2c0e07ed6b99 100644 --- a/arch/arm/mach-omap2/cminst44xx.c +++ b/arch/arm/mach-omap2/cminst44xx.c | |||
@@ -514,9 +514,8 @@ static struct cm_ll_data omap4xxx_cm_ll_data = { | |||
514 | .module_disable = &omap4_cminst_module_disable, | 514 | .module_disable = &omap4_cminst_module_disable, |
515 | }; | 515 | }; |
516 | 516 | ||
517 | int __init omap4_cm_init(void) | 517 | int __init omap4_cm_init(const struct omap_prcm_init_data *data) |
518 | { | 518 | { |
519 | omap2_cm_base_init(); | ||
520 | omap_cm_base_init(); | 519 | omap_cm_base_init(); |
521 | 520 | ||
522 | return cm_register(&omap4xxx_cm_ll_data); | 521 | return cm_register(&omap4xxx_cm_ll_data); |
diff --git a/arch/arm/mach-omap2/io.c b/arch/arm/mach-omap2/io.c index 7632dfead166..c3fa739ab4c8 100644 --- a/arch/arm/mach-omap2/io.c +++ b/arch/arm/mach-omap2/io.c | |||
@@ -387,7 +387,6 @@ void __init omap2420_init_early(void) | |||
387 | omap2_control_base_init(); | 387 | omap2_control_base_init(); |
388 | omap2xxx_check_revision(); | 388 | omap2xxx_check_revision(); |
389 | omap2_prcm_base_init(); | 389 | omap2_prcm_base_init(); |
390 | omap2xxx_cm_init(); | ||
391 | omap2xxx_voltagedomains_init(); | 390 | omap2xxx_voltagedomains_init(); |
392 | omap242x_powerdomains_init(); | 391 | omap242x_powerdomains_init(); |
393 | omap242x_clockdomains_init(); | 392 | omap242x_clockdomains_init(); |
@@ -414,7 +413,6 @@ void __init omap2430_init_early(void) | |||
414 | omap2_control_base_init(); | 413 | omap2_control_base_init(); |
415 | omap2xxx_check_revision(); | 414 | omap2xxx_check_revision(); |
416 | omap2_prcm_base_init(); | 415 | omap2_prcm_base_init(); |
417 | omap2xxx_cm_init(); | ||
418 | omap2xxx_voltagedomains_init(); | 416 | omap2xxx_voltagedomains_init(); |
419 | omap243x_powerdomains_init(); | 417 | omap243x_powerdomains_init(); |
420 | omap243x_clockdomains_init(); | 418 | omap243x_clockdomains_init(); |
@@ -454,8 +452,11 @@ void __init omap3_init_early(void) | |||
454 | omap3xxx_check_revision(); | 452 | omap3xxx_check_revision(); |
455 | omap3xxx_check_features(); | 453 | omap3xxx_check_features(); |
456 | omap2_prcm_base_init(); | 454 | omap2_prcm_base_init(); |
457 | omap3xxx_prm_init(NULL); | 455 | /* XXX: remove these once OMAP3 is DT only */ |
458 | omap3xxx_cm_init(); | 456 | if (!of_have_populated_dt()) { |
457 | omap3xxx_prm_init(NULL); | ||
458 | omap3xxx_cm_init(NULL); | ||
459 | } | ||
459 | omap3xxx_voltagedomains_init(); | 460 | omap3xxx_voltagedomains_init(); |
460 | omap3xxx_powerdomains_init(); | 461 | omap3xxx_powerdomains_init(); |
461 | omap3xxx_clockdomains_init(); | 462 | omap3xxx_clockdomains_init(); |
@@ -553,7 +554,6 @@ void __init ti814x_init_early(void) | |||
553 | omap3xxx_check_revision(); | 554 | omap3xxx_check_revision(); |
554 | ti81xx_check_features(); | 555 | ti81xx_check_features(); |
555 | omap2_prcm_base_init(); | 556 | omap2_prcm_base_init(); |
556 | am33xx_cm_init(); | ||
557 | omap3xxx_voltagedomains_init(); | 557 | omap3xxx_voltagedomains_init(); |
558 | omap3xxx_powerdomains_init(); | 558 | omap3xxx_powerdomains_init(); |
559 | ti81xx_clockdomains_init(); | 559 | ti81xx_clockdomains_init(); |
@@ -571,7 +571,6 @@ void __init ti816x_init_early(void) | |||
571 | omap3xxx_check_revision(); | 571 | omap3xxx_check_revision(); |
572 | ti81xx_check_features(); | 572 | ti81xx_check_features(); |
573 | omap2_prcm_base_init(); | 573 | omap2_prcm_base_init(); |
574 | am33xx_cm_init(); | ||
575 | omap3xxx_voltagedomains_init(); | 574 | omap3xxx_voltagedomains_init(); |
576 | omap3xxx_powerdomains_init(); | 575 | omap3xxx_powerdomains_init(); |
577 | ti81xx_clockdomains_init(); | 576 | ti81xx_clockdomains_init(); |
@@ -591,7 +590,6 @@ void __init am33xx_init_early(void) | |||
591 | omap3xxx_check_revision(); | 590 | omap3xxx_check_revision(); |
592 | am33xx_check_features(); | 591 | am33xx_check_features(); |
593 | omap2_prcm_base_init(); | 592 | omap2_prcm_base_init(); |
594 | am33xx_cm_init(); | ||
595 | am33xx_powerdomains_init(); | 593 | am33xx_powerdomains_init(); |
596 | am33xx_clockdomains_init(); | 594 | am33xx_clockdomains_init(); |
597 | am33xx_hwmod_init(); | 595 | am33xx_hwmod_init(); |
@@ -614,7 +612,6 @@ void __init am43xx_init_early(void) | |||
614 | omap3xxx_check_revision(); | 612 | omap3xxx_check_revision(); |
615 | am33xx_check_features(); | 613 | am33xx_check_features(); |
616 | omap2_prcm_base_init(); | 614 | omap2_prcm_base_init(); |
617 | omap4_cm_init(); | ||
618 | am43xx_powerdomains_init(); | 615 | am43xx_powerdomains_init(); |
619 | am43xx_clockdomains_init(); | 616 | am43xx_clockdomains_init(); |
620 | am43xx_hwmod_init(); | 617 | am43xx_hwmod_init(); |
@@ -640,7 +637,6 @@ void __init omap4430_init_early(void) | |||
640 | omap4xxx_check_revision(); | 637 | omap4xxx_check_revision(); |
641 | omap4xxx_check_features(); | 638 | omap4xxx_check_features(); |
642 | omap2_prcm_base_init(); | 639 | omap2_prcm_base_init(); |
643 | omap4_cm_init(); | ||
644 | omap4_pm_init_early(); | 640 | omap4_pm_init_early(); |
645 | omap44xx_voltagedomains_init(); | 641 | omap44xx_voltagedomains_init(); |
646 | omap44xx_powerdomains_init(); | 642 | omap44xx_powerdomains_init(); |
@@ -670,7 +666,6 @@ void __init omap5_init_early(void) | |||
670 | omap4_pm_init_early(); | 666 | omap4_pm_init_early(); |
671 | omap2_prcm_base_init(); | 667 | omap2_prcm_base_init(); |
672 | omap5xxx_check_revision(); | 668 | omap5xxx_check_revision(); |
673 | omap4_cm_init(); | ||
674 | omap54xx_voltagedomains_init(); | 669 | omap54xx_voltagedomains_init(); |
675 | omap54xx_powerdomains_init(); | 670 | omap54xx_powerdomains_init(); |
676 | omap54xx_clockdomains_init(); | 671 | omap54xx_clockdomains_init(); |
@@ -697,7 +692,6 @@ void __init dra7xx_init_early(void) | |||
697 | omap4_pm_init_early(); | 692 | omap4_pm_init_early(); |
698 | omap2_prcm_base_init(); | 693 | omap2_prcm_base_init(); |
699 | dra7xxx_check_revision(); | 694 | dra7xxx_check_revision(); |
700 | omap4_cm_init(); | ||
701 | dra7xx_powerdomains_init(); | 695 | dra7xx_powerdomains_init(); |
702 | dra7xx_clockdomains_init(); | 696 | dra7xx_clockdomains_init(); |
703 | dra7xx_hwmod_init(); | 697 | dra7xx_hwmod_init(); |
diff --git a/arch/arm/mach-omap2/prm_common.c b/arch/arm/mach-omap2/prm_common.c index a834124c5309..3e932b8b8ce9 100644 --- a/arch/arm/mach-omap2/prm_common.c +++ b/arch/arm/mach-omap2/prm_common.c | |||
@@ -770,7 +770,13 @@ int __init omap2_prm_base_init(void) | |||
770 | 770 | ||
771 | int __init omap2_prcm_base_init(void) | 771 | int __init omap2_prcm_base_init(void) |
772 | { | 772 | { |
773 | return omap2_prm_base_init(); | 773 | int ret; |
774 | |||
775 | ret = omap2_prm_base_init(); | ||
776 | if (ret) | ||
777 | return ret; | ||
778 | |||
779 | return omap2_cm_base_init(); | ||
774 | } | 780 | } |
775 | 781 | ||
776 | /** | 782 | /** |