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>
This commit is contained in:
Tomi Valkeinen 2021-06-14 13:23:12 +02:00 committed by Mauro Carvalho Chehab
parent 4e11f02f6f
commit 918d6d120a

View File

@ -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)