From: David Sterba <dsterba@suse.cz>
To: Filipe David Manana <fdmanana@gmail.com>
Cc: Omar Sandoval <osandov@osandov.com>, Chris Mason <clm@fb.com>,
Josef Bacik <jbacik@fb.com>, David Sterba <dsterba@suse.cz>,
Filipe Manana <fdmanana@suse.com>,
"linux-btrfs@vger.kernel.org" <linux-btrfs@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] btrfs: unlock i_mutex after attempting to delete subvolume during send
Date: Mon, 30 Mar 2015 15:00:05 +0200 [thread overview]
Message-ID: <20150330130005.GF32051@twin.jikos.cz> (raw)
In-Reply-To: <CAL3q7H7oHbftmpnnMVt0EFWzS_etc--n2bRP9C0Vuzayr4CKgg@mail.gmail.com>
On Sat, Mar 28, 2015 at 11:37:43AM +0000, Filipe David Manana wrote:
> On Sat, Mar 28, 2015 at 11:02 AM, Omar Sandoval <osandov@osandov.com> wrote:
> > Whenever the check for a send in progress introduced in commit
> > 521e0546c970 (btrfs: protect snapshots from deleting during send) is
> > hit, we return without unlocking inode->i_mutex. This is easy to see
> > with lockdep enabled:
> >
> > [ +0.000059] ================================================
> > [ +0.000028] [ BUG: lock held when returning to user space! ]
> > [ +0.000029] 4.0.0-rc5-00096-g3c435c1 #93 Not tainted
> > [ +0.000026] ------------------------------------------------
> > [ +0.000029] btrfs/211 is leaving the kernel with locks still held!
> > [ +0.000029] 1 lock held by btrfs/211:
> > [ +0.000023] #0: (&type->i_mutex_dir_key){+.+.+.}, at: [<ffffffff8135b8df>] btrfs_ioctl_snap_destroy+0x2df/0x7a0
> >
> > Make sure we unlock it in the error path.
> >
> > Signed-off-by: Omar Sandoval <osandov@osandov.com>
> Reviewed-by: Filipe Manana <fdmanana@suse.com>
>
> Thanks, should go to stable in my opinion.
Agreed.
next prev parent reply other threads:[~2015-03-30 13:00 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-28 11:02 Omar Sandoval
2015-03-28 11:37 ` Filipe David Manana
2015-03-30 13:00 ` David Sterba [this message]
2015-03-30 12:59 ` David Sterba
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=20150330130005.GF32051@twin.jikos.cz \
--to=dsterba@suse.cz \
--cc=clm@fb.com \
--cc=fdmanana@gmail.com \
--cc=fdmanana@suse.com \
--cc=jbacik@fb.com \
--cc=linux-btrfs@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=osandov@osandov.com \
/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
all inboxes | Powered by JetHome®