linux-mtd.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Miquel Raynal <miquel.raynal@bootlin.com>
To: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>,
	miquel.raynal@bootlin.com
Cc: richard@nod.at, vigneshr@ti.com, linux-mtd@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] mtd: mtd_oobtest: Remove redundant assignment to err
Date: Mon, 10 May 2021 12:43:50 +0200	[thread overview]
Message-ID: <20210510104350.11011-1-miquel.raynal@bootlin.com> (raw)
In-Reply-To: <1619346498-43617-1-git-send-email-jiapeng.chong@linux.alibaba.com>

On Sun, 2021-04-25 at 10:28:18 UTC, Jiapeng Chong wrote:
> Variable err is set to zero but this value is never read as it is
> overwritten with a new value later on, hence it is a redundant
> assignment and can be removed.
> 
> Cleans up the following clang-analyzer warning:
> 
> drivers/mtd/tests/oobtest.c:626:4: warning: Value stored to 'err' is
> never read [clang-analyzer-deadcode.DeadStores].
> 
> drivers/mtd/tests/oobtest.c:603:4: warning: Value stored to 'err' is
> never read [clang-analyzer-deadcode.DeadStores].
> 
> drivers/mtd/tests/oobtest.c:579:4: warning: Value stored to 'err' is
> never read [clang-analyzer-deadcode.DeadStores].
> 
> drivers/mtd/tests/oobtest.c:556:4: warning: Value stored to 'err' is
> never read [clang-analyzer-deadcode.DeadStores].
> 
> drivers/mtd/tests/oobtest.c:532:3: warning: Value stored to 'err' is
> never read [clang-analyzer-deadcode.DeadStores].
> 
> drivers/mtd/tests/oobtest.c:509:3: warning: Value stored to 'err' is
> never read [clang-analyzer-deadcode.DeadStores].
> 
> Reported-by: Abaci Robot <abaci@linux.alibaba.com>
> Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>

Applied to https://git.kernel.org/pub/scm/linux/kernel/git/mtd/linux.git mtd/next, thanks.

Miquel

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

      reply	other threads:[~2021-05-10 10:58 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-25 10:28 [PATCH] mtd: mtd_oobtest: Remove redundant assignment to err Jiapeng Chong
2021-05-10 10:43 ` 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=20210510104350.11011-1-miquel.raynal@bootlin.com \
    --to=miquel.raynal@bootlin.com \
    --cc=jiapeng.chong@linux.alibaba.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=richard@nod.at \
    --cc=vigneshr@ti.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).