diff options
Diffstat (limited to 'arch/arm/mach-omap2/clockdomain.c')
-rw-r--r-- | arch/arm/mach-omap2/clockdomain.c | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/arch/arm/mach-omap2/clockdomain.c b/arch/arm/mach-omap2/clockdomain.c index a2142e0f1ef4..da74f719d874 100644 --- a/arch/arm/mach-omap2/clockdomain.c +++ b/arch/arm/mach-omap2/clockdomain.c | |||
@@ -13,7 +13,6 @@ | |||
13 | */ | 13 | */ |
14 | #undef DEBUG | 14 | #undef DEBUG |
15 | 15 | ||
16 | #include <linux/module.h> | ||
17 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
18 | #include <linux/device.h> | 17 | #include <linux/device.h> |
19 | #include <linux/list.h> | 18 | #include <linux/list.h> |
@@ -30,7 +29,6 @@ | |||
30 | #include "prm2xxx_3xxx.h" | 29 | #include "prm2xxx_3xxx.h" |
31 | #include "prm-regbits-24xx.h" | 30 | #include "prm-regbits-24xx.h" |
32 | #include "cm2xxx_3xxx.h" | 31 | #include "cm2xxx_3xxx.h" |
33 | #include "cm2xxx_3xxx.h" | ||
34 | 32 | ||
35 | #include <plat/clock.h> | 33 | #include <plat/clock.h> |
36 | #include <plat/powerdomain.h> | 34 | #include <plat/powerdomain.h> |
@@ -410,7 +408,7 @@ int clkdm_add_wkdep(struct clockdomain *clkdm1, struct clockdomain *clkdm2) | |||
410 | pr_debug("clockdomain: hardware will wake up %s when %s wakes " | 408 | pr_debug("clockdomain: hardware will wake up %s when %s wakes " |
411 | "up\n", clkdm1->name, clkdm2->name); | 409 | "up\n", clkdm1->name, clkdm2->name); |
412 | 410 | ||
413 | prm_set_mod_reg_bits((1 << clkdm2->dep_bit), | 411 | omap2_prm_set_mod_reg_bits((1 << clkdm2->dep_bit), |
414 | clkdm1->pwrdm.ptr->prcm_offs, PM_WKDEP); | 412 | clkdm1->pwrdm.ptr->prcm_offs, PM_WKDEP); |
415 | } | 413 | } |
416 | 414 | ||
@@ -445,7 +443,7 @@ int clkdm_del_wkdep(struct clockdomain *clkdm1, struct clockdomain *clkdm2) | |||
445 | pr_debug("clockdomain: hardware will no longer wake up %s " | 443 | pr_debug("clockdomain: hardware will no longer wake up %s " |
446 | "after %s wakes up\n", clkdm1->name, clkdm2->name); | 444 | "after %s wakes up\n", clkdm1->name, clkdm2->name); |
447 | 445 | ||
448 | prm_clear_mod_reg_bits((1 << clkdm2->dep_bit), | 446 | omap2_prm_clear_mod_reg_bits((1 << clkdm2->dep_bit), |
449 | clkdm1->pwrdm.ptr->prcm_offs, PM_WKDEP); | 447 | clkdm1->pwrdm.ptr->prcm_offs, PM_WKDEP); |
450 | } | 448 | } |
451 | 449 | ||
@@ -481,7 +479,7 @@ int clkdm_read_wkdep(struct clockdomain *clkdm1, struct clockdomain *clkdm2) | |||
481 | } | 479 | } |
482 | 480 | ||
483 | /* XXX It's faster to return the atomic wkdep_usecount */ | 481 | /* XXX It's faster to return the atomic wkdep_usecount */ |
484 | return prm_read_mod_bits_shift(clkdm1->pwrdm.ptr->prcm_offs, PM_WKDEP, | 482 | return omap2_prm_read_mod_bits_shift(clkdm1->pwrdm.ptr->prcm_offs, PM_WKDEP, |
485 | (1 << clkdm2->dep_bit)); | 483 | (1 << clkdm2->dep_bit)); |
486 | } | 484 | } |
487 | 485 | ||
@@ -515,7 +513,7 @@ int clkdm_clear_all_wkdeps(struct clockdomain *clkdm) | |||
515 | atomic_set(&cd->wkdep_usecount, 0); | 513 | atomic_set(&cd->wkdep_usecount, 0); |
516 | } | 514 | } |
517 | 515 | ||
518 | prm_clear_mod_reg_bits(mask, clkdm->pwrdm.ptr->prcm_offs, PM_WKDEP); | 516 | omap2_prm_clear_mod_reg_bits(mask, clkdm->pwrdm.ptr->prcm_offs, PM_WKDEP); |
519 | 517 | ||
520 | return 0; | 518 | return 0; |
521 | } | 519 | } |
@@ -554,7 +552,7 @@ int clkdm_add_sleepdep(struct clockdomain *clkdm1, struct clockdomain *clkdm2) | |||
554 | pr_debug("clockdomain: will prevent %s from sleeping if %s " | 552 | pr_debug("clockdomain: will prevent %s from sleeping if %s " |
555 | "is active\n", clkdm1->name, clkdm2->name); | 553 | "is active\n", clkdm1->name, clkdm2->name); |
556 | 554 | ||
557 | cm_set_mod_reg_bits((1 << clkdm2->dep_bit), | 555 | omap2_cm_set_mod_reg_bits((1 << clkdm2->dep_bit), |
558 | clkdm1->pwrdm.ptr->prcm_offs, | 556 | clkdm1->pwrdm.ptr->prcm_offs, |
559 | OMAP3430_CM_SLEEPDEP); | 557 | OMAP3430_CM_SLEEPDEP); |
560 | } | 558 | } |
@@ -597,7 +595,7 @@ int clkdm_del_sleepdep(struct clockdomain *clkdm1, struct clockdomain *clkdm2) | |||
597 | "sleeping if %s is active\n", clkdm1->name, | 595 | "sleeping if %s is active\n", clkdm1->name, |
598 | clkdm2->name); | 596 | clkdm2->name); |
599 | 597 | ||
600 | cm_clear_mod_reg_bits((1 << clkdm2->dep_bit), | 598 | omap2_cm_clear_mod_reg_bits((1 << clkdm2->dep_bit), |
601 | clkdm1->pwrdm.ptr->prcm_offs, | 599 | clkdm1->pwrdm.ptr->prcm_offs, |
602 | OMAP3430_CM_SLEEPDEP); | 600 | OMAP3430_CM_SLEEPDEP); |
603 | } | 601 | } |
@@ -640,7 +638,7 @@ int clkdm_read_sleepdep(struct clockdomain *clkdm1, struct clockdomain *clkdm2) | |||
640 | } | 638 | } |
641 | 639 | ||
642 | /* XXX It's faster to return the atomic sleepdep_usecount */ | 640 | /* XXX It's faster to return the atomic sleepdep_usecount */ |
643 | return prm_read_mod_bits_shift(clkdm1->pwrdm.ptr->prcm_offs, | 641 | return omap2_prm_read_mod_bits_shift(clkdm1->pwrdm.ptr->prcm_offs, |
644 | OMAP3430_CM_SLEEPDEP, | 642 | OMAP3430_CM_SLEEPDEP, |
645 | (1 << clkdm2->dep_bit)); | 643 | (1 << clkdm2->dep_bit)); |
646 | } | 644 | } |
@@ -678,7 +676,7 @@ int clkdm_clear_all_sleepdeps(struct clockdomain *clkdm) | |||
678 | atomic_set(&cd->sleepdep_usecount, 0); | 676 | atomic_set(&cd->sleepdep_usecount, 0); |
679 | } | 677 | } |
680 | 678 | ||
681 | prm_clear_mod_reg_bits(mask, clkdm->pwrdm.ptr->prcm_offs, | 679 | omap2_prm_clear_mod_reg_bits(mask, clkdm->pwrdm.ptr->prcm_offs, |
682 | OMAP3430_CM_SLEEPDEP); | 680 | OMAP3430_CM_SLEEPDEP); |
683 | 681 | ||
684 | return 0; | 682 | return 0; |
@@ -730,7 +728,7 @@ int omap2_clkdm_sleep(struct clockdomain *clkdm) | |||
730 | 728 | ||
731 | if (cpu_is_omap24xx()) { | 729 | if (cpu_is_omap24xx()) { |
732 | 730 | ||
733 | cm_set_mod_reg_bits(OMAP24XX_FORCESTATE_MASK, | 731 | omap2_cm_set_mod_reg_bits(OMAP24XX_FORCESTATE_MASK, |
734 | clkdm->pwrdm.ptr->prcm_offs, OMAP2_PM_PWSTCTRL); | 732 | clkdm->pwrdm.ptr->prcm_offs, OMAP2_PM_PWSTCTRL); |
735 | 733 | ||
736 | } else if (cpu_is_omap34xx() || cpu_is_omap44xx()) { | 734 | } else if (cpu_is_omap34xx() || cpu_is_omap44xx()) { |
@@ -774,7 +772,7 @@ int omap2_clkdm_wakeup(struct clockdomain *clkdm) | |||
774 | 772 | ||
775 | if (cpu_is_omap24xx()) { | 773 | if (cpu_is_omap24xx()) { |
776 | 774 | ||
777 | cm_clear_mod_reg_bits(OMAP24XX_FORCESTATE_MASK, | 775 | omap2_cm_clear_mod_reg_bits(OMAP24XX_FORCESTATE_MASK, |
778 | clkdm->pwrdm.ptr->prcm_offs, OMAP2_PM_PWSTCTRL); | 776 | clkdm->pwrdm.ptr->prcm_offs, OMAP2_PM_PWSTCTRL); |
779 | 777 | ||
780 | } else if (cpu_is_omap34xx() || cpu_is_omap44xx()) { | 778 | } else if (cpu_is_omap34xx() || cpu_is_omap44xx()) { |