From: Gu Jinxiang <gujx@cn.fujitsu.com>
To: <linux-btrfs@vger.kernel.org>
Cc: <hch@lst.de>, Gu JinXiang <gujx@cn.fujitsu.com>
Subject: [PATCH] btrfs: Use bd_dev to generate index when dev_state_hashtable add items.
Date: Fri, 29 Sep 2017 16:16:35 +0800 [thread overview]
Message-ID: <1506672995-12488-1-git-send-email-gujx@cn.fujitsu.com> (raw)
From: Gu JinXiang <gujx@cn.fujitsu.com>
Fix bug of
<f8f84b2dfda5> (<btrfs: index check-integrity state hash by a dev_t>).
Signed-off-by: Gu JinXiang <gujx@cn.fujitsu.com>
---
fs/btrfs/check-integrity.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/fs/btrfs/check-integrity.c b/fs/btrfs/check-integrity.c
index 9d3854839038..86d79bc4cfb3 100644
--- a/fs/btrfs/check-integrity.c
+++ b/fs/btrfs/check-integrity.c
@@ -613,7 +613,7 @@ static void btrfsic_dev_state_hashtable_add(
struct btrfsic_dev_state_hashtable *h)
{
const unsigned int hashval =
- (((unsigned int)((uintptr_t)ds->bdev)) &
+ (((unsigned int)((uintptr_t)ds->bdev->bd_dev)) &
(BTRFSIC_DEV2STATE_HASHTABLE_SIZE - 1));
list_add(&ds->collision_resolving_node, h->table + hashval);
--
2.13.5
next reply other threads:[~2017-09-29 8:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-29 8:16 Gu Jinxiang [this message]
2017-09-29 18:05 ` [PATCH] btrfs: Use bd_dev to generate index when dev_state_hashtable add items David Sterba
2017-10-09 1:54 ` Gu, Jinxiang
2017-10-10 12:10 ` David Sterba
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=1506672995-12488-1-git-send-email-gujx@cn.fujitsu.com \
--to=gujx@cn.fujitsu.com \
--cc=hch@lst.de \
--cc=linux-btrfs@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;
as well as URLs for NNTP newsgroup(s).