diff options
author | Rafael J. Wysocki <rjw@sisk.pl> | 2012-09-24 07:30:39 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rjw@sisk.pl> | 2012-09-24 07:30:39 -0400 |
commit | 59f3b797c50ad078cde59050cd1a7c4cb8e5a8e5 (patch) | |
tree | 717f583332096d83c8dda504ce040c35badb395c | |
parent | fa373abbbd01109b849fa331da73ee17748def66 (diff) | |
parent | 1bae9958f8b0162aadf79e2ac20bcc9a409bb661 (diff) |
Merge branch 'pm-cpufreq'
* pm-cpufreq:
cpufreq: OMAP: Check IS_ERR() instead of NULL for omap_device_get_by_hwmod_name
-rw-r--r-- | drivers/cpufreq/omap-cpufreq.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/cpufreq/omap-cpufreq.c b/drivers/cpufreq/omap-cpufreq.c index 6e22f4481c07..65f8e9a54975 100644 --- a/drivers/cpufreq/omap-cpufreq.c +++ b/drivers/cpufreq/omap-cpufreq.c | |||
@@ -266,9 +266,9 @@ static int __init omap_cpufreq_init(void) | |||
266 | } | 266 | } |
267 | 267 | ||
268 | mpu_dev = omap_device_get_by_hwmod_name("mpu"); | 268 | mpu_dev = omap_device_get_by_hwmod_name("mpu"); |
269 | if (!mpu_dev) { | 269 | if (IS_ERR(mpu_dev)) { |
270 | pr_warning("%s: unable to get the mpu device\n", __func__); | 270 | pr_warning("%s: unable to get the mpu device\n", __func__); |
271 | return -EINVAL; | 271 | return PTR_ERR(mpu_dev); |
272 | } | 272 | } |
273 | 273 | ||
274 | mpu_reg = regulator_get(mpu_dev, "vcc"); | 274 | mpu_reg = regulator_get(mpu_dev, "vcc"); |