From: Xiubo Li <xiubli@redhat.com>
To: Colin Ian King <colin.i.king@gmail.com>,
Jeff Layton <jlayton@kernel.org>,
Ilya Dryomov <idryomov@gmail.com>,
ceph-devel@vger.kernel.org
Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ceph: remove redundant variable ino
Date: Wed, 18 May 2022 22:23:22 +0800 [thread overview]
Message-ID: <5398e036-8150-ffd0-844e-719257c6e2f7@redhat.com> (raw)
In-Reply-To: <20220518085508.509104-1-colin.i.king@gmail.com>
On 5/18/22 4:55 PM, Colin Ian King wrote:
> Variable ino is being assigned a value that is never read. The variable
> and assignment are redundant, remove it.
>
> Cleans up clang scan build warning:
> warning: Although the value stored to 'ino' is used in the enclosing
> expression, the value is never actually read from 'ino'
> [deadcode.DeadStores]
>
> Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
> ---
> fs/ceph/mds_client.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/fs/ceph/mds_client.c b/fs/ceph/mds_client.c
> index 00c3de177dd6..20197f05faec 100644
> --- a/fs/ceph/mds_client.c
> +++ b/fs/ceph/mds_client.c
> @@ -437,7 +437,7 @@ static int ceph_parse_deleg_inos(void **p, void *end,
> ceph_decode_32_safe(p, end, sets, bad);
> dout("got %u sets of delegated inodes\n", sets);
> while (sets--) {
> - u64 start, len, ino;
> + u64 start, len;
>
> ceph_decode_64_safe(p, end, start, bad);
> ceph_decode_64_safe(p, end, len, bad);
> @@ -449,7 +449,7 @@ static int ceph_parse_deleg_inos(void **p, void *end,
> continue;
> }
> while (len--) {
> - int err = xa_insert(&s->s_delegated_inos, ino = start++,
> + int err = xa_insert(&s->s_delegated_inos, start++,
> DELEGATED_INO_AVAILABLE,
> GFP_KERNEL);
> if (!err) {
Merged into ceph-client/testing branch. Thanks!
-- Xiubo
prev parent reply other threads:[~2022-05-18 14:23 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-18 8:55 Colin Ian King
2022-05-18 14:08 ` Jeff Layton
2022-05-18 14:23 ` Xiubo Li [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=5398e036-8150-ffd0-844e-719257c6e2f7@redhat.com \
--to=xiubli@redhat.com \
--cc=ceph-devel@vger.kernel.org \
--cc=colin.i.king@gmail.com \
--cc=idryomov@gmail.com \
--cc=jlayton@kernel.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®