From: Richard Weinberger <richard@nod.at>
To: dedekind1@gmail.com
Cc: linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] UBI: Fix possible deadlock in erase_worker()
Date: Tue, 30 Sep 2014 00:22:56 +0200 [thread overview]
Message-ID: <5429DBC0.1010801@nod.at> (raw)
In-Reply-To: <1411728032.23429.63.camel@sauron.fi.intel.com>
Am 26.09.2014 12:40, schrieb Artem Bityutskiy:
> On Mon, 2014-09-22 at 10:45 +0200, Richard Weinberger wrote:
>> If sync_erase() fails with EINTR, ENOMEM, EAGAIN or
>> EBUSY erase_worker() re-schedules the failed work.
>> This will lead to a deadlock because erase_worker() is called
>> with work_sem held in read mode. And schedule_erase() will take
>> this lock again.
>>
>> Signed-off-by: Richard Weinberger <richard@nod.at>
>
> Did you manage to test it?
>
> Why no -stable this time? Not that important, or just something
> theoretical and you never actually hit this bug?
It is something theoretical, I was only able to trigger it by injecting
ENOMEM by hand.
Thanks,
//richard
next prev parent reply other threads:[~2014-09-29 22:23 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-22 8:45 [PATCH 1/3] UBI: ubi_eba_read_leb: Remove in vain variable assignment Richard Weinberger
2014-09-22 8:45 ` Richard Weinberger
2014-09-22 8:45 ` [PATCH 2/3] UBI: wl: Rename cancel flag to shutdown Richard Weinberger
2014-09-22 8:45 ` Richard Weinberger
2014-09-22 8:45 ` [PATCH 3/3] UBI: Fix possible deadlock in erase_worker() Richard Weinberger
2014-09-22 8:45 ` Richard Weinberger
2014-09-26 10:40 ` Artem Bityutskiy
2014-09-29 22:22 ` Richard Weinberger [this message]
2014-09-26 10:46 ` [PATCH 1/3] UBI: ubi_eba_read_leb: Remove in vain variable assignment Artem Bityutskiy
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=5429DBC0.1010801@nod.at \
--to=richard@nod.at \
--cc=dedekind1@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.