syzbot


KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue (2)

Status: auto-closed as invalid on 2022/02/26 09:45
Reported-by: syzbot+@syzkaller.appspotmail.com
First crash: 320d, last: 310d
similar bugs (4):
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue (5) 1 47d 47d 0/24 auto-obsoleted due to no activity on 2022/11/15 22:27
upstream KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue 1 379d 379d 0/24 auto-closed as invalid on 2021/12/18 22:19
upstream KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue (3) 1 260d 260d 0/24 auto-closed as invalid on 2022/04/17 09:14
upstream KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue (4) 11 97d 219d 0/24 auto-closed as invalid on 2022/09/26 17:17

Sample crash report:
==================================================================
BUG: KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue

write to 0xffff888101e28be4 of 4 bytes by task 1920 on cpu 1:
 __blk_mq_unfreeze_queue block/blk-mq.c:223 [inline]
 blk_mq_unfreeze_queue+0x3c/0xc0 block/blk-mq.c:234
 __loop_clr_fd+0x488/0x5d0 drivers/block/loop.c:1147
 loop_rundown_workfn+0x3e/0xb0 drivers/block/loop.c:1185
 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 0xffff888101e28be4 of 4 bytes by task 1233 on cpu 0:
 __bio_queue_enter+0x1ea/0x500 block/blk-core.c:403
 bio_queue_enter block/blk.h:81 [inline]
 blk_mq_get_new_requests block/blk-mq.c:2726 [inline]
 blk_mq_submit_bio+0x4b7/0xe50 block/blk-mq.c:2806
 __submit_bio+0x151/0x350 block/blk-core.c:806
 __submit_bio_noacct_mq block/blk-core.c:881 [inline]
 submit_bio_noacct+0x418/0x4e0 block/blk-core.c:907
 submit_bio+0x10c/0x180
 mpage_bio_submit fs/mpage.c:66 [inline]
 mpage_readahead+0x27d/0x2c0 fs/mpage.c:393
 blkdev_readahead+0x18/0x20 block/fops.c:401
 read_pages+0xba/0x5f0 mm/readahead.c:129
 page_cache_ra_unbounded+0x3a6/0x400 mm/readahead.c:238
 do_page_cache_ra mm/readahead.c:268 [inline]
 force_page_cache_ra+0x1e6/0x220 mm/readahead.c:300
 page_cache_sync_ra+0xcc/0xe0 mm/readahead.c:574
 page_cache_sync_readahead include/linux/pagemap.h:1056 [inline]
 filemap_get_pages mm/filemap.c:2511 [inline]
 filemap_read+0x3ed/0x1430 mm/filemap.c:2598
 blkdev_read_iter+0xcb/0x350 block/fops.c:610
 call_read_iter include/linux/fs.h:2080 [inline]
 new_sync_read fs/read_write.c:400 [inline]
 vfs_read+0x66c/0x750 fs/read_write.c:481
 ksys_read+0xd9/0x190 fs/read_write.c:619
 __do_sys_read fs/read_write.c:629 [inline]
 __se_sys_read fs/read_write.c:627 [inline]
 __x64_sys_read+0x3e/0x50 fs/read_write.c:627
 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: 0x00000001 -> 0x00000000

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 PID: 1233 Comm: udevd Not tainted 5.16.0-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
==================================================================
I/O error, dev loop5, sector 0 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0
I/O error, dev loop3, sector 264064 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0
I/O error, dev loop5, sector 264064 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0
I/O error, dev loop5, sector 0 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0

Crashes (4):
Manager Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Title
ci2-upstream-kcsan-gce 2022/01/22 09:43 upstream 0809edbae347 214351e1 .config log report info KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue
ci2-upstream-kcsan-gce 2022/01/19 02:33 upstream 99613159ad74 731a2d23 .config log report info KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue
ci2-upstream-kcsan-gce 2022/01/14 03:31 upstream 455e73a07f6e b8d780ab .config log report info KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue
ci2-upstream-kcsan-gce 2022/01/12 10:02 upstream 6f38be8f2ccd 44d1319a .config log report info KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue
* Struck through repros no longer work on HEAD.