[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <52B10AC7.4080107@huawei.com>
Date: Wed, 18 Dec 2013 10:39:03 +0800
From: Li Zefan <lizefan@...wei.com>
To: Wang Nan <wangnan0@...wei.com>
CC: <linux-kernel@...r.kernel.org>, <hui.geng@...wei.com>,
Wang Guoli <andy.wangguoli@...wei.com>,
<stable@...r.kernel.org>
Subject: Re: [PATCH] jffs2: unlock f->sem on error in jffs2_new_inode()
The patch should be sent to jffs2 mainling list, which is
linux-mtd@...ts.infradead.org.
It's not needed to cc stable mailing list. Actually I think it's
better not to.
On 2013/12/18 10:14, Wang Nan wrote:
> From: Wang Guoli <andy.wangguoli@...wei.com>
>
> If jffs2_new_inode() succeeds, it returns with f->sem held, and
> the caller is responsible for releasing the lock. If it fails,
> it still returns with the lock held, but the caller won't release
> the lock, which will lead to deadlock.
>
> Fix it by releasing the lock in jffs2_new_inode() on error.
>
> Cc: <stable@...r.kernel.org> # 2.6.34+
> Signed-off-by: Wang Guoli <andy.wangguoli@...wei.com>
You should also sign the patch.
> ---
> fs/jffs2/fs.c | 9 ++++++---
> 1 file changed, 6 insertions(+), 3 deletions(-)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists