Skip to content

Commit

Permalink
Merge tag '3.15-fixes' of git://neil.brown.name/md
Browse files Browse the repository at this point in the history
Pull md bugfix from Neil Brown:
 "One BUG fix for md for recent commit"

* tag '3.15-fixes' of git://neil.brown.name/md:
  raid5: fix a race of stripe count check
  • Loading branch information
Linus Torvalds committed Apr 17, 2014
2 parents 09df694 + c7a6d35 commit 23c1a60
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/md/raid5.c
Original file line number Diff line number Diff line change
Expand Up @@ -4370,8 +4370,7 @@ static struct stripe_head *__get_priority_stripe(struct r5conf *conf, int group)
sh->group = NULL;
}
list_del_init(&sh->lru);
atomic_inc(&sh->count);
BUG_ON(atomic_read(&sh->count) != 1);
BUG_ON(atomic_inc_return(&sh->count) != 1);
return sh;
}

Expand Down

0 comments on commit 23c1a60

Please sign in to comment.