blk-iocost: read params inside lock in sysfs apis
authorYu Kuai <yukuai3@huawei.com>
Tue, 17 Jan 2023 07:08:04 +0000 (15:08 +0800)
committerJens Axboe <axboe@kernel.dk>
Sun, 29 Jan 2023 22:18:34 +0000 (15:18 -0700)
commit35198e32300190d52e7f50413dde4f86dea1de92
tree2f48cf4919ec0e254b5c0760804879bcc2da02e2
parent235a5a83f637e32646cd004c9b580decf1225566
blk-iocost: read params inside lock in sysfs apis

Otherwise, user might get abnormal values if params is updated
concurrently.

Signed-off-by: Yu Kuai <yukuai3@huawei.com>
Acked-by: Tejun Heo <tj@kernel.org>
Link: https://lore.kernel.org/r/20230117070806.3857142-4-yukuai1@huaweicloud.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
block/blk-iocost.c