diff options
author | Greg Kroah-Hartman | 2014-05-23 03:13:53 +0200 |
---|---|---|
committer | Greg Kroah-Hartman | 2014-05-23 03:13:53 +0200 |
commit | cbfef53360ea88fa7ef9f80def778fba9b05d21e (patch) | |
tree | 9e23ee08206ec0304e25e8a93eabc2d5bcd8ae9c /block/blk-cgroup.c | |
parent | Merge 3.15-rc3 into staging-next (diff) | |
parent | Linux 3.15-rc6 (diff) | |
download | kernel-qcow2-linux-cbfef53360ea88fa7ef9f80def778fba9b05d21e.tar.gz kernel-qcow2-linux-cbfef53360ea88fa7ef9f80def778fba9b05d21e.tar.xz kernel-qcow2-linux-cbfef53360ea88fa7ef9f80def778fba9b05d21e.zip |
Merge 3.15-rc6 into driver-core-next
We want the kernfs fixes in this branch as well for testing.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'block/blk-cgroup.c')
-rw-r--r-- | block/blk-cgroup.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/block/blk-cgroup.c b/block/blk-cgroup.c index e4a4145926f6..1039fb9ff5f5 100644 --- a/block/blk-cgroup.c +++ b/block/blk-cgroup.c @@ -451,7 +451,20 @@ static int blkcg_reset_stats(struct cgroup_subsys_state *css, struct blkcg_gq *blkg; int i; - mutex_lock(&blkcg_pol_mutex); + /* + * XXX: We invoke cgroup_add/rm_cftypes() under blkcg_pol_mutex + * which ends up putting cgroup's internal cgroup_tree_mutex under + * it; however, cgroup_tree_mutex is nested above cgroup file + * active protection and grabbing blkcg_pol_mutex from a cgroup + * file operation creates a possible circular dependency. cgroup + * internal locking is planned to go through further simplification + * and this issue should go away soon. For now, let's trylock + * blkcg_pol_mutex and restart the write on failure. + * + * http://lkml.kernel.org/g/5363C04B.4010400@oracle.com + */ + if (!mutex_trylock(&blkcg_pol_mutex)) + return restart_syscall(); spin_lock_irq(&blkcg->lock); /* |