syzbot


KCSAN: data-race in blk_mq_dispatch_rq_list / blk_mq_run_hw_queue (3)

Status: auto-closed as invalid on 2022/04/13 13:43
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 264d, last: 264d
similar bugs (2):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in blk_mq_dispatch_rq_list / blk_mq_run_hw_queue 1 510d 510d 0/24 auto-closed as invalid on 2021/08/10 19:35
upstream KCSAN: data-race in blk_mq_dispatch_rq_list / blk_mq_run_hw_queue (2) 1 459d 459d 0/24 auto-closed as invalid on 2021/09/30 19:36

Sample crash report:
==================================================================
BUG: KCSAN: data-race in blk_mq_dispatch_rq_list / blk_mq_run_hw_queue

write to 0xffff88810272a810 of 8 bytes by task 72 on cpu 1:
 __list_splice include/linux/list.h:453 [inline]
 list_splice_tail_init include/linux/list.h:508 [inline]
 blk_mq_dispatch_rq_list+0xda5/0x11e0 block/blk-mq.c:1903
 __blk_mq_sched_dispatch_requests+0x1b4/0x270 block/blk-mq-sched.c:299
 blk_mq_sched_dispatch_requests+0x9f/0x110 block/blk-mq-sched.c:332
 __blk_mq_run_hw_queue+0x7e/0x100 block/blk-mq.c:1972
 __blk_mq_delay_run_hw_queue+0x19c/0x390 block/blk-mq.c:2049
 blk_mq_run_hw_queue+0x180/0x310 block/blk-mq.c:2100
 blk_mq_run_hw_queues+0x1d1/0x230 block/blk-mq.c:2163
 scsi_run_queue+0x681/0x6b0 drivers/scsi/scsi_lib.c:461
 scsi_requeue_run_queue+0x21/0x30 drivers/scsi/scsi_lib.c:471
 process_one_work+0x3f6/0x960 kernel/workqueue.c:2307
 worker_thread+0x616/0xa70 kernel/workqueue.c:2454
 kthread+0x1bf/0x1e0 kernel/kthread.c:377
 ret_from_fork+0x1f/0x30

read to 0xffff88810272a810 of 8 bytes by task 20887 on cpu 0:
 list_empty_careful include/linux/list.h:329 [inline]
 blk_mq_hctx_has_pending block/blk-mq.c:100 [inline]
 blk_mq_run_hw_queue+0x19b/0x310 block/blk-mq.c:2095
 blk_mq_sched_insert_requests+0x1cc/0x2a0 block/blk-mq-sched.c:486
 blk_mq_flush_plug_list+0x5c3/0x6c0 block/blk-mq.c:2632
 blk_add_rq_to_plug+0x13f/0x3a0 block/blk-mq.c:2694
 blk_mq_submit_bio+0x8d1/0xec0 block/blk-mq.c:2835
 __submit_bio+0x151/0x350 block/blk-core.c:800
 __submit_bio_noacct_mq block/blk-core.c:875 [inline]
 submit_bio_noacct+0x475/0x4e0 block/blk-core.c:901
 submit_bio+0x10c/0x180
 iomap_dio_submit_bio fs/iomap/direct-io.c:66 [inline]
 iomap_dio_bio_iter+0x9ed/0xc70 fs/iomap/direct-io.c:351
 __iomap_dio_rw+0x8d6/0x10a0 fs/iomap/direct-io.c:590
 iomap_dio_rw+0x38/0x80 fs/iomap/direct-io.c:680
 ext4_dio_write_iter fs/ext4/file.c:564 [inline]
 ext4_file_write_iter+0x7d5/0xda0 fs/ext4/file.c:675
 call_write_iter include/linux/fs.h:2074 [inline]
 do_iter_readv_writev+0x2de/0x380 fs/read_write.c:725
 do_iter_write+0x192/0x5c0 fs/read_write.c:851
 vfs_writev fs/read_write.c:924 [inline]
 do_pwritev+0x235/0x440 fs/read_write.c:1021
 __do_sys_pwritev fs/read_write.c:1068 [inline]
 __se_sys_pwritev fs/read_write.c:1063 [inline]
 __x64_sys_pwritev+0x54/0x60 fs/read_write.c:1063
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x44/0xae

value changed: 0xffff88810272a808 -> 0xffff888103165ec8

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 20887 Comm: syz-executor.5 Not tainted 5.17.0-rc7-syzkaller-00060-g92f90cc9fe0e-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================

Crashes (1):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2022/03/09 13:41 upstream 92f90cc9fe0e 9e8eaa75 .config log report info KCSAN: data-race in blk_mq_dispatch_rq_list / blk_mq_run_hw_queue
* Struck through repros no longer work on HEAD.