From 6950fe94432b2e2633a9f5e36543ec38a6cd8861 Mon Sep 17 00:00:00 2001 From: Sandor Yu Date: Thu, 14 Dec 2017 11:17:04 +0800 Subject: [PATCH] MLK-17208-2: mipi sensor: Fill subdev_format reserved[0] Pass mipi csi-2 output clock rate from mipi sensor to mipi csi-2 rx controller by v4l2_subdev_format.reserved[0]. Signed-off-by: Sandor Yu --- drivers/media/platform/imx8/max9286.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/media/platform/imx8/max9286.c b/drivers/media/platform/imx8/max9286.c index 7696f85f8675..123b97227818 100644 --- a/drivers/media/platform/imx8/max9286.c +++ b/drivers/media/platform/imx8/max9286.c @@ -2868,6 +2868,12 @@ static int max9286_probe(struct i2c_client *client, max9286_data->format.width = g_max9286_width; max9286_data->format.height = g_max9286_height; max9286_data->format.colorspace = V4L2_COLORSPACE_JPEG; + /***************************************** + * Pass mipi phy clock rate Mbps + * fcsi2 = PCLk * WIDTH * CHANNELS / LANES + * fsci2 = 72MPCLK * 8 bit * 4 channels / 4 lanes + ****************************************/ + max9286_data->format.reserved[0] = 72 * 8; max9286_data->format.field = V4L2_FIELD_NONE; max9286_data->streamcap.capturemode = 0; max9286_data->streamcap.timeperframe.denominator = 30; -- 2.17.1