From: Richard Acayan <mailingradian@gmail.com>
To: Dave Stevenson <dave.stevenson@raspberrypi.com>
Cc: Sakari Ailus <sakari.ailus@linux.intel.com>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
linux-media@vger.kernel.org, linux-kernel@vger.kernel.org,
David Heidelberg <david@ixit.cz>,
Jacopo Mondi <jacopo.mondi@ideasonboard.com>,
devicetree@vger.kernel.org
Subject: Re: [PATCH v4 02/21] media: i2c: imx355: Add support for 24 MHz external clock
Date: Wed, 15 Jul 2026 15:47:41 -0400 [thread overview]
Message-ID: <alfj3XIkX-2O5BGp@rdacayan> (raw)
In-Reply-To: <20260715-media-imx355-v4-2-f7f966fb9ffd@raspberrypi.com>
On Wed, Jul 15, 2026 at 12:43:15PM +0100, Dave Stevenson wrote:
> From: David Heidelberg <david@ixit.cz>
>
> The IMX355 sensor supports multiple external clock frequencies,
> including 19.2 MHz and 24 MHz. The driver currently supports only
> fixed 19.2 MHz input clock.
>
> Refactor the clock handling to make the PLL configuration dependent
> on the external clock frequency and add support for 24 MHz. Introduce
> a table of clock parameter sets and program the corresponding EXTCLK
> frequency and PLL multipliers to maintain consistent internal VCO
> frequencies across supported inputs.
>
> The PLL settings are adjusted so that OP VCO remains at 720 MHz
>
> This preserves existing timing characteristics while allowing systems
> using a 24 MHz clock to operate correctly.
>
> No functional change for existing 19.2 MHz users.
>
> Assisted-by: Claude:claude-opus-4-6
> Signed-off-by: David Heidelberg <david@ixit.cz>
> Signed-off-by: Dave Stevenson <dave.stevenson@raspberrypi.com>
> ---
> drivers/media/i2c/imx355.c | 77 +++++++++++++++++++++++++++-------------------
> 1 file changed, 45 insertions(+), 32 deletions(-)
>
> diff --git a/drivers/media/i2c/imx355.c b/drivers/media/i2c/imx355.c
> index ac59908f57aa..a6ee7532018f 100644
> --- a/drivers/media/i2c/imx355.c
> +++ b/drivers/media/i2c/imx355.c
(snip)
> @@ -1749,7 +1756,13 @@ static int imx355_probe(struct i2c_client *client)
> "failed to get clock\n");
>
> freq = clk_get_rate(imx355->clk);
> - if (freq != IMX355_EXT_CLK)
> + for (unsigned int i = 0; i < ARRAY_SIZE(imx355_clk_params); i++) {
Did we start allowing variable declarations mixed with code?
next prev parent reply other threads:[~2026-07-15 19:47 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-15 11:43 [PATCH v4 00/21] media/imx355: General code cleanups, and adding support for 2 lane operation Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 01/21] media: imx355: Avoid calling imx355_power_off twice in error path Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 02/21] media: i2c: imx355: Add support for 24 MHz external clock Dave Stevenson
2026-07-15 19:47 ` Richard Acayan [this message]
2026-07-15 20:19 ` Sakari Ailus
2026-07-15 11:43 ` [PATCH v4 03/21] dt-bindings: media: imx355: Allow 2 CSI2 data lane output Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 04/21] media: imx355: Remove duplicated registers from the mode tables Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 05/21] media: imx355: Remove setting FRM_LENGTH_LINES in the mode regs Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 06/21] media: imx355: Programmatically set the crop parameters for each mode Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 07/21] media: imx355: Set register LINE_LENGTH_PCK programmatically Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 08/21] media: imx355: Set binning mode registers programmatically Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 09/21] media: imx355: Remove link_freq_index from each mode as ununsed Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 10/21] media: imx355: pixel_rate never changes, so don't recompute Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 11/21] media: imx355: Remove redundant fll_min, and implement fixed offset Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 12/21] media: imx355: Add support for get_selection Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 13/21] media: imx355: Use pm_runtime autosuspend_delay Dave Stevenson
2026-07-15 12:03 ` sashiko-bot
2026-07-15 11:43 ` [PATCH v4 14/21] media: imx355: Convert to new CCI register access helpers Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 15/21] media: imx355: Set the colorspace in the format Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 16/21] media: imx355: Define the exposure offset, and use that define Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 17/21] media: imx355: Use NULL ctrl_ops for HBLANK as it is a read-only control Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 18/21] media: imx355: Compute link frequency from PLL setup Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 19/21] media: imx355: Support 2 lane readout Dave Stevenson
2026-07-15 11:43 ` [PATCH v4 20/21] media: imx355: Switch to using the subdev state Dave Stevenson
2026-07-15 12:13 ` sashiko-bot
2026-07-15 11:43 ` [PATCH v4 21/21] media: imx355: Remove storing cur_mode in the state 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=alfj3XIkX-2O5BGp@rdacayan \
--to=mailingradian@gmail.com \
--cc=conor+dt@kernel.org \
--cc=dave.stevenson@raspberrypi.com \
--cc=david@ixit.cz \
--cc=devicetree@vger.kernel.org \
--cc=jacopo.mondi@ideasonboard.com \
--cc=krzk+dt@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
--cc=robh@kernel.org \
--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