diff options
| author | Ming Lei <[email protected]> | 2020-09-01 10:07:38 +0000 |
|---|---|---|
| committer | Jens Axboe <[email protected]> | 2020-09-01 14:34:08 +0000 |
| commit | cafe01ef8fcb248583038e1be071383530fe355a (patch) | |
| tree | af141eea39609d18694bc3a9f8531ce53c8c3254 /net/switchdev/switchdev.c | |
| parent | block: ensure bdi->io_pages is always initialized (diff) | |
| download | kernel-cafe01ef8fcb248583038e1be071383530fe355a.tar.gz kernel-cafe01ef8fcb248583038e1be071383530fe355a.zip | |
block: release disk reference in hd_struct_free_work
Commit e8c7d14ac6c3 ("block: revert back to synchronous request_queue removal")
stops to release request queue from wq context because that commit
supposed all blk_put_queue() is called in context which is allowed
to sleep. However, this assumption isn't true because we release disk's
reference in partition's percpu_ref's ->release() which doesn't allow
to sleep, because the ->release() is run via call_rcu().
Fixes this issue by moving put disk reference into hd_struct_free_work()
Fixes: e8c7d14ac6c3 ("block: revert back to synchronous request_queue removal")
Reported-by: Ilya Dryomov <[email protected]>
Signed-off-by: Ming Lei <[email protected]>
Tested-by: Ilya Dryomov <[email protected]>
Reviewed-by: Christoph Hellwig <[email protected]>
Cc: Luis Chamberlain <[email protected]>
Cc: Christoph Hellwig <[email protected]>
Cc: Bart Van Assche <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
Diffstat (limited to 'net/switchdev/switchdev.c')
0 files changed, 0 insertions, 0 deletions
