[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20200623122536.GE870@valkosipuli.retiisi.org.uk>
Date: Tue, 23 Jun 2020 15:25:36 +0300
From: Sakari Ailus <sakari.ailus@....fi>
To: Andrey Konovalov <andrey.konovalov@...aro.org>
Cc: mchehab@...nel.org, manivannan.sadhasivam@...aro.org,
linux-media@...r.kernel.org, linux-kernel@...r.kernel.org,
devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
c.barrett@...mos.com, a.brela@...mos.com, peter.griffin@...aro.org
Subject: Re: [PATCH v5 06/10] media: i2c: imx290: Add support for test
pattern generation
Hi Andrey,
On Fri, Jun 12, 2020 at 04:53:51PM +0300, Andrey Konovalov wrote:
...
> @@ -448,6 +466,22 @@ static int imx290_set_ctrl(struct v4l2_ctrl *ctrl)
> case V4L2_CID_GAIN:
> ret = imx290_set_gain(imx290, ctrl->val);
> break;
> + case V4L2_CID_TEST_PATTERN:
> + if (ctrl->val) {
> + imx290_write_reg(imx290, IMX290_BLKLEVEL_LOW, 0x00);
> + imx290_write_reg(imx290, IMX290_BLKLEVEL_HIGH, 0x00);
> + msleep(10);
> + imx290_write_reg(imx290, IMX290_PGCTRL,
> + (u8)(IMX290_PGCTRL_REGEN |
> + IMX290_PGCTRL_THRU |
> + IMX290_PGCTRL_MODE(ctrl->val)));
> + } else {
> + imx290_write_reg(imx290, IMX290_PGCTRL, 0x00);
> + msleep(10);
> + imx290_write_reg(imx290, IMX290_BLKLEVEL_LOW, 0x3c);
> + imx290_write_reg(imx290, IMX290_BLKLEVEL_HIGH, 0x00);
> + }
> + break;
> default:
> ret = -EINVAL;
> break;
I've merged the patches in my tree. Could you still replace msleep() with
less than 20 ms with usleep_range() usage as a follow-up patch on top of
these, please?
--
Kind regards,
Sakari Ailus
Powered by blists - more mailing lists