From: Bryan O'Donoghue <bod@kernel.org>
To: Hans de Goede <johannes.goede@oss.qualcomm.com>,
Sakari Ailus <sakari.ailus@linux.intel.com>
Cc: Heimir Thor Sverrisson <heimir.sverrisson@gmail.com>,
linux-media@vger.kernel.org, Sebastian Reichel <sre@kernel.org>
Subject: Re: [PATCH 5/5] media: ov02c10: Remove unnecessary hflip and vflip pointers
Date: Wed, 10 Dec 2025 00:27:55 +0000 [thread overview]
Message-ID: <bbb10fce-4aae-4a72-893a-683cb2f060d5@kernel.org> (raw)
In-Reply-To: <20251209160621.6854-6-johannes.goede@oss.qualcomm.com>
On 09/12/2025 16:06, Hans de Goede wrote:
> The cci_update_bits() inside ov02c10_set_ctrl() can used the passed
> in ctrk argument to access the vflip control value.
use the passed <data> in the ctrl argument
>
> After changing this there is no need to store a pointer to the hflip
> and vflip controls inside struct ov02c10, drop these.
>
> Cc: Sebastian Reichel <sre@kernel.org>
> Cc: Bryan O'Donoghue <bod@kernel.org>
> Signed-off-by: Hans de Goede <johannes.goede@oss.qualcomm.com>
> ---
> drivers/media/i2c/ov02c10.c | 12 +++++-------
> 1 file changed, 5 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/media/i2c/ov02c10.c b/drivers/media/i2c/ov02c10.c
> index f912ae142040..cf93d36032e1 100644
> --- a/drivers/media/i2c/ov02c10.c
> +++ b/drivers/media/i2c/ov02c10.c
> @@ -381,8 +381,6 @@ struct ov02c10 {
> struct v4l2_ctrl *vblank;
> struct v4l2_ctrl *hblank;
> struct v4l2_ctrl *exposure;
> - struct v4l2_ctrl *hflip;
> - struct v4l2_ctrl *vflip;
>
> struct clk *img_clk;
> struct gpio_desc *reset;
> @@ -471,7 +469,7 @@ static int ov02c10_set_ctrl(struct v4l2_ctrl *ctrl)
> cci_write(ov02c10->regmap, OV02C10_ISP_Y_WIN_CONTROL,
> ctrl->val ? 2 : 1, &ret);
> cci_update_bits(ov02c10->regmap, OV02C10_ROTATE_CONTROL,
> - BIT(4), ov02c10->vflip->val << 4, &ret);
> + BIT(4), ctrl->val << 4, &ret);
> break;
>
> default:
> @@ -549,11 +547,11 @@ static int ov02c10_init_controls(struct ov02c10 *ov02c10)
> OV02C10_EXPOSURE_STEP,
> exposure_max);
>
> - ov02c10->hflip = v4l2_ctrl_new_std(ctrl_hdlr, &ov02c10_ctrl_ops,
> - V4L2_CID_HFLIP, 0, 1, 1, 0);
> + v4l2_ctrl_new_std(ctrl_hdlr, &ov02c10_ctrl_ops, V4L2_CID_HFLIP,
> + 0, 1, 1, 0);
>
> - ov02c10->vflip = v4l2_ctrl_new_std(ctrl_hdlr, &ov02c10_ctrl_ops,
> - V4L2_CID_VFLIP, 0, 1, 1, 0);
> + v4l2_ctrl_new_std(ctrl_hdlr, &ov02c10_ctrl_ops, V4L2_CID_VFLIP,
> + 0, 1, 1, 0);
>
> v4l2_ctrl_new_std_menu_items(ctrl_hdlr, &ov02c10_ctrl_ops,
> V4L2_CID_TEST_PATTERN,
> --
> 2.52.0
>
Reviewed-by: Bryan O'Donoghue <bod@kernel.org>
next prev parent reply other threads:[~2025-12-10 0:28 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <O5Gex5D3AY7Qx5JRN_QeWluQpNM8uye-XD90s-asNy5IJgdUAK9-D2UDDW5dXOL1vgSw1CeY1U70nwxr6aXm3A==@protonmail.internalid>
2025-12-09 16:06 ` [PATCH regression fixes for 6.19 0/5] media: ov02c10: h/vflip fixes Hans de Goede
2025-12-09 16:06 ` [PATCH 1/5] media: ov02c10: Fix bayer-pattern change after default vflip change Hans de Goede
2025-12-09 17:16 ` Hans de Goede
2025-12-10 0:20 ` Bryan O'Donoghue
2025-12-09 16:06 ` [PATCH 2/5] media: ov02c10: Adjust x-win/y-win when changing flipping to preserve bayer-pattern Hans de Goede
2025-12-10 0:23 ` Bryan O'Donoghue
2025-12-09 16:06 ` [PATCH 3/5] media: ov02c10: Fix the horizontal flip control Hans de Goede
2025-12-10 0:24 ` Bryan O'Donoghue
2025-12-09 16:06 ` [PATCH 4/5] media: ipu-bridge: Add DMI quirk for Dell XPS laptops with upside down sensors Hans de Goede
2025-12-10 0:26 ` Bryan O'Donoghue
2025-12-10 10:32 ` kernel test robot
2025-12-09 16:06 ` [PATCH 5/5] media: ov02c10: Remove unnecessary hflip and vflip pointers Hans de Goede
2025-12-10 0:27 ` Bryan O'Donoghue [this message]
2025-12-10 0:19 ` [PATCH regression fixes for 6.19 0/5] media: ov02c10: h/vflip fixes Bryan O'Donoghue
2025-12-10 8:06 ` Hans de Goede
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=bbb10fce-4aae-4a72-893a-683cb2f060d5@kernel.org \
--to=bod@kernel.org \
--cc=heimir.sverrisson@gmail.com \
--cc=johannes.goede@oss.qualcomm.com \
--cc=linux-media@vger.kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=sre@kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.