From: Boris Brezillon <boris.brezillon@free-electrons.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Wenyou Yang <wenyou.yang@atmel.com>,
Josh Wu <rainyfeeling@outlook.com>,
Richard Weinberger <richard@nod.at>,
David Woodhouse <dwmw2@infradead.org>,
Brian Norris <computersforpeace@gmail.com>,
Marek Vasut <marek.vasut@gmail.com>,
Cyrille Pitchen <cyrille.pitchen@atmel.com>,
linux-mtd@lists.infradead.org, kernel-janitors@vger.kernel.org
Subject: Re: [patch] mtd: nand: Fix a couple error codes
Date: Sun, 9 Apr 2017 16:33:22 +0200 [thread overview]
Message-ID: <20170409163322.3da06acd@bbrezillon> (raw)
In-Reply-To: <20170404081545.GA25533@mwanda>
Hi Dan,
On Tue, 4 Apr 2017 11:15:46 +0300
Dan Carpenter <dan.carpenter@oracle.com> wrote:
> We accidentally return 1 on error instead of proper error codes.
These bugs have not reached Linus' tree yet and I'll have to force push
my nand/next branch because of regressions introduced by other patches
(not related to the Atmel NAND driver rework). Do you mind if I squash
the changes in the original commit?
Thanks,
Boris
>
> Fixes: 07b23e3db9ed ("mtd: nand: Cleanup/rework the atmel_nand driver")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
>
> diff --git a/drivers/mtd/nand/atmel/nand-controller.c b/drivers/mtd/nand/atmel/nand-controller.c
> index 27301603f394..b8d17a024dbd 100644
> --- a/drivers/mtd/nand/atmel/nand-controller.c
> +++ b/drivers/mtd/nand/atmel/nand-controller.c
> @@ -1686,7 +1686,7 @@ static int atmel_nand_controller_init(struct atmel_nand_controller *nc,
> nc->smc = syscon_node_to_regmap(np);
> of_node_put(np);
> if (IS_ERR(nc->smc)) {
> - ret = IS_ERR(nc->smc);
> + ret = PTR_ERR(nc->smc);
> dev_err(dev, "Could not get SMC regmap (err = %d)\n", ret);
> return ret;
> }
> @@ -1719,7 +1719,7 @@ atmel_smc_nand_controller_init(struct atmel_smc_nand_controller *nc)
> nc->matrix = syscon_node_to_regmap(np);
> of_node_put(np);
> if (IS_ERR(nc->matrix)) {
> - ret = IS_ERR(nc->matrix);
> + ret = PTR_ERR(nc->matrix);
> dev_err(dev, "Could not get Matrix regmap (err = %d)\n", ret);
> return ret;
> }
next prev parent reply other threads:[~2017-04-09 14:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-04 8:15 [patch] mtd: nand: Fix a couple error codes Dan Carpenter
2017-04-04 9:27 ` Marek Vasut
2017-04-09 14:33 ` Boris Brezillon [this message]
2017-04-10 7:09 ` Dan Carpenter
2017-04-11 8:09 ` Boris Brezillon
2017-04-11 11:37 ` Boris Brezillon
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=20170409163322.3da06acd@bbrezillon \
--to=boris.brezillon@free-electrons.com \
--cc=computersforpeace@gmail.com \
--cc=cyrille.pitchen@atmel.com \
--cc=dan.carpenter@oracle.com \
--cc=dwmw2@infradead.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=marek.vasut@gmail.com \
--cc=rainyfeeling@outlook.com \
--cc=richard@nod.at \
--cc=wenyou.yang@atmel.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