diff options
Diffstat (limited to 'arch/arm/mach-omap2/pm.c')
| -rw-r--r-- | arch/arm/mach-omap2/pm.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/arch/arm/mach-omap2/pm.c b/arch/arm/mach-omap2/pm.c index abefbc4d8e0b..ea61c32957bd 100644 --- a/arch/arm/mach-omap2/pm.c +++ b/arch/arm/mach-omap2/pm.c | |||
| @@ -16,6 +16,7 @@ | |||
| 16 | #include <linux/opp.h> | 16 | #include <linux/opp.h> |
| 17 | #include <linux/export.h> | 17 | #include <linux/export.h> |
| 18 | #include <linux/suspend.h> | 18 | #include <linux/suspend.h> |
| 19 | #include <linux/cpu.h> | ||
| 19 | 20 | ||
| 20 | #include <asm/system_misc.h> | 21 | #include <asm/system_misc.h> |
| 21 | 22 | ||
| @@ -169,7 +170,15 @@ static int __init omap2_set_init_voltage(char *vdd_name, char *clk_name, | |||
| 169 | goto exit; | 170 | goto exit; |
| 170 | } | 171 | } |
| 171 | 172 | ||
| 172 | dev = omap_device_get_by_hwmod_name(oh_name); | 173 | if (!strncmp(oh_name, "mpu", 3)) |
| 174 | /* | ||
| 175 | * All current OMAPs share voltage rail and clock | ||
| 176 | * source, so CPU0 is used to represent the MPU-SS. | ||
| 177 | */ | ||
| 178 | dev = get_cpu_device(0); | ||
| 179 | else | ||
| 180 | dev = omap_device_get_by_hwmod_name(oh_name); | ||
| 181 | |||
| 173 | if (IS_ERR(dev)) { | 182 | if (IS_ERR(dev)) { |
| 174 | pr_err("%s: Unable to get dev pointer for hwmod %s\n", | 183 | pr_err("%s: Unable to get dev pointer for hwmod %s\n", |
| 175 | __func__, oh_name); | 184 | __func__, oh_name); |
| @@ -177,7 +186,7 @@ static int __init omap2_set_init_voltage(char *vdd_name, char *clk_name, | |||
| 177 | } | 186 | } |
| 178 | 187 | ||
| 179 | voltdm = voltdm_lookup(vdd_name); | 188 | voltdm = voltdm_lookup(vdd_name); |
| 180 | if (IS_ERR(voltdm)) { | 189 | if (!voltdm) { |
| 181 | pr_err("%s: unable to get vdd pointer for vdd_%s\n", | 190 | pr_err("%s: unable to get vdd pointer for vdd_%s\n", |
| 182 | __func__, vdd_name); | 191 | __func__, vdd_name); |
| 183 | goto exit; | 192 | goto exit; |
