diff options
author | Paolo Valente <paolo.valente@linaro.org> | 2019-06-25 07:12:44 +0200 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2019-06-25 09:07:34 -0600 |
commit | db599f9ed9bd31b018b6c48ad7c6b21d5b790ecf (patch) | |
tree | bc003791219b878b55104a71530e0f59a4af264c /Documentation/sparc | |
parent | 766d61412ef840295f55e98e2c5fb0fc110c6ca4 (diff) | |
download | linux-db599f9ed9bd31b018b6c48ad7c6b21d5b790ecf.tar.bz2 |
block, bfq: fix rq_in_driver check in bfq_update_inject_limit
One of the cases where the parameters for injection may be updated is
when there are no more in-flight I/O requests. The number of in-flight
requests is stored in the field bfqd->rq_in_driver of the descriptor
bfqd of the device. So, the controlled condition is
bfqd->rq_in_driver == 0.
Unfortunately, this is wrong because, the instruction that checks this
condition is in the code path that handles the completion of a
request, and, in particular, the instruction is executed before
bfqd->rq_in_driver is decremented in such a code path.
This commit fixes this issue by just replacing 0 with 1 in the
comparison.
Reported-by: Srivatsa S. Bhat (VMware) <srivatsa@csail.mit.edu>
Tested-by: Srivatsa S. Bhat (VMware) <srivatsa@csail.mit.edu>
Signed-off-by: Paolo Valente <paolo.valente@linaro.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'Documentation/sparc')
0 files changed, 0 insertions, 0 deletions