summaryrefslogtreecommitdiffstats
path: root/kernel/block/blk-cgroup.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/block/blk-cgroup.c')
-rw-r--r--kernel/block/blk-cgroup.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/kernel/block/blk-cgroup.c b/kernel/block/blk-cgroup.c
index 5a37188b5..9d359e05f 100644
--- a/kernel/block/blk-cgroup.c
+++ b/kernel/block/blk-cgroup.c
@@ -1331,10 +1331,8 @@ int blkcg_policy_register(struct blkcg_policy *pol)
struct blkcg_policy_data *cpd;
cpd = pol->cpd_alloc_fn(GFP_KERNEL);
- if (!cpd) {
- mutex_unlock(&blkcg_pol_mutex);
+ if (!cpd)
goto err_free_cpds;
- }
blkcg->cpd[pol->plid] = cpd;
cpd->blkcg = blkcg;