]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
blk-wbt: use wq_has_sleeper() for wq active check
authorJens Axboe <axboe@kernel.dk>
Fri, 11 Jan 2019 11:07:00 +0000 (12:07 +0100)
committerKleber Sacilotto de Souza <kleber.souza@canonical.com>
Mon, 14 Jan 2019 09:28:55 +0000 (09:28 +0000)
commit7e31a9ca5abf799a8a932ff68c70565d48632b1a
tree6010010686d418718d2bb587785560b909c75e34
parent2fb965cc7b46832a2ea083375a02389e93d013c4
blk-wbt: use wq_has_sleeper() for wq active check

BugLink: https://bugs.launchpad.net/bugs/1810998
We need the memory barrier before checking the list head,
use the appropriate helper for this. The matching queue
side memory barrier is provided by set_current_state().

Tested-by: Anchal Agarwal <anchalag@amazon.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
(backported from commit b78820937b4762b7d30b807d7156bec1d89e4dd3)
[mfo: backport:
 - hunk 3: s/rq_wait_inc_below(rqw/atomic_inc_below(&rqw->inflight/]
Signed-off-by: Mauricio Faria de Oliveira <mfo@canonical.com>
Acked-by: Stefan Bader <stefan.bader@canonical.com>
Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Signed-off-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
block/blk-wbt.c