diff options
author | Tejun Heo <tj@kernel.org> | 2016-11-10 17:16:37 +0100 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2016-11-10 18:10:04 +0100 |
commit | ebc4ff661fbe76781c6b16dfb7b754a5d5073f8e (patch) | |
tree | ba0562eb2a24164629d6cbc90f864642ba507665 /block/cfq-iosched.c | |
parent | nvme: don't pass the full CQE to nvme_complete_async_event (diff) | |
download | linux-ebc4ff661fbe76781c6b16dfb7b754a5d5073f8e.tar.xz linux-ebc4ff661fbe76781c6b16dfb7b754a5d5073f8e.zip |
block: cfq_cpd_alloc() should use @gfp
cfq_cpd_alloc() which is the cpd_alloc_fn implementation for cfq was
incorrectly hard coding GFP_KERNEL instead of using the mask specified
through the @gfp parameter. This currently doesn't cause any actual
issues because all current callers specify GFP_KERNEL. Fix it.
Signed-off-by: Tejun Heo <tj@kernel.org>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Fixes: e4a9bde9589f ("blkcg: replace blkcg_policy->cpd_size with ->cpd_alloc/free_fn() methods")
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'block/cfq-iosched.c')
-rw-r--r-- | block/cfq-iosched.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index dcbed8c9c82c..61010511c5a0 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c @@ -1586,7 +1586,7 @@ static struct blkcg_policy_data *cfq_cpd_alloc(gfp_t gfp) { struct cfq_group_data *cgd; - cgd = kzalloc(sizeof(*cgd), GFP_KERNEL); + cgd = kzalloc(sizeof(*cgd), gfp); if (!cgd) return NULL; return &cgd->cpd; |