arm: msm: return error pointer in vreg_get if vreg not found
authorSteve Muckle <smuckle@quicinc.com>
Thu, 4 Mar 2010 20:38:05 +0000 (12:38 -0800)
committerDaniel Walker <dwalker@codeaurora.org>
Wed, 12 May 2010 16:14:34 +0000 (09:14 -0700)
Signed-off-by: Steve Muckle <smuckle@quicinc.com>
arch/arm/mach-msm/vreg.c

index fcb0b9f..a839e19 100644 (file)
@@ -70,7 +70,7 @@ struct vreg *vreg_get(struct device *dev, const char *id)
                if (!strcmp(vregs[n].name, id))
                        return vregs + n;
        }
-       return 0;
+       return ERR_PTR(-ENOENT);
 }
 
 void vreg_put(struct vreg *vreg)