[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <AANLkTikHdKf5_gtTTPY9z+ymyPP6enc3S_-d_zdzmLDJ@mail.gmail.com>
Date: Fri, 14 Jan 2011 15:10:31 +1100
From: Nick Piggin <npiggin@...il.com>
To: Li Zefan <lizf@...fujitsu.com>
Cc: Valdis.Kletnieks@...edu, containers@...ts.linux-foundation.org,
linux-kernel@...r.kernel.org,
linux-security-module@...r.kernel.org,
Eric Paris <eparis@...isplace.org>,
Paul Menage <menage@...gle.com>,
Stephen Smalley <sds@...ho.nsa.gov>
Subject: Re: linux-next: lockdep whinge in cgroup_rmdir
On Fri, Jan 14, 2011 at 3:06 PM, Li Zefan <lizf@...fujitsu.com> wrote:
> Nick Piggin wrote:
>> It looks like it is just a missing parent->child lock order annotation, but
>> mainline cgroupfs code looks to be OK there. What does
>> cgroup_clear_directory() look like in mmotm?
>
> It's not from cgroup_clear_directory()..
>
> This should fix it:
Yep, thanks!
> =========================
>
> From: Li Zefan <lizf@...fujitsu.com>
> Date: Fri, 14 Jan 2011 11:34:34 +0800
> Subject: [PATCH] cgroups: Fix a lockdep warning at cgroup removal
>
> Commit 2fd6b7f5 ("fs: dcache scale subdirs") forgot to annotate a dentry
> lock, which caused a lockdep warning.
>
> Reported-by: Valdis Kletnieks <Valdis.Kletnieks@...edu>
> Signed-off-by: Li Zefan <lizf@...fujitsu.com>
> ---
> kernel/cgroup.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/kernel/cgroup.c b/kernel/cgroup.c
> index 5c5f4cc..db983e2 100644
> --- a/kernel/cgroup.c
> +++ b/kernel/cgroup.c
> @@ -910,7 +910,7 @@ static void cgroup_d_remove_dir(struct dentry *dentry)
>
> parent = dentry->d_parent;
> spin_lock(&parent->d_lock);
> - spin_lock(&dentry->d_lock);
> + spin_lock_nested(&dentry->d_lock, DENTRY_D_LOCK_NESTED);
> list_del_init(&dentry->d_u.d_child);
> spin_unlock(&dentry->d_lock);
> spin_unlock(&parent->d_lock);
> --
> 1.7.3.1
>
>
--
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