summaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>2013-10-30 06:23:21 +0100
committerTony Lindgren <tony@atomide.com>2013-11-15 16:38:14 +0100
commitc27f2de754a1412ce4a6c4af723605f776ec4ac2 (patch)
tree309e2787b6a81a2f2c52b0818059661f79595d52 /arch/arm
parentARM: OMAP: devicetree: fix SPI node compatible property syntax items (diff)
downloadlinux-c27f2de754a1412ce4a6c4af723605f776ec4ac2.tar.xz
linux-c27f2de754a1412ce4a6c4af723605f776ec4ac2.zip
ARM: OMAP3: Beagle: fix return value check in beagle_opp_init()
In case of error, the function get_cpu_device() returns NULL pointer not ERR_PTR(). The IS_ERR() test in the return value check should be replaced with NULL test. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mach-omap2/board-omap3beagle.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
index 8b9cd0690ce7..09f6149b59a9 100644
--- a/arch/arm/mach-omap2/board-omap3beagle.c
+++ b/arch/arm/mach-omap2/board-omap3beagle.c
@@ -510,7 +510,7 @@ static int __init beagle_opp_init(void)
mpu_dev = get_cpu_device(0);
iva_dev = omap_device_get_by_hwmod_name("iva");
- if (IS_ERR(mpu_dev) || IS_ERR(iva_dev)) {
+ if (!mpu_dev || IS_ERR(iva_dev)) {
pr_err("%s: Aiee.. no mpu/dsp devices? %p %p\n",
__func__, mpu_dev, iva_dev);
return -ENODEV;