[PATCH] md/raid5: Fix two small bugs in init_stripe().

DORMANTno replies

From: Jianpeng Ma <hidden>
Date: 2012-08-06 01:07:26
Subsystem: software raid (multiple disks) support, the rest · Maintainers: Song Liu, Yu Kuai, Linus Torvalds

There are two small bugs in func init_stripe():
1:pr_debug print error sector
2:Don't call remove_hash() because it called in get_free_stripe().

Signed-off-by: Jianpeng Ma <redacted>
---
 drivers/md/raid5.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
index adda94d..8b486b0 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -329,9 +329,8 @@ static void init_stripe(struct stripe_head *sh, sector_t sector, int previous)
 	BUG_ON(stripe_operations_active(sh));
 
 	pr_debug("init_stripe called, stripe %llu\n",
-		(unsigned long long)sh->sector);
+		(unsigned long long)sector);
 
-	remove_hash(sh);
 
 	sh->generation = conf->generation - previous;
 	sh->disks = previous ? conf->previous_raid_disks : conf->raid_disks;
-- 
1.7.9.5
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help