From: Greg KH <greg@kroah.com>
To: Roman Gushchin <klamm@yandex-team.ru>
Cc: Neil Brown <neilb@suse.de>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
Shaohua Li <shli@kernel.org>,
"linux-raid@vger.kernel.org" <linux-raid@vger.kernel.org>,
"stable@vger.kernel.org" <stable@vger.kernel.org>
Subject: Re: [PATCH] md/raid5: fix locking in handle_stripe_clean_event()
Date: Thu, 29 Oct 2015 14:22:32 -0700 [thread overview]
Message-ID: <20151029212232.GA6009@kroah.com> (raw)
In-Reply-To: <30651446128148@webcorp02d.yandex-team.ru>
On Thu, Oct 29, 2015 at 05:15:48PM +0300, Roman Gushchin wrote:
> 29.10.2015, 03:35, "Neil Brown" <neilb@suse.de>:
> > On Wed, Oct 28 2015, Roman Gushchin wrote:
> >
> >> �After commit 566c09c53455 ("raid5: relieve lock contention in get_active_stripe()")
> >> �__find_stripe() is called under conf->hash_locks + hash.
> >> �But handle_stripe_clean_event() calls remove_hash() under
> >> �conf->device_lock.
> >>
> >> �Under some cirscumstances the hash chain can be circuited,
> >> �and we get an infinite loop with disabled interrupts and locked hash
> >> �lock in __find_stripe(). This leads to hard lockup on multiple CPUs
> >> �and following system crash.
> >>
> >> �I was able to reproduce this behavior on raid6 over 6 ssd disks.
> >> �The devices_handle_discard_safely option should be set to enable trim
> >> �support. The following script was used:
> >>
> >> �for i in `seq 1 32`; do
> >> �����dd if=/dev/zero of=large$i bs=10M count=100 &
> >> �done
> >>
> >> �Signed-off-by: Roman Gushchin <klamm@yandex-team.ru>
> >> �Cc: Neil Brown <neilb@suse.de>
> >> �Cc: Shaohua Li <shli@kernel.org>
> >> �Cc: linux-raid@vger.kernel.org
> >> �Cc: <stable@vger.kernel.org> # 3.10 - 3.19
> >
> > Hi Roman,
> > �thanks for reporting this and providing a fix.
> >
> > I'm a bit confused by that stable range: 3.10 - 3.19
> >
> > The commit you identify as introducing the bug was added in 3.13, so
> > presumably 3.10, 3.11, 3.12 are not affected.
>
> Sure, it's my mistake. Correct range is 3.13 - 3.19. Sorry.
>
> > Also the bug is still present in mainline, so 4.0, 4.1, 4.2 are also
> > affected, though the patch needs to be revised a bit for 4.1 and later.
>
> Yes, exactly, but things are a bit more complicated in mainline.
> I'll try to prepare a patch for mainline in a couple of days.
We can't do anything with a patch that is not already in Linus's tree,
which is why this isn't even in my patch queue anymore. Please resend
this once the fix is in Linus's tree, with the git commit id of what it
is there and we will be glad to queue it up.
thanks,
greg k-h
next prev parent reply other threads:[~2015-10-29 21:22 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-10-28 8:52 [PATCH] md/raid5: fix locking in handle_stripe_clean_event() Roman Gushchin
2015-10-29 0:34 ` Neil Brown
2015-10-29 14:15 ` Roman Gushchin
2015-10-29 21:22 ` Greg KH [this message]
-- strict thread matches above, loose matches on Subject: below --
2015-11-06 6:41 FAILED: patch "[PATCH] md/raid5: fix locking in handle_stripe_clean_event()" failed to apply to 3.14-stable tree gregkh
2015-11-06 9:54 ` [PATCH] md/raid5: fix locking in handle_stripe_clean_event() Roman Gushchin
2015-11-11 15:58 ` Luis Henriques
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=20151029212232.GA6009@kroah.com \
--to=greg@kroah.com \
--cc=klamm@yandex-team.ru \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-raid@vger.kernel.org \
--cc=neilb@suse.de \
--cc=shli@kernel.org \
--cc=stable@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).