]> www.infradead.org Git - users/jedix/linux-maple.git/commit
block: Fix a race between blk_cleanup_queue() and timeout handling
authorBart Van Assche <bart.vanassche@wdc.com>
Fri, 4 Jan 2019 08:01:28 +0000 (16:01 +0800)
committerBrian Maly <brian.maly@oracle.com>
Wed, 27 Mar 2019 21:40:50 +0000 (17:40 -0400)
commit89e915b7ff28d5c6e8802bab9550e759eed31c99
tree1793d8ace6ca50f9c7e77dbdc6c96a0ed7c508b1
parentf59f43139798fbfad5c87f5a080c2e70f8ab3768
block: Fix a race between blk_cleanup_queue() and timeout handling

Make sure that if the timeout timer fires after a queue has been
marked "dying" that the affected requests are finished.

Reported-by: chenxiang (M) <chenxiang66@hisilicon.com>
Fixes: commit 287922eb0b18 ("block: defer timeouts to a workqueue")
Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com>
Tested-by: chenxiang (M) <chenxiang66@hisilicon.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Keith Busch <keith.busch@intel.com>
Cc: Hannes Reinecke <hare@suse.com>
Cc: Ming Lei <ming.lei@redhat.com>
Cc: Johannes Thumshirn <jthumshirn@suse.de>
Cc: <stable@vger.kernel.org>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
(backport from upstream commit 4e9b6f20828ac880dbc1fa2fdbafae779473d1af)

Signed-off-by: Brian Maly <brian.maly@oracle.com>
Conflicts:
  block/blk-core.c
  block/blk-timeout.c

Orabug: 29158186

Reviewed-by: Junxiao Bi <junxiao.bi@oracle.com>
Signed-off-by: Jianchao Wang <jianchao.w.wang@oracle.com>
Signed-off-by: Brian Maly <brian.maly@oracle.com>
block/blk-core.c
block/blk-timeout.c