Skip to content
Snippets Groups Projects
Commit 961e2d0b authored by zhengbin's avatar zhengbin Committed by Yongqiang Liu
Browse files

blk-mq: Fix memory leak in blk_mq_init_allocated_queue error handling

mainline inclusion
from mainline-v5.4-rc1
commit 73d9c8d4
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I5NC63


CVE: NA

--------------------------------

If blk_mq_init_allocated_queue->elevator_init_mq fails, need to release
the previously requested resources.

Fixes: d3484991 ("blk-mq-sched: allow setting of default IO scheduler")
Signed-off-by: default avatarzhengbin <zhengbin13@huawei.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
Signed-off-by: default avatarYu Kuai <yukuai3@huawei.com>
Reviewed-by: default avatarJason Yan <yanaijie@huawei.com>
Signed-off-by: default avatarYongqiang Liu <liuyongqiang13@huawei.com>
parent 6100cd7f
No related branches found
No related tags found
No related merge requests found
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment