diff options
author | Ming Lei <ming.lei@redhat.com> | 2023-06-16 21:23:54 +0800 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2023-06-16 10:12:25 -0600 |
commit | 245165658e1c9f95c0fecfe02b9b1ebd30a1198a (patch) | |
tree | 0afb4aef73404f0134af73f0cfcab25953a39e0b /drivers/md/dm-crypt.c | |
parent | 84bd06c632c6d5279849f5f8ab47d9517d259422 (diff) | |
download | linux-stable-245165658e1c9f95c0fecfe02b9b1ebd30a1198a.tar.gz linux-stable-245165658e1c9f95c0fecfe02b9b1ebd30a1198a.tar.bz2 linux-stable-245165658e1c9f95c0fecfe02b9b1ebd30a1198a.zip |
blk-mq: fix NULL dereference on q->elevator in blk_mq_elv_switch_none
After grabbing q->sysfs_lock, q->elevator may become NULL because of
elevator switch.
Fix the NULL dereference on q->elevator by checking it with lock.
Reported-by: Guangwu Zhang <guazhang@redhat.com>
Signed-off-by: Ming Lei <ming.lei@redhat.com>
Link: https://lore.kernel.org/r/20230616132354.415109-1-ming.lei@redhat.com
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/md/dm-crypt.c')
0 files changed, 0 insertions, 0 deletions