f624ff0a85ca6d1172159fe34dbad6a0ac1a8738
[openwrt/staging/blocktrron.git] /
1 From 705b61d95a10db07cf60f6087e543c826fa53c28 Mon Sep 17 00:00:00 2001
2 From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
3 Date: Mon, 16 Jan 2023 15:44:54 +0100
4 Subject: [PATCH] media: i2c: imx290: Handle error from
5 imx290_set_data_lanes()
6
7 Upstream commit 05ef7ec49d6b
8
9 Check the error status returned by imx290_set_data_lanes() in its
10 caller and propagate it.
11
12 Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
13 Reviewed-by: Alexander Stein <alexander.stein@ew.tq-group.com>
14 Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
15 Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
16 ---
17 drivers/media/i2c/imx290.c | 6 +++++-
18 1 file changed, 5 insertions(+), 1 deletion(-)
19
20 --- a/drivers/media/i2c/imx290.c
21 +++ b/drivers/media/i2c/imx290.c
22 @@ -756,7 +756,11 @@ static int imx290_start_streaming(struct
23 }
24
25 /* Set data lane count */
26 - imx290_set_data_lanes(imx290);
27 + ret = imx290_set_data_lanes(imx290);
28 + if (ret < 0) {
29 + dev_err(imx290->dev, "Could not set data lanes\n");
30 + return ret;
31 + }
32
33 /* Apply the register values related to current frame format */
34 format = v4l2_subdev_get_pad_format(&imx290->sd, state, 0);