================================================================== BUG: KCSAN: data-race in __bio_queue_enter / blk_mq_unfreeze_queue read-write to 0xffff8881010c5e2c of 4 bytes by task 1819 on cpu 1: __blk_mq_unfreeze_queue block/blk-mq.c:225 [inline] blk_mq_unfreeze_queue+0x34/0xb0 block/blk-mq.c:236 __loop_clr_fd+0x244/0x3c0 drivers/block/loop.c:1167 loop_clr_fd drivers/block/loop.c:1252 [inline] lo_ioctl+0xd8c/0x1290 drivers/block/loop.c:1558 blkdev_ioctl+0x20e/0x440 block/ioctl.c:614 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:870 [inline] __se_sys_ioctl+0xcb/0x140 fs/ioctl.c:856 __x64_sys_ioctl+0x3f/0x50 fs/ioctl.c:856 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x46/0xb0 read to 0xffff8881010c5e2c of 4 bytes by task 5567 on cpu 0: __bio_queue_enter+0x1ea/0x500 block/blk-core.c:395 bio_queue_enter block/blk.h:81 [inline] blk_mq_get_new_requests block/blk-mq.c:2739 [inline] blk_mq_submit_bio+0x476/0xe40 block/blk-mq.c:2826 __submit_bio block/blk-core.c:661 [inline] __submit_bio_noacct_mq block/blk-core.c:738 [inline] submit_bio_noacct_nocheck+0x83d/0xaa0 block/blk-core.c:755 submit_bio_noacct+0x690/0x7f0 block/blk-core.c:862 submit_bio+0xfb/0x110 mpage_bio_submit fs/mpage.c:64 [inline] mpage_readahead+0x3ab/0x3f0 fs/mpage.c:360 blkdev_readahead+0x18/0x20 block/fops.c:382 read_pages+0xa5/0x750 mm/readahead.c:158 page_cache_ra_unbounded+0x2a8/0x2e0 mm/readahead.c:261 do_page_cache_ra mm/readahead.c:291 [inline] force_page_cache_ra+0x1c6/0x200 mm/readahead.c:322 page_cache_sync_ra+0xc8/0xf0 mm/readahead.c:691 page_cache_sync_readahead include/linux/pagemap.h:1234 [inline] filemap_get_pages mm/filemap.c:2592 [inline] filemap_read+0x3e5/0x1400 mm/filemap.c:2679 blkdev_read_iter+0x2c6/0x370 block/fops.c:594 call_read_iter include/linux/fs.h:2052 [inline] new_sync_read fs/read_write.c:401 [inline] vfs_read+0x5a5/0x6a0 fs/read_write.c:482 ksys_read+0xe8/0x1a0 fs/read_write.c:620 __do_sys_read fs/read_write.c:630 [inline] __se_sys_read fs/read_write.c:628 [inline] __x64_sys_read+0x3e/0x50 fs/read_write.c:628 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x2b/0x70 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x46/0xb0 value changed: 0x00000001 -> 0x00000000 Reported by Kernel Concurrency Sanitizer on: CPU: 0 PID: 5567 Comm: udevd Not tainted 5.19.0-rc1-syzkaller-00023-g34f4335c16a5-dirty #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 ================================================================== I/O error, dev loop2, sector 0 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0 blk_print_req_error: 179 callbacks suppressed I/O error, dev loop1, sector 16128 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0 I/O error, dev loop1, sector 0 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 0 Buffer I/O error on dev loop1, logical block 0, async page read loop1: unable to read partition table loop1: partition table beyond EOD, truncated I/O error, dev loop1, sector 16128 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0 I/O error, dev loop1, sector 16128 op 0x0:(READ) flags 0x80700 phys_seg 1 prio class 0 I/O error, dev loop1, sector 0 op 0x0:(READ) flags 0x0 phys_seg 1 prio class 0 Buffer I/O error on dev loop1, logical block 0, async page read loop1: unable to read partition table loop1: partition table beyond EOD, truncated Buffer I/O error on dev loop1, logical block 0, async page read loop1: unable to read partition table loop1: partition table beyond EOD, truncated