diff options
author | Tejun Heo <tj@kernel.org> | 2019-08-28 15:05:51 -0700 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2019-08-28 21:17:01 -0600 |
commit | cf09a8ee19ad1f78b4e18cdde9f2a61133efacf5 (patch) | |
tree | fe93a7359f9de19bb6480a37847e76acfb64887f /block/blk-cgroup.c | |
parent | da8c828190fcd04662f594f3e00a184885aa5aa3 (diff) | |
download | linux-cf09a8ee19ad1f78b4e18cdde9f2a61133efacf5.tar.bz2 |
blkcg: pass @q and @blkcg into blkcg_pol_alloc_pd_fn()
Instead of @node, pass in @q and @blkcg so that the alloc function has
more context. This doesn't cause any behavior change and will be used
by io.weight implementation.
Signed-off-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk-cgroup.c')
-rw-r--r-- | block/blk-cgroup.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/block/blk-cgroup.c b/block/blk-cgroup.c index 55a7dc227dfb..6a82ca3fb5cf 100644 --- a/block/blk-cgroup.c +++ b/block/blk-cgroup.c @@ -175,7 +175,7 @@ static struct blkcg_gq *blkg_alloc(struct blkcg *blkcg, struct request_queue *q, continue; /* alloc per-policy data and attach it to blkg */ - pd = pol->pd_alloc_fn(gfp_mask, q->node); + pd = pol->pd_alloc_fn(gfp_mask, q, blkcg); if (!pd) goto err_free; @@ -1346,7 +1346,7 @@ int blkcg_activate_policy(struct request_queue *q, blk_mq_freeze_queue(q); pd_prealloc: if (!pd_prealloc) { - pd_prealloc = pol->pd_alloc_fn(GFP_KERNEL, q->node); + pd_prealloc = pol->pd_alloc_fn(GFP_KERNEL, q, &blkcg_root); if (!pd_prealloc) { ret = -ENOMEM; goto out_bypass_end; @@ -1362,7 +1362,7 @@ pd_prealloc: if (blkg->pd[pol->plid]) continue; - pd = pol->pd_alloc_fn(GFP_NOWAIT | __GFP_NOWARN, q->node); + pd = pol->pd_alloc_fn(GFP_NOWAIT | __GFP_NOWARN, q, &blkcg_root); if (!pd) swap(pd, pd_prealloc); if (!pd) { |