diff options
author | Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> | 2021-06-14 13:23:12 +0200 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab+huawei@kernel.org> | 2021-07-12 12:34:11 +0200 |
commit | 918d6d120a60c2640263396308eeb2b6afeb0cd6 (patch) | |
tree | c27b7a98e0db3c5d8a82f3f1636269982fed3029 /drivers | |
parent | 4e11f02f6f9e10015ca07dd016359d2cde9cfbe7 (diff) | |
download | linux-918d6d120a60c2640263396308eeb2b6afeb0cd6.tar.bz2 |
media: ti-vpe: cal: fix error handling in cal_camerarx_create
cal_camerarx_create() doesn't handle error returned from
cal_camerarx_sd_init_cfg(). Fix this.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/media/platform/ti-vpe/cal-camerarx.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/media/platform/ti-vpe/cal-camerarx.c b/drivers/media/platform/ti-vpe/cal-camerarx.c index 124a4e2bdefe..e2e384a887ac 100644 --- a/drivers/media/platform/ti-vpe/cal-camerarx.c +++ b/drivers/media/platform/ti-vpe/cal-camerarx.c @@ -845,7 +845,9 @@ struct cal_camerarx *cal_camerarx_create(struct cal_dev *cal, if (ret) goto error; - cal_camerarx_sd_init_cfg(sd, NULL); + ret = cal_camerarx_sd_init_cfg(sd, NULL); + if (ret) + goto error; ret = v4l2_device_register_subdev(&cal->v4l2_dev, sd); if (ret) |