From: sashiko-bot@kernel.org
To: "Guoniu Zhou" <guoniu.zhou@oss.nxp.com>
Cc: devicetree@vger.kernel.org, Frank.Li@kernel.org, robh@kernel.org,
imx@lists.linux.dev, media-ci@linuxtv.org, conor+dt@kernel.org
Subject: Re: [PATCH v3 5/5] media: imx8-isi: Enable ISI RAW10/12/14 output LSB alignment
Date: Tue, 15 Sep 2026 10:59:14 +0000 [thread overview]
Message-ID: <20260915105914.9F2EA1F000FF@smtp.kernel.org> (raw)
In-Reply-To: <20260915-isi_imx952-v3-5-3d8ff1363dda@oss.nxp.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Medium] media: imx8-isi: Unconditional setting of RAW alignment bits may corrupt non-RAW streams
--
commit 24f35e10010e44cf9f1ebb2452592fd2a6c1b167
Author: Guoniu Zhou <guoniu.zhou@oss.nxp.com>
media: imx8-isi: Enable ISI RAW10/12/14 output LSB alignment
This commit updates the i.MX8 ISI driver to use the hardware LSB alignment
capability introduced in i.MX952 for RAW10/12/14 formats. It drops the older
RAW16 workaround for these newer platforms and updates the alignment bits
during channel setup.
> diff --git a/drivers/media/platform/nxp/imx8-isi/imx8-isi-hw.c b/drivers/media/platform/nxp/imx8-isi/imx8-isi-hw.c
> index 6aa760ce36053..0832b4a110ed2 100644
> --- a/drivers/media/platform/nxp/imx8-isi/imx8-isi-hw.c
> +++ b/drivers/media/platform/nxp/imx8-isi/imx8-isi-hw.c
[ ... ]
> @@ -357,6 +368,20 @@ static void mxc_isi_channel_set_control(struct mxc_isi_pipe *pipe,
> val |= CHNL_CTRL_VC_ID_1(vc >> 2);
> }
>
> + if (isi_raw_out_lsb(pdata)) {
> + /*
> + * Enable RAW10/12/14 output LSB alignment to match the
> + * V4L2 requirement that RAW formats are LSB-aligned.
> + */
> + val |= CHNL_CTRL_RAW_OUT_LSB_ALIGN;
> +
> + /*
> + * Align the data selection from pixel link to MSB to
> + * avoid data shift since the data from PL is MSB.
> + */
> + val |= CHNL_CTRL_RAW_IN_MSB_ALIGN;
> + }
> +
[Severity: Medium]
When starting a non-RAW stream (such as YUV or RGB) on an i.MX952 platform,
could setting these alignment bits unconditionally cause data shift or
corruption for the non-RAW video streams?
It looks like mxc_isi_channel_set_control() applies these bits without
checking if the currently active format is actually a RAW format. Would it
make sense to verify the active stream format before enabling these bits?
> mxc_isi_write(pipe, CHNL_CTRL, val);
>
> mutex_unlock(&pipe->lock);
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260915-isi_imx952-v3-0-3d8ff1363dda@oss.nxp.com?part=5
prev parent reply other threads:[~2026-09-15 10:59 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-15 10:51 [PATCH v3 0/5] media: imx8-isi: Add i.MX952 ISI support Guoniu Zhou
2026-09-15 10:51 ` [PATCH v3 1/5] media: imx8-isi: Reorder mxc_imx95_data to follow mxc_imx93_data Guoniu Zhou
2026-09-15 10:51 ` [PATCH v3 2/5] media: imx8-isi: Extend output format mask to 7 bits Guoniu Zhou
2026-09-15 13:45 ` Frank Li
2026-09-15 10:51 ` [PATCH v3 3/5] media: dt-bindings: nxp,imx8-isi: Add i.MX952 ISI compatible string Guoniu Zhou
2026-09-15 10:51 ` [PATCH v3 4/5] media: imx8-isi: Add i.MX952 ISI support Guoniu Zhou
2026-09-15 10:51 ` [PATCH v3 5/5] media: imx8-isi: Enable ISI RAW10/12/14 output LSB alignment Guoniu Zhou
2026-09-15 10:59 ` sashiko-bot [this message]
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=20260915105914.9F2EA1F000FF@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=Frank.Li@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=guoniu.zhou@oss.nxp.com \
--cc=imx@lists.linux.dev \
--cc=media-ci@linuxtv.org \
--cc=robh@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/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.