linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Lad, Prabhakar" <prabhakar.csengg@gmail.com>
To: Yang Yingliang <yangyingliang@huawei.com>
Cc: LKML <linux-kernel@vger.kernel.org>,
	linux-media <linux-media@vger.kernel.org>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Subject: Re: [PATCH -next 3/3] media: isif: remove unnecessary check of res
Date: Wed, 18 May 2022 20:46:20 +0100	[thread overview]
Message-ID: <CA+V-a8vS+Y94Rn0JL3+hf3yZxM8FOfPmMyP86GHB058gZ62VKA@mail.gmail.com> (raw)
In-Reply-To: <20220426030544.3537713-3-yangyingliang@huawei.com>

On Tue, Apr 26, 2022 at 3:53 AM Yang Yingliang <yangyingliang@huawei.com> wrote:
>
> The resource is checked in probe function, so there is
> no need do this check in remove function.
>
> Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
> ---
>  drivers/media/platform/ti/davinci/isif.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
>
Reviewed-by: Lad Prabhakar <prabhakar.csengg@gmail.com>

Cheers,
Prabhakar

> diff --git a/drivers/media/platform/ti/davinci/isif.c b/drivers/media/platform/ti/davinci/isif.c
> index c53cecd072b1..69e862de014f 100644
> --- a/drivers/media/platform/ti/davinci/isif.c
> +++ b/drivers/media/platform/ti/davinci/isif.c
> @@ -1107,8 +1107,7 @@ static int isif_remove(struct platform_device *pdev)
>         isif_cfg.linear_tbl1_addr = NULL;
>         while (i < 3) {
>                 res = platform_get_resource(pdev, IORESOURCE_MEM, i);
> -               if (res)
> -                       release_mem_region(res->start, resource_size(res));
> +               release_mem_region(res->start, resource_size(res));
>                 i++;
>         }
>         vpfe_unregister_ccdc_device(&isif_hw_dev);
> --
> 2.25.1
>

  reply	other threads:[~2022-05-18 19:46 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-26  3:05 [PATCH -next 1/3] [media] dm355_ccdc: remove unnecessary check of res Yang Yingliang
2022-04-26  3:05 ` [PATCH -next 2/3] [media] dm644x_ccdc: " Yang Yingliang
2022-05-18 19:42   ` Lad, Prabhakar
2022-04-26  3:05 ` [PATCH -next 3/3] media: isif: " Yang Yingliang
2022-05-18 19:46   ` Lad, Prabhakar [this message]
2022-05-18 19:41 ` [PATCH -next 1/3] [media] dm355_ccdc: " Lad, Prabhakar

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=CA+V-a8vS+Y94Rn0JL3+hf3yZxM8FOfPmMyP86GHB058gZ62VKA@mail.gmail.com \
    --to=prabhakar.csengg@gmail.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=yangyingliang@huawei.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;
as well as URLs for NNTP newsgroup(s).