From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
Cc: Robert Mader <robert.mader@collabora.com>,
Sakari Ailus <sakari.ailus@linux.intel.com>,
Dave Stevenson <dave.stevenson@raspberrypi.com>,
linux-media@vger.kernel.org
Subject: Re: [PATCH 3/3] media: imx258: Remove mandatory 180 degrees rotation
Date: Wed, 25 Jan 2023 14:39:25 +0200 [thread overview]
Message-ID: <Y9Ei/VDAGTxR3+EF@pendragon.ideasonboard.com> (raw)
In-Reply-To: <20230117100603.51631-4-jacopo.mondi@ideasonboard.com>
Hi Jacopo,
Thank you for the patch.
On Tue, Jan 17, 2023 at 11:06:03AM +0100, Jacopo Mondi wrote:
> The "rotation" fwnode device property is intended to allow specify the
s/specify/specifying/
> sensor's physical mounting rotation, so that it can be exposed through
> the read-only V4L2_CID_CAMERA_SENSOR_ROTATION control and applications
> can decide how to compensate for that.
>
> The imx258 driver has read-only VFLIP and HFLIP enabled, resulting in
> a 180 degrees image rotation being produced by the sensor. But this
> doesn't imply that the physical mounting rotation should match the
> driver's implementation.
>
> Now that the driver registers V4L2_CID_CAMERA_SENSOR_ROTATION
> and V4L2_CID_HFLIP/VFLIP correctly, userspace has all the required
> information to handle the rotation correctly, hence it is not necessary
> to require the 'rotation' property to be fixed to 180 degrees in DTS.
>
> Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
> ---
> drivers/media/i2c/imx258.c | 8 --------
> 1 file changed, 8 deletions(-)
>
> diff --git a/drivers/media/i2c/imx258.c b/drivers/media/i2c/imx258.c
> index 2e0a4ea76589..85d73b186111 100644
> --- a/drivers/media/i2c/imx258.c
> +++ b/drivers/media/i2c/imx258.c
> @@ -1299,14 +1299,6 @@ static int imx258_probe(struct i2c_client *client)
> return -EINVAL;
> }
>
> - /*
> - * Check that the device is mounted upside down. The driver only
> - * supports a single pixel order right now.
> - */
> - ret = device_property_read_u32(&client->dev, "rotation", &val);
> - if (ret || val != 180)
> - return -EINVAL;
> -
> /* Initialize subdev */
> v4l2_i2c_subdev_init(&imx258->sd, client, &imx258_subdev_ops);
>
--
Regards,
Laurent Pinchart
next prev parent reply other threads:[~2023-01-25 12:39 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-17 10:06 [PATCH 0/3] media: imx258: Remove rotation=<80 requirement Jacopo Mondi
2023-01-17 10:06 ` [PATCH 1/3] media: imx258: Parse and register properties Jacopo Mondi
2023-01-25 12:35 ` Laurent Pinchart
2023-01-17 10:06 ` [PATCH 2/3] media: imx258: Register H/V flip controls Jacopo Mondi
2023-01-17 10:17 ` Sakari Ailus
2023-01-17 10:28 ` Jacopo Mondi
2023-01-25 12:49 ` Laurent Pinchart
2023-01-17 10:06 ` [PATCH 3/3] media: imx258: Remove mandatory 180 degrees rotation Jacopo Mondi
2023-01-25 12:39 ` Laurent Pinchart [this message]
2023-01-26 14:52 ` [PATCH 0/3] media: imx258: Remove rotation=<80 requirement Sakari Ailus
2023-01-26 15:48 ` Dave Stevenson
2023-01-26 16:01 ` Laurent Pinchart
2023-01-26 16:13 ` Dave Stevenson
2023-01-26 16:02 ` Sakari Ailus
2023-01-26 16:44 ` Dave Stevenson
2023-01-26 17:31 ` Jacopo Mondi
2023-01-26 17:58 ` Dave Stevenson
2023-01-26 20:03 ` Jacopo Mondi
2023-01-27 11:08 ` Dave Stevenson
2023-02-27 17:11 ` Jacopo Mondi
2023-02-27 22:09 ` Sakari Ailus
2023-03-17 9:32 ` Robert Mader
2023-03-22 12:27 ` Jacopo Mondi
2023-03-22 12:30 ` Sakari Ailus
2023-03-22 12:32 ` Jacopo Mondi
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=Y9Ei/VDAGTxR3+EF@pendragon.ideasonboard.com \
--to=laurent.pinchart@ideasonboard.com \
--cc=dave.stevenson@raspberrypi.com \
--cc=jacopo.mondi@ideasonboard.com \
--cc=linux-media@vger.kernel.org \
--cc=robert.mader@collabora.com \
--cc=sakari.ailus@linux.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