linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: NeilBrown <neilb@suse.de>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Shaohua Li <shli@kernel.org>,
	Fengguang Wu <fengguang.wu@intel.com>,
	linux RAID <linux-raid@vger.kernel.org>,
	lkml <linux-kernel@vger.kernel.org>
Subject: [GIT PULL REQUEST] one md BUG-fix for 3.15-rc
Date: Thu, 17 Apr 2014 17:12:06 +1000	[thread overview]
Message-ID: <20140417171206.4518ce1d@notabene.brown> (raw)

[-- Attachment #1: Type: text/plain, Size: 1155 bytes --]

The following changes since commit e240c1839d11152b0355442f8ac6d2d2d921be36:

  raid5: get_active_stripe avoids device_lock (2014-04-09 14:42:42 +1000)

are available in the git repository at:

  git://neil.brown.name/md tags/3.15-fixes

for you to fetch changes up to c7a6d35e463caacab08ca0333bdec5b8bdce8bbb:

  raid5: fix a race of stripe count check (2014-04-17 17:05:28 +1000)

----------------------------------------------------------------
One BUG fix for md for recent commit

----------------------------------------------------------------
Shaohua Li (1):
      raid5: fix a race of stripe count check

 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 25247a852912..ad1b9bea446e 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -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;
 }
 

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

                 reply	other threads:[~2014-04-17  7:12 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20140417171206.4518ce1d@notabene.brown \
    --to=neilb@suse.de \
    --cc=fengguang.wu@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-raid@vger.kernel.org \
    --cc=shli@kernel.org \
    --cc=torvalds@linux-foundation.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).