mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Cc: Xavier Roumegue <xavier.roumegue@oss.nxp.com>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	Ezequiel Garcia <ezequiel@vanguardiasur.com.ar>,
	Hans Verkuil <hverkuil-cisco@xs4all.nl>,
	linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org,
	linux-media@vger.kernel.org
Subject: Re: [PATCH] media: dw100: Fix an error handling path in dw100_probe()
Date: Mon, 22 Aug 2022 12:56:54 +0300	[thread overview]
Message-ID: <YwNS5jr2+ersua9B@pendragon.ideasonboard.com> (raw)
In-Reply-To: <7213b90d0d872be154cff81aec1ad8a4a77116af.1661161223.git.christophe.jaillet@wanadoo.fr>

Hi Christophe,

Thank you for the patch.

On Mon, Aug 22, 2022 at 11:40:43AM +0200, Christophe JAILLET wrote:
> After a successful call to media_device_init() it is safer to call
> media_device_init().

I assume you meant media_device_cleanup() ? With this fixed,

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> Add the missing call in the error handling path of the probe, as already
> done in the remove function.
> 
> Fixes: bd090d4d995a ("media: dw100: Add i.MX8MP dw100 dewarper driver")
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> ---
>  drivers/media/platform/nxp/dw100/dw100.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/drivers/media/platform/nxp/dw100/dw100.c b/drivers/media/platform/nxp/dw100/dw100.c
> index 94518f0e486b..b3b057798ab6 100644
> --- a/drivers/media/platform/nxp/dw100/dw100.c
> +++ b/drivers/media/platform/nxp/dw100/dw100.c
> @@ -1623,6 +1623,7 @@ static int dw100_probe(struct platform_device *pdev)
>  error_v4l2:
>  	video_unregister_device(vfd);
>  err_m2m:
> +	media_device_cleanup(&dw_dev->mdev);
>  	v4l2_m2m_release(dw_dev->m2m_dev);
>  err_v4l2:
>  	v4l2_device_unregister(&dw_dev->v4l2_dev);

-- 
Regards,

Laurent Pinchart

  reply	other threads:[~2022-08-22  9:57 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-22  9:40 Christophe JAILLET
2022-08-22  9:56 ` Laurent Pinchart [this message]
2022-08-22 10:54   ` Christophe JAILLET
2022-08-22 10:18 ` Dan Carpenter

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=YwNS5jr2+ersua9B@pendragon.ideasonboard.com \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=christophe.jaillet@wanadoo.fr \
    --cc=ezequiel@vanguardiasur.com.ar \
    --cc=hverkuil-cisco@xs4all.nl \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=xavier.roumegue@oss.nxp.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

all inboxes | Powered by JetHome®