block, bfq: do not raise non-default weights
BFQ heuristics try to detect interactive I/O, and raise the weight of the queues containing such an I/O. Yet, if also the user changes the weight of a queue (i.e., the user changes the ioprio of the process associated with that queue), then it is most likely better to prevent BFQ heuristics from silently changing the same weight. Tested-by: Jan Kara <jack@suse.cz> Signed-off-by: Paolo Valente <paolo.valente@linaro.org> Signed-off-by: Jens Axboe <axboe@kernel.dk> (cherry picked from commit 91b896f65d32610d6d58af02170b15f8d37a7702) (cherry picked from commit cbbd2f045e60073978fe1b721c0953cd8762ecbb) (cherry picked from commit 88b650c71f7d0d30ac2fa215a139d7a48d069cd9) (cherry picked from commit 9a4725f0341c71a9b4f50f2d203f9740029e42e5) (cherry picked from commit a2c57345ffa5404cefd3d43e2fd4e4492ac7c6e0) (cherry picked from commit df56458ca85c681d163d879b832f868ed5044c8e) (cherry picked from commit dfc085aad98db2bcabd2c438fcd722a90303e6cb)
This commit is contained in:
parent
4b23f1e69b
commit
7034a03ec0
1 changed files with 7 additions and 3 deletions
|
@ -1686,15 +1686,19 @@ static void bfq_bfqq_handle_idle_busy_switch(struct bfq_data *bfqd,
|
|||
* - it is sync,
|
||||
* - it does not belong to a large burst,
|
||||
* - it has been idle for enough time or is soft real-time,
|
||||
* - is linked to a bfq_io_cq (it is not shared in any sense).
|
||||
* - is linked to a bfq_io_cq (it is not shared in any sense),
|
||||
* - has a default weight (otherwise we assume the user wanted
|
||||
* to control its weight explicitly)
|
||||
*/
|
||||
in_burst = bfq_bfqq_in_large_burst(bfqq);
|
||||
soft_rt = bfqd->bfq_wr_max_softrt_rate > 0 &&
|
||||
!BFQQ_TOTALLY_SEEKY(bfqq) &&
|
||||
!in_burst &&
|
||||
time_is_before_jiffies(bfqq->soft_rt_next_start) &&
|
||||
bfqq->dispatched == 0;
|
||||
*interactive = !in_burst && idle_for_long_time;
|
||||
bfqq->dispatched == 0 &&
|
||||
bfqq->entity.new_weight == 40;
|
||||
*interactive = !in_burst && idle_for_long_time &&
|
||||
bfqq->entity.new_weight == 40;
|
||||
wr_or_deserves_wr = bfqd->low_latency &&
|
||||
(bfqq->wr_coeff > 1 ||
|
||||
(bfq_bfqq_sync(bfqq) &&
|
||||
|
|
Loading…
Add table
Reference in a new issue