From: Dave Stevenson <dave.stevenson@raspberrypi.com>
To: Rui Miguel Silva <rmfrfs@gmail.com>,
Sakari Ailus <sakari.ailus@linux.intel.com>,
Bingbu Cao <bingbu.cao@intel.com>,
Tianshu Qiu <tian.shu.qiu@intel.com>,
Jimmy Su <jimmy.su@intel.com>,
linux-media@vger.kernel.org
Cc: Dave Stevenson <dave.stevenson@raspberrypi.com>
Subject: [PATCH v2 2/5] media: i2c: imx208: Set V4L2_CTRL_FLAG_MODIFY_LAYOUT on flips
Date: Mon, 5 Dec 2022 15:21:46 +0000 [thread overview]
Message-ID: <20221205152149.1364185-3-dave.stevenson@raspberrypi.com> (raw)
In-Reply-To: <20221205152149.1364185-1-dave.stevenson@raspberrypi.com>
The driver changes the Bayer order based on the flips, but
does not define the control correctly with the
V4L2_CTRL_FLAG_MODIFY_LAYOUT flag.
Add the V4L2_CTRL_FLAG_MODIFY_LAYOUT flag.
Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
---
drivers/media/i2c/imx208.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/media/i2c/imx208.c b/drivers/media/i2c/imx208.c
index a0e17bb9d4ca..64c70ebf9869 100644
--- a/drivers/media/i2c/imx208.c
+++ b/drivers/media/i2c/imx208.c
@@ -937,8 +937,12 @@ static int imx208_init_controls(struct imx208 *imx208)
imx208->hflip = v4l2_ctrl_new_std(ctrl_hdlr, &imx208_ctrl_ops,
V4L2_CID_HFLIP, 0, 1, 1, 0);
+ if (imx208->hflip)
+ imx208->hflip->flags |= V4L2_CTRL_FLAG_MODIFY_LAYOUT;
imx208->vflip = v4l2_ctrl_new_std(ctrl_hdlr, &imx208_ctrl_ops,
V4L2_CID_VFLIP, 0, 1, 1, 0);
+ if (imx208->vflip)
+ imx208->vflip->flags |= V4L2_CTRL_FLAG_MODIFY_LAYOUT;
v4l2_ctrl_new_std(ctrl_hdlr, &imx208_ctrl_ops, V4L2_CID_ANALOGUE_GAIN,
IMX208_ANA_GAIN_MIN, IMX208_ANA_GAIN_MAX,
--
2.34.1
next prev parent reply other threads:[~2022-12-05 15:25 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-05 15:21 [PATCH V2 0/5] Ensure sensor drivers set V4L2_CTRL_FLAG_MODIFY_LAYOUT for flips Dave Stevenson
2022-12-05 15:21 ` [PATCH v2 1/5] media: i2c: ov2680: Set V4L2_CTRL_FLAG_MODIFY_LAYOUT on flips Dave Stevenson
2022-12-05 15:21 ` Dave Stevenson [this message]
2022-12-05 15:21 ` [PATCH v2 3/5] media: i2c: imx319: " Dave Stevenson
2022-12-06 3:42 ` Cao, Bingbu
2022-12-06 11:39 ` Dave Stevenson
2022-12-06 11:52 ` Cao, Bingbu
2022-12-05 15:21 ` [PATCH v2 4/5] media: i2c: imx355: " Dave Stevenson
2022-12-06 11:52 ` Cao, Bingbu
2022-12-05 15:21 ` [PATCH v2 5/5] media: i2c: ov08d10: " Dave Stevenson
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20221205152149.1364185-3-dave.stevenson@raspberrypi.com \
--to=dave.stevenson@raspberrypi.com \
--cc=bingbu.cao@intel.com \
--cc=jimmy.su@intel.com \
--cc=linux-media@vger.kernel.org \
--cc=rmfrfs@gmail.com \
--cc=sakari.ailus@linux.intel.com \
--cc=tian.shu.qiu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox