Commit b8e6a15a authored by Markus Stockhausen's avatar Markus Stockhausen Committed by NeilBrown

md/raid5: fix init_stripe() inconsistencies

raid5: fix init_stripe() inconsistencies

1) remove_hash() is not necessary. We will only be called right after
   get_free_stripe(). There we have already a call to remove_hash().

2) Tracing prints out the sector of the freed stripe and not the sector
   that we want to initialize.
Signed-off-by: default avatarNeilBrown <neilb@suse.de>
parent c4796e21
...@@ -531,9 +531,7 @@ static void init_stripe(struct stripe_head *sh, sector_t sector, int previous) ...@@ -531,9 +531,7 @@ static void init_stripe(struct stripe_head *sh, sector_t sector, int previous)
BUG_ON(stripe_operations_active(sh)); BUG_ON(stripe_operations_active(sh));
pr_debug("init_stripe called, stripe %llu\n", pr_debug("init_stripe called, stripe %llu\n",
(unsigned long long)sh->sector); (unsigned long long)sector);
remove_hash(sh);
retry: retry:
seq = read_seqcount_begin(&conf->gen_lock); seq = read_seqcount_begin(&conf->gen_lock);
sh->generation = conf->generation - previous; sh->generation = conf->generation - previous;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment