diff options
author | Sakari Ailus <sakari.ailus@iki.fi> | 2015-03-09 19:44:40 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@osg.samsung.com> | 2015-04-02 21:24:00 -0400 |
commit | 0fd68f2f7aee2343f2396188362ba41447d8004f (patch) | |
tree | 957c672bf80f9f0983ed77c0b0032c01155030bf | |
parent | c4c0283ab3cd78f8c53e708f8e75e8ed80468a31 (diff) |
[media] smiapp: Clean up smiapp_get_pdata()
Don't set rval when it's not used (the function returns a pointer to struct
smiapp_platform_data).
Signed-off-by: Sakari Ailus <sakari.ailus@iki.fi>
Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
-rw-r--r-- | drivers/media/i2c/smiapp/smiapp-core.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/media/i2c/smiapp/smiapp-core.c b/drivers/media/i2c/smiapp/smiapp-core.c index f714eb7f4092..557f25def3a0 100644 --- a/drivers/media/i2c/smiapp/smiapp-core.c +++ b/drivers/media/i2c/smiapp/smiapp-core.c | |||
@@ -2988,10 +2988,8 @@ static struct smiapp_platform_data *smiapp_get_pdata(struct device *dev) | |||
2988 | return NULL; | 2988 | return NULL; |
2989 | 2989 | ||
2990 | pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); | 2990 | pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL); |
2991 | if (!pdata) { | 2991 | if (!pdata) |
2992 | rval = -ENOMEM; | ||
2993 | goto out_err; | 2992 | goto out_err; |
2994 | } | ||
2995 | 2993 | ||
2996 | v4l2_of_parse_endpoint(ep, &bus_cfg); | 2994 | v4l2_of_parse_endpoint(ep, &bus_cfg); |
2997 | 2995 | ||
@@ -3001,7 +2999,6 @@ static struct smiapp_platform_data *smiapp_get_pdata(struct device *dev) | |||
3001 | break; | 2999 | break; |
3002 | /* FIXME: add CCP2 support. */ | 3000 | /* FIXME: add CCP2 support. */ |
3003 | default: | 3001 | default: |
3004 | rval = -EINVAL; | ||
3005 | goto out_err; | 3002 | goto out_err; |
3006 | } | 3003 | } |
3007 | 3004 | ||