Re: [PATCH v3] staging: media: imx: fix parenthesis ending checks
From: Frank Li
Date: Tue Mar 10 2026 - 11:40:49 EST
On Mon, Mar 09, 2026 at 05:26:43PM -0700, Mark Adamenko wrote:
> Remove 4 checks for ending with a parenthesis by removing unnecessary
> line breaks, and forward declare a variable for a function call that
> would otherwise remain over 80 columns.
>
> Signed-off-by: Mark Adamenko <marusik.adamenko@xxxxxxxxx>
> ---
Reviewed-by: Frank Li <Frank.Li@xxxxxxx>
> v3: fix commit message
> ---
> ---
> drivers/staging/media/imx/imx-ic-prpencvf.c | 16 ++++++----------
> 1 file changed, 6 insertions(+), 10 deletions(-)
>
> diff --git a/drivers/staging/media/imx/imx-ic-prpencvf.c b/drivers/staging/media/imx/imx-ic-prpencvf.c
> index 77360bfe081a..2339b59af7b0 100644
> --- a/drivers/staging/media/imx/imx-ic-prpencvf.c
> +++ b/drivers/staging/media/imx/imx-ic-prpencvf.c
> @@ -315,8 +315,7 @@ static void prp_setup_vb2_buf(struct prp_priv *priv, dma_addr_t *phys)
> buf = imx_media_capture_device_next_buf(vdev);
> if (buf) {
> priv->active_vb2_buf[i] = buf;
> - phys[i] = vb2_dma_contig_plane_dma_addr(
> - &buf->vbuf.vb2_buf, 0);
> + phys[i] = vb2_dma_contig_plane_dma_addr(&buf->vbuf.vb2_buf, 0);
> } else {
> priv->active_vb2_buf[i] = NULL;
> phys[i] = priv->underrun_buf.phys;
> @@ -704,11 +703,9 @@ static int prp_start(struct prp_priv *priv)
> }
>
> if (ipu_rot_mode_is_irt(priv->rot_mode))
> - priv->eof_irq = ipu_idmac_channel_irq(
> - ic_priv->ipu, priv->rot_out_ch, IPU_IRQ_EOF);
> + priv->eof_irq = ipu_idmac_channel_irq(ic_priv->ipu, priv->rot_out_ch, IPU_IRQ_EOF);
> else
> - priv->eof_irq = ipu_idmac_channel_irq(
> - ic_priv->ipu, priv->out_ch, IPU_IRQ_EOF);
> + priv->eof_irq = ipu_idmac_channel_irq(ic_priv->ipu, priv->out_ch, IPU_IRQ_EOF);
>
> ret = devm_request_irq(ic_priv->ipu_dev, priv->eof_irq,
> prp_eof_interrupt, 0,
> @@ -750,7 +747,7 @@ static int prp_start(struct prp_priv *priv)
> static void prp_stop(struct prp_priv *priv)
> {
> struct imx_ic_priv *ic_priv = priv->ic_priv;
> - unsigned long flags;
> + unsigned long flags, timeout_in_jiffies;
> int ret;
>
> /* mark next EOF interrupt as the last before stream off */
> @@ -761,9 +758,8 @@ static void prp_stop(struct prp_priv *priv)
> /*
> * and then wait for interrupt handler to mark completion.
> */
> - ret = wait_for_completion_timeout(
> - &priv->last_eof_comp,
> - msecs_to_jiffies(IMX_MEDIA_EOF_TIMEOUT));
> + timeout_in_jiffies = msecs_to_jiffies(IMX_MEDIA_EOF_TIMEOUT);
> + ret = wait_for_completion_timeout(&priv->last_eof_comp, timeout_in_jiffies);
> if (ret == 0)
> v4l2_warn(&ic_priv->sd, "wait last EOF timeout\n");
>
> --
> 2.53.0
>