[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <aXAKHMjwVpWYUmp7@kekkonen.localdomain>
Date: Wed, 21 Jan 2026 01:05:00 +0200
From: Sakari Ailus <sakari.ailus@...ux.intel.com>
To: Michael Riesch <michael.riesch@...labora.com>
Cc: Chaoyi Chen <chaoyi.chen@...k-chips.com>,
Kever Yang <kever.yang@...k-chips.com>, Frank Li <Frank.li@....com>,
Mehdi Djait <mehdi.djait@...ux.intel.com>,
Bryan O'Donoghue <bryan.odonoghue@...aro.org>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>,
Hans Verkuil <hverkuil@...nel.org>,
Mauro Carvalho Chehab <mchehab@...nel.org>,
Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>,
Conor Dooley <conor+dt@...nel.org>,
Heiko Stuebner <heiko@...ech.de>,
Philipp Zabel <p.zabel@...gutronix.de>,
Sebastian Reichel <sebastian.reichel@...labora.com>,
Nicolas Dufresne <nicolas.dufresne@...labora.com>,
Collabora Kernel Team <kernel@...labora.com>,
linux-media@...r.kernel.org, devicetree@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org,
linux-rockchip@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: Re: fixup! media: synopsys: add driver for the designware mipi csi-2
receiver
Hi Michael,
On Tue, Jan 20, 2026 at 08:35:17PM +0100, Michael Riesch wrote:
> Make smatch happy by adding braces around the initialization in switch
> cases.
>
> Signed-off-by: Michael Riesch <michael.riesch@...labora.com>
> ---
> @Sakari could you try the following patch? I think this should solve the
> issues with smatch/sparse you mentioned off-list.
I don't know what went wrong but this won't apply.
Instead I made the following changes:
diff --git a/drivers/media/platform/synopsys/dw-mipi-csi2rx.c b/drivers/media/platform/synopsys/dw-mipi-csi2rx.c
index 29119a1a8d38..170346ae1a59 100644
--- a/drivers/media/platform/synopsys/dw-mipi-csi2rx.c
+++ b/drivers/media/platform/synopsys/dw-mipi-csi2rx.c
@@ -237,10 +237,8 @@ static int dw_mipi_csi2rx_start(struct dw_mipi_csi2rx_device *csi2)
switch (csi2->bus_type) {
case V4L2_MBUS_CSI2_DPHY:
- struct phy_configure_opts_mipi_dphy *cfg = &opts.mipi_dphy;
-
ret = phy_mipi_dphy_get_default_config_for_hsclk(link_freq * 2,
- lanes, cfg);
+ lanes, &opts.mipi_dphy);
if (ret)
return ret;
@@ -294,14 +292,12 @@ dw_mipi_csi2rx_enum_mbus_code(struct v4l2_subdev *sd,
switch (code->pad) {
case DW_MIPI_CSI2RX_PAD_SRC:
- const struct v4l2_mbus_framefmt *sink_fmt;
-
if (code->index)
return -EINVAL;
- sink_fmt = v4l2_subdev_state_get_format(
- sd_state, DW_MIPI_CSI2RX_PAD_SINK);
- code->code = sink_fmt->code;
+ code->code =
+ v4l2_subdev_state_get_format(sd_state,
+ DW_MIPI_CSI2RX_PAD_SINK)->code;
return 0;
case DW_MIPI_CSI2RX_PAD_SINK:
--
Regards,
Sakari Ailus
Powered by blists - more mailing lists