syzbot


KCSAN: data-race in blk_mq_start_request / bt_for_each (2)

Status: moderation: reported on 2024/08/30 13:14
Subsystems: block
[Documentation on labels]
Reported-by: syzbot+3912f6af732771b057ba@syzkaller.appspotmail.com
First crash: 82d, last: 28d
Similar bugs (1)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in blk_mq_start_request / bt_for_each block 1 298d 298d 0/28 auto-obsoleted due to no activity on 2024/03/02 18:09

Sample crash report:
==================================================================
BUG: KCSAN: data-race in blk_mq_start_request / bt_for_each

write to 0xffff888101450fd0 of 8 bytes by task 46 on cpu 1:
 blk_mq_start_request+0x1e4/0x3b0 block/blk-mq.c:1259
 loop_queue_rq+0x44/0x660 drivers/block/loop.c:1846
 blk_mq_dispatch_rq_list+0x2a2/0xf30 block/blk-mq.c:2030
 __blk_mq_sched_dispatch_requests+0x1ce/0xd50 block/blk-mq-sched.c:301
 blk_mq_sched_dispatch_requests+0x78/0xe0 block/blk-mq-sched.c:331
 blk_mq_run_hw_queue+0x29c/0x4d0 block/blk-mq.c:2243
 blk_mq_run_hw_queues+0x15b/0x1e0 block/blk-mq.c:2292
 blk_mq_requeue_work+0x3fa/0x430 block/blk-mq.c:1477
 process_one_work kernel/workqueue.c:3229 [inline]
 process_scheduled_works+0x483/0x9a0 kernel/workqueue.c:3310
 worker_thread+0x51d/0x6f0 kernel/workqueue.c:3391
 kthread+0x1d1/0x210 kernel/kthread.c:389
 ret_from_fork+0x4b/0x60 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244

read to 0xffff888101450fd0 of 8 bytes by task 80 on cpu 0:
 blk_mq_find_and_get_req block/blk-mq-tag.c:260 [inline]
 bt_iter block/blk-mq-tag.c:288 [inline]
 __sbitmap_for_each_set include/linux/sbitmap.h:286 [inline]
 sbitmap_for_each_set include/linux/sbitmap.h:307 [inline]
 bt_for_each+0x279/0x480 block/blk-mq-tag.c:325
 blk_mq_queue_tag_busy_iter+0x1a4/0x330 block/blk-mq-tag.c:534
 blk_mq_timeout_work+0xc4/0x350 block/blk-mq.c:1637
 process_one_work kernel/workqueue.c:3229 [inline]
 process_scheduled_works+0x483/0x9a0 kernel/workqueue.c:3310
 worker_thread+0x51d/0x6f0 kernel/workqueue.c:3391
 kthread+0x1d1/0x210 kernel/kthread.c:389
 ret_from_fork+0x4b/0x60 arch/x86/kernel/process.c:147
 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244

value changed: 0xffff8881021db700 -> 0xffff8881010ac800

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 UID: 0 PID: 80 Comm: kworker/0:1H Not tainted 6.12.0-rc4-syzkaller-00047-gc2ee9f594da8 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
Workqueue: kblockd blk_mq_timeout_work
==================================================================

Crashes (3):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/10/23 22:35 upstream c2ee9f594da8 15fa2979 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in blk_mq_start_request / bt_for_each
2024/10/03 23:51 upstream 7ec462100ef9 d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in blk_mq_start_request / bt_for_each
2024/08/30 13:14 upstream 20371ba12063 ee2602b8 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in blk_mq_start_request / bt_for_each
* Struck through repros no longer work on HEAD.