diff options
author | Paul Walmsley <paul@pwsan.com> | 2012-10-21 09:01:11 +0200 |
---|---|---|
committer | Paul Walmsley <paul@pwsan.com> | 2012-10-21 09:01:11 +0200 |
commit | 4bd5259e53accda0fe295d3b25da348f4d5f4b09 (patch) | |
tree | 6ddacb5a75a8eda93916eaa917775ac36b561b81 /arch/arm/mach-omap2/prm2xxx.c | |
parent | ARM: OMAP2+: CM/hwmod: split CM functions into OMAP2, OMAP3-specific files (diff) | |
download | linux-4bd5259e53accda0fe295d3b25da348f4d5f4b09.tar.xz linux-4bd5259e53accda0fe295d3b25da348f4d5f4b09.zip |
ARM: OMAP2/3: clockdomain/PRM/CM: move the low-level clockdomain functions into PRM/CM
Move the low-level SoC-specific clockdomain control functions into
cm*.c and prm*.c. For example, OMAP2xxx low-level clockdomain
functions go into cm2xxx.c. Then remove the unnecessary
clockdomain*xxx*.c files.
The objective is to centralize low-level CM and PRM register accesses
into the cm*.[ch] and prm*.[ch] files, and then to export an OMAP
SoC-independent API to higher-level OMAP power management code.
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Vaibhav Hiremath <hvaibhav@ti.com>
Acked-by: Rajendra Nayak <rnayak@ti.com>
Reviewed-by: Russ Dill <Russ.Dill@ti.com>
Acked-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Diffstat (limited to 'arch/arm/mach-omap2/prm2xxx.c')
-rw-r--r-- | arch/arm/mach-omap2/prm2xxx.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/prm2xxx.c b/arch/arm/mach-omap2/prm2xxx.c index 218ef6a1f11e..9cdb4e5e3d80 100644 --- a/arch/arm/mach-omap2/prm2xxx.c +++ b/arch/arm/mach-omap2/prm2xxx.c @@ -24,10 +24,27 @@ #include "vp.h" #include "powerdomain.h" +#include "clockdomain.h" #include "prm2xxx.h" #include "cm2xxx_3xxx.h" #include "prm-regbits-24xx.h" +int omap2xxx_clkdm_sleep(struct clockdomain *clkdm) +{ + omap2_prm_set_mod_reg_bits(OMAP24XX_FORCESTATE_MASK, + clkdm->pwrdm.ptr->prcm_offs, + OMAP2_PM_PWSTCTRL); + return 0; +} + +int omap2xxx_clkdm_wakeup(struct clockdomain *clkdm) +{ + omap2_prm_clear_mod_reg_bits(OMAP24XX_FORCESTATE_MASK, + clkdm->pwrdm.ptr->prcm_offs, + OMAP2_PM_PWSTCTRL); + return 0; +} + struct pwrdm_ops omap2_pwrdm_operations = { .pwrdm_set_next_pwrst = omap2_pwrdm_set_next_pwrst, .pwrdm_read_next_pwrst = omap2_pwrdm_read_next_pwrst, |