From: Michael Riesch <michael.riesch@collabora.com>
To: Chaoyi Chen <chaoyi.chen@rock-chips.com>,
Kever Yang <kever.yang@rock-chips.com>,
Frank Li <Frank.li@nxp.com>,
Mehdi Djait <mehdi.djait@linux.intel.com>,
Bryan O'Donoghue <bryan.odonoghue@linaro.org>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
Hans Verkuil <hverkuil@kernel.org>,
Mauro Carvalho Chehab <mchehab@kernel.org>,
Rob Herring <robh@kernel.org>,
Krzysztof Kozlowski <krzk+dt@kernel.org>,
Conor Dooley <conor+dt@kernel.org>,
Heiko Stuebner <heiko@sntech.de>,
Philipp Zabel <p.zabel@pengutronix.de>,
Sebastian Reichel <sebastian.reichel@collabora.com>,
Nicolas Dufresne <nicolas.dufresne@collabora.com>,
Collabora Kernel Team <kernel@collabora.com>,
Sakari Ailus <sakari.ailus@linux.intel.com>
Cc: linux-media@vger.kernel.org, devicetree@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: fixup! media: synopsys: add driver for the designware mipi csi-2 receiver
Date: Tue, 20 Jan 2026 20:35:17 +0100 [thread overview]
Message-ID: <7722373a-b491-4aaa-9527-a8f091cf22fe@collabora.com> (raw)
In-Reply-To: <20251114-rockchip-mipi-receiver-v8-2-bd1cf5cb9588@collabora.com>
Make smatch happy by adding braces around the initialization in switch
cases.
Signed-off-by: Michael Riesch <michael.riesch@collabora.com>
---
@Sakari could you try the following patch? I think this should solve the
issues with smatch/sparse you mentioned off-list.
drivers/media/platform/synopsys/dw-mipi-csi2rx.c | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/media/platform/synopsys/dw-mipi-csi2rx.c
b/drivers/media/platform/synopsys/dw-mipi-csi2rx.c
index 29119a1a8d38..dc82223e312a 100644
--- a/drivers/media/platform/synopsys/dw-mipi-csi2rx.c
+++ b/drivers/media/platform/synopsys/dw-mipi-csi2rx.c
@@ -236,7 +236,7 @@ static int dw_mipi_csi2rx_start(struct
dw_mipi_csi2rx_device *csi2)
return link_freq;
switch (csi2->bus_type) {
- case V4L2_MBUS_CSI2_DPHY:
+ 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,
@@ -254,7 +254,7 @@ static int dw_mipi_csi2rx_start(struct
dw_mipi_csi2rx_device *csi2)
control |= SW_CPHY_EN(0);
break;
-
+ }
case V4L2_MBUS_CSI2_CPHY:
/* TODO: implement CPHY configuration */
return -EOPNOTSUPP;
@@ -293,7 +293,7 @@ dw_mipi_csi2rx_enum_mbus_code(struct v4l2_subdev *sd,
struct dw_mipi_csi2rx_device *csi2 = to_csi2(sd);
switch (code->pad) {
- case DW_MIPI_CSI2RX_PAD_SRC:
+ case DW_MIPI_CSI2RX_PAD_SRC: {
const struct v4l2_mbus_framefmt *sink_fmt;
if (code->index)
@@ -304,6 +304,7 @@ dw_mipi_csi2rx_enum_mbus_code(struct v4l2_subdev *sd,
code->code = sink_fmt->code;
return 0;
+ }
case DW_MIPI_CSI2RX_PAD_SINK:
if (code->index > csi2->formats_num)
return -EINVAL;
--
2.39.5
_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip
next prev parent reply other threads:[~2026-07-09 8:48 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-20 12:22 [PATCH v8 0/3] media: rockchip: add driver for the rockchip mipi csi-2 receiver Michael Riesch via B4 Relay
2026-01-20 12:22 ` [PATCH v8 1/3] media: dt-bindings: add " Michael Riesch via B4 Relay
2026-01-20 12:22 ` [PATCH v8 2/3] media: synopsys: add driver for the designware " Michael Riesch via B4 Relay
2026-01-20 16:59 ` Frank Li
2026-01-20 19:35 ` Michael Riesch [this message]
2026-01-20 23:05 ` fixup! " Sakari Ailus
2026-01-21 7:29 ` Michael Riesch
2026-01-20 12:22 ` [PATCH v8 3/3] arm64: defconfig: enable " Michael Riesch via B4 Relay
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=7722373a-b491-4aaa-9527-a8f091cf22fe@collabora.com \
--to=michael.riesch@collabora.com \
--cc=Frank.li@nxp.com \
--cc=bryan.odonoghue@linaro.org \
--cc=chaoyi.chen@rock-chips.com \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=heiko@sntech.de \
--cc=hverkuil@kernel.org \
--cc=kernel@collabora.com \
--cc=kever.yang@rock-chips.com \
--cc=krzk+dt@kernel.org \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=mchehab@kernel.org \
--cc=mehdi.djait@linux.intel.com \
--cc=nicolas.dufresne@collabora.com \
--cc=p.zabel@pengutronix.de \
--cc=robh@kernel.org \
--cc=sakari.ailus@linux.intel.com \
--cc=sebastian.reichel@collabora.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