From: Miquel Raynal <miquel.raynal@bootlin.com>
To: Zheng Yongjun <zhengyongjun3@huawei.com>
Cc: richard@nod.at, linux-mtd@lists.infradead.org, vigneshr@ti.com,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH -next] mtd: rawnand: simplify the cs553x_write_ctrl_byte()
Date: Thu, 10 Dec 2020 22:19:08 +0100 [thread overview]
Message-ID: <20201210221908.192623d7@xps13> (raw)
In-Reply-To: <20201209093103.20742-1-zhengyongjun3@huawei.com>
Hi Yongjun,
Zheng Yongjun <zhengyongjun3@huawei.com> wrote on Wed, 9 Dec 2020
17:31:03 +0800:
> Simplify the return expression.
>
> Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
> ---
> drivers/mtd/nand/raw/cs553x_nand.c | 11 +++--------
> 1 file changed, 3 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/mtd/nand/raw/cs553x_nand.c b/drivers/mtd/nand/raw/cs553x_nand.c
> index 282203debd0c..a616aaa2e3dc 100644
> --- a/drivers/mtd/nand/raw/cs553x_nand.c
> +++ b/drivers/mtd/nand/raw/cs553x_nand.c
> @@ -105,17 +105,12 @@ static int cs553x_write_ctrl_byte(struct cs553x_nand_controller *cs553x,
> u32 ctl, u8 data)
> {
> u8 status;
> - int ret;
>
> writeb(ctl, cs553x->mmio + MM_NAND_CTL);
> writeb(data, cs553x->mmio + MM_NAND_IO);
> - ret = readb_poll_timeout_atomic(cs553x->mmio + MM_NAND_STS, status,
> - !(status & CS_NAND_CTLR_BUSY), 1,
> - 100000);
> - if (ret)
> - return ret;
> -
> - return 0;
> + return readb_poll_timeout_atomic(cs553x->mmio + MM_NAND_STS, status,
> + !(status & CS_NAND_CTLR_BUSY), 1,
> + 100000);
> }
>
> static void cs553x_data_in(struct cs553x_nand_controller *cs553x, void *buf,
Sorry but this brings no value and I kind of personally dislike commits
darkening git blames for almost no reason, so if you don't mind I would
like to avoid such change.
Thanks,
Miquèl
______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
prev parent reply other threads:[~2020-12-10 21:20 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-09 9:31 [PATCH -next] mtd: rawnand: simplify the cs553x_write_ctrl_byte() Zheng Yongjun
2020-12-10 21:19 ` Miquel Raynal [this message]
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=20201210221908.192623d7@xps13 \
--to=miquel.raynal@bootlin.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--cc=richard@nod.at \
--cc=vigneshr@ti.com \
--cc=zhengyongjun3@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).