public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: jg1.han@samsung.com (Jingoo Han)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH -next] mtd: nuc900_nand: remove redundant return value check of platform_get_resource()
Date: Wed, 08 Jan 2014 08:58:49 +0900	[thread overview]
Message-ID: <001401cf0c04$691d63d0$3b582b70$%han@samsung.com> (raw)
In-Reply-To: <CAPgLHd_RMOPLP2f4nA1vqNNddocMUX7f-gE29TTkuJZPUm=SWw@mail.gmail.com>

On Tuesday, January 07, 2014 10:39 PM, Wei Yongjun wrote:
> 
> From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> 
> Remove unneeded error handling on the result of a call
> to platform_get_resource() when the value is passed to
> devm_ioremap_resource().
> 
> Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>

Reviewed-by: Jingoo Han <jg1.han@samsung.com>

Best regards,
Jingoo Han

> ---
>  drivers/mtd/nand/nuc900_nand.c | 3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/drivers/mtd/nand/nuc900_nand.c b/drivers/mtd/nand/nuc900_nand.c
> index 661fd14..9ee09a8 100644
> --- a/drivers/mtd/nand/nuc900_nand.c
> +++ b/drivers/mtd/nand/nuc900_nand.c
> @@ -268,9 +268,6 @@ static int nuc900_nand_probe(struct platform_device *pdev)
>  	chip->ecc.mode		= NAND_ECC_SOFT;
> 
>  	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> -	if (!res)
> -		return -ENXIO;
> -
>  	nuc900_nand->reg = devm_ioremap_resource(&pdev->dev, res);
>  	if (IS_ERR(nuc900_nand->reg))
>  		return PTR_ERR(nuc900_nand->reg);

  reply	other threads:[~2014-01-07 23:58 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-07 13:38 [PATCH -next] mtd: nuc900_nand: remove redundant return value check of platform_get_resource() Wei Yongjun
2014-01-07 23:58 ` Jingoo Han [this message]
2014-01-20 19:39   ` Brian Norris

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='001401cf0c04$691d63d0$3b582b70$%han@samsung.com' \
    --to=jg1.han@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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