diff options
author | Peter 'p2' De Schrijver <peter.de-schrijver@nokia.com> | 2008-10-15 11:13:47 -0400 |
---|---|---|
committer | Kevin Hilman <khilman@deeprootsystems.com> | 2009-09-02 18:08:23 -0400 |
commit | a23456e9b02b3fae0fc78cb33fad69803a50e5bc (patch) | |
tree | d74c8b6ed9600bc605fcd74ac4f3dfd5f6a52910 /arch/arm/mach-omap2/pm34xx.c | |
parent | fe617af716bc09cbbdd11ad820d5818017a9f481 (diff) |
OMAP: PM: Add closures to clkdm_for_each and pwrdm_for_each.
Add some infrastructure to easily iterate over clock and power
domains.
Signed-off-by: Peter 'p2' De Schrijver <peter.de-schrijver@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Diffstat (limited to 'arch/arm/mach-omap2/pm34xx.c')
-rw-r--r-- | arch/arm/mach-omap2/pm34xx.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/arm/mach-omap2/pm34xx.c b/arch/arm/mach-omap2/pm34xx.c index f1976242f997..331dfca93ed5 100644 --- a/arch/arm/mach-omap2/pm34xx.c +++ b/arch/arm/mach-omap2/pm34xx.c | |||
@@ -664,7 +664,7 @@ static void __init prcm_setup_regs(void) | |||
664 | omap3_d2d_idle(); | 664 | omap3_d2d_idle(); |
665 | } | 665 | } |
666 | 666 | ||
667 | static int __init pwrdms_setup(struct powerdomain *pwrdm) | 667 | static int __init pwrdms_setup(struct powerdomain *pwrdm, void *unused) |
668 | { | 668 | { |
669 | struct power_state *pwrst; | 669 | struct power_state *pwrst; |
670 | 670 | ||
@@ -689,7 +689,7 @@ static int __init pwrdms_setup(struct powerdomain *pwrdm) | |||
689 | * supported. Initiate sleep transition for other clockdomains, if | 689 | * supported. Initiate sleep transition for other clockdomains, if |
690 | * they are not used | 690 | * they are not used |
691 | */ | 691 | */ |
692 | static int __init clkdms_setup(struct clockdomain *clkdm) | 692 | static int __init clkdms_setup(struct clockdomain *clkdm, void *unused) |
693 | { | 693 | { |
694 | if (clkdm->flags & CLKDM_CAN_ENABLE_AUTO) | 694 | if (clkdm->flags & CLKDM_CAN_ENABLE_AUTO) |
695 | omap2_clkdm_allow_idle(clkdm); | 695 | omap2_clkdm_allow_idle(clkdm); |
@@ -722,13 +722,13 @@ static int __init omap3_pm_init(void) | |||
722 | goto err1; | 722 | goto err1; |
723 | } | 723 | } |
724 | 724 | ||
725 | ret = pwrdm_for_each(pwrdms_setup); | 725 | ret = pwrdm_for_each(pwrdms_setup, NULL); |
726 | if (ret) { | 726 | if (ret) { |
727 | printk(KERN_ERR "Failed to setup powerdomains\n"); | 727 | printk(KERN_ERR "Failed to setup powerdomains\n"); |
728 | goto err2; | 728 | goto err2; |
729 | } | 729 | } |
730 | 730 | ||
731 | (void) clkdm_for_each(clkdms_setup); | 731 | (void) clkdm_for_each(clkdms_setup, NULL); |
732 | 732 | ||
733 | mpu_pwrdm = pwrdm_lookup("mpu_pwrdm"); | 733 | mpu_pwrdm = pwrdm_lookup("mpu_pwrdm"); |
734 | if (mpu_pwrdm == NULL) { | 734 | if (mpu_pwrdm == NULL) { |