From: Marek Vasut <marek.vasut@gmail.com>
To: Wei Yongjun <weiyj.lk@gmail.com>,
Cyrille Pitchen <cyrille.pitchen@atmel.com>,
David Woodhouse <dwmw2@infradead.org>,
Brian Norris <computersforpeace@gmail.com>,
Boris Brezillon <boris.brezillon@free-electrons.com>,
Richard Weinberger <richard@nod.at>
Cc: Wei Yongjun <weiyongjun1@huawei.com>,
linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH -next] mtd: aspeed: remove redundant dev_err call in aspeed_smc_probe()
Date: Thu, 9 Feb 2017 09:50:23 +0100 [thread overview]
Message-ID: <6c10cdf0-5b91-000c-a8c3-78f41d47bac3@gmail.com> (raw)
In-Reply-To: <20170208162310.6048-1-weiyj.lk@gmail.com>
On 02/08/2017 05:23 PM, Wei Yongjun wrote:
> From: Wei Yongjun <weiyongjun1@huawei.com>
>
> There is a error message within devm_ioremap_resource
> already, so remove the dev_err call to avoid redundant
> error message.
>
> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Reviewed-by: Marek Vasut <marek.vasut@gmail.com>
> ---
> drivers/mtd/spi-nor/aspeed-smc.c | 8 ++------
> 1 file changed, 2 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/mtd/spi-nor/aspeed-smc.c b/drivers/mtd/spi-nor/aspeed-smc.c
> index 7c86099..56051d3 100644
> --- a/drivers/mtd/spi-nor/aspeed-smc.c
> +++ b/drivers/mtd/spi-nor/aspeed-smc.c
> @@ -723,17 +723,13 @@ static int aspeed_smc_probe(struct platform_device *pdev)
>
> res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
> controller->regs = devm_ioremap_resource(dev, res);
> - if (IS_ERR(controller->regs)) {
> - dev_err(dev, "Cannot remap controller address.\n");
> + if (IS_ERR(controller->regs))
> return PTR_ERR(controller->regs);
> - }
>
> res = platform_get_resource(pdev, IORESOURCE_MEM, 1);
> controller->ahb_base = devm_ioremap_resource(dev, res);
> - if (IS_ERR(controller->ahb_base)) {
> - dev_err(dev, "Cannot remap controller address.\n");
> + if (IS_ERR(controller->ahb_base))
> return PTR_ERR(controller->ahb_base);
> - }
>
> ret = aspeed_smc_setup_flash(controller, np, res);
> if (ret)
>
>
>
--
Best regards,
Marek Vasut
next prev parent reply other threads:[~2017-02-09 8:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-08 16:23 [PATCH -next] mtd: aspeed: remove redundant dev_err call in aspeed_smc_probe() Wei Yongjun
2017-02-09 8:50 ` Marek Vasut [this message]
2017-02-10 19:20 ` 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=6c10cdf0-5b91-000c-a8c3-78f41d47bac3@gmail.com \
--to=marek.vasut@gmail.com \
--cc=boris.brezillon@free-electrons.com \
--cc=computersforpeace@gmail.com \
--cc=cyrille.pitchen@atmel.com \
--cc=dwmw2@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=richard@nod.at \
--cc=weiyj.lk@gmail.com \
--cc=weiyongjun1@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).