From: Steve Muckle Date: Thu, 4 Mar 2010 20:38:05 +0000 (-0800) Subject: arm: msm: return error pointer in vreg_get if vreg not found X-Git-Tag: v2.6.35-rc1~497^2~58 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=0c50b444b69f49e38d16b974993a626ad74c59a7;p=karo-tx-linux.git arm: msm: return error pointer in vreg_get if vreg not found Signed-off-by: Steve Muckle --- diff --git a/arch/arm/mach-msm/vreg.c b/arch/arm/mach-msm/vreg.c index fcb0b9f25684..a839e1913c5b 100644 --- a/arch/arm/mach-msm/vreg.c +++ b/arch/arm/mach-msm/vreg.c @@ -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)