summaryrefslogtreecommitdiffstats
path: root/block/blk-sysfs.c
diff options
context:
space:
mode:
authorAleksei Zakharov <zakharov.a.g@yandex.ru>2019-02-11 05:10:34 -0500
committerJens Axboe <axboe@kernel.dk>2019-02-11 10:20:14 -0500
commitb7143fe67bfc3b83a9e11371da659e1e70a1bbf3 (patch)
tree97680f2159fc96f58d83743844ab1b1d1f025cb1 /block/blk-sysfs.c
parent0586942f03b71bc95b0ee356ff6b09d53acbad06 (diff)
block: avoid setting wbt_lat_usec to current value
There's no reason to set wbt min lat and freeze request queue if current value is the same. Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de> Signed-off-by: Aleksei Zakharov <zakharov.a.g@yandex.ru> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/blk-sysfs.c')
-rw-r--r--block/blk-sysfs.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/block/blk-sysfs.c b/block/blk-sysfs.c
index 94e1b052abbc..59685918167e 100644
--- a/block/blk-sysfs.c
+++ b/block/blk-sysfs.c
@@ -468,6 +468,9 @@ static ssize_t queue_wb_lat_store(struct request_queue *q, const char *page,
468 else if (val >= 0) 468 else if (val >= 0)
469 val *= 1000ULL; 469 val *= 1000ULL;
470 470
471 if (wbt_get_min_lat(q) == val)
472 return count;
473
471 /* 474 /*
472 * Ensure that the queue is idled, in case the latency update 475 * Ensure that the queue is idled, in case the latency update
473 * ends up either enabling or disabling wbt completely. We can't 476 * ends up either enabling or disabling wbt completely. We can't