================================================================== BUG: KCSAN: data-race in relay_switch_subbuf / relay_switch_subbuf write to 0xffff8881078fb638 of 8 bytes by task 19040 on cpu 0: relay_switch_subbuf+0x39d/0x3b0 kernel/relay.c:708 relay_reserve include/linux/relay.h:248 [inline] __blk_add_trace+0x6a7/0x700 kernel/trace/blktrace.c:276 blk_add_trace_rq kernel/trace/blktrace.c:848 [inline] blk_add_trace_rq_issue+0x1b2/0x1c0 kernel/trace/blktrace.c:861 trace_block_rq_issue include/trace/events/block.h:227 [inline] blk_mq_start_request+0x23b/0x280 block/blk-mq.c:1252 scsi_queue_rq+0x13f3/0x15a0 drivers/scsi/scsi_lib.c:1757 blk_mq_dispatch_rq_list+0x997/0x1290 block/blk-mq.c:2056 __blk_mq_do_dispatch_sched block/blk-mq-sched.c:173 [inline] blk_mq_do_dispatch_sched+0x49d/0x7f0 block/blk-mq-sched.c:187 __blk_mq_sched_dispatch_requests+0x1cd/0x270 blk_mq_sched_dispatch_requests+0x8f/0xf0 block/blk-mq-sched.c:339 __blk_mq_run_hw_queue+0x8b/0x150 block/blk-mq.c:2174 __blk_mq_delay_run_hw_queue+0x15b/0x2e0 block/blk-mq.c:2250 blk_mq_run_hw_queue+0x1be/0x350 block/blk-mq.c:2298 blk_mq_sched_insert_requests+0x220/0x300 block/blk-mq-sched.c:493 blk_mq_dispatch_plug_list+0x1e9/0x2c0 block/blk-mq.c:2758 blk_mq_flush_plug_list+0x38a/0x3e0 block/blk-mq.c:2800 blk_add_rq_to_plug+0x142/0x390 block/blk-mq.c:1296 blk_mq_submit_bio+0x90b/0xed0 block/blk-mq.c:2991 __submit_bio block/blk-core.c:605 [inline] __submit_bio_noacct_mq block/blk-core.c:682 [inline] submit_bio_noacct_nocheck+0x83d/0xaa0 block/blk-core.c:699 submit_bio_noacct+0x6a5/0x810 block/blk-core.c:805 submit_bio+0xfb/0x110 block/blk-core.c:841 ext4_io_submit fs/ext4/page-io.c:378 [inline] io_submit_add_bh fs/ext4/page-io.c:420 [inline] ext4_bio_write_page+0x6dd/0xc20 fs/ext4/page-io.c:564 mpage_submit_page fs/ext4/inode.c:2129 [inline] mpage_map_and_submit_buffers fs/ext4/inode.c:2374 [inline] mpage_map_and_submit_extent fs/ext4/inode.c:2513 [inline] ext4_do_writepages+0x11a8/0x1e70 fs/ext4/inode.c:2877 ext4_writepages+0x11b/0x240 fs/ext4/inode.c:2965 do_writepages+0x1db/0x350 mm/page-writeback.c:2581 filemap_fdatawrite_wbc+0xd6/0xf0 mm/filemap.c:388 __filemap_fdatawrite_range mm/filemap.c:421 [inline] __filemap_fdatawrite mm/filemap.c:427 [inline] filemap_flush+0x93/0xc0 mm/filemap.c:454 ext4_alloc_da_blocks+0x47/0x100 fs/ext4/inode.c:3219 ext4_release_file+0x5b/0x1d0 fs/ext4/file.c:158 __fput+0x245/0x570 fs/file_table.c:320 ____fput+0x11/0x20 fs/file_table.c:348 task_work_run+0xde/0x110 kernel/task_work.c:179 exit_task_work include/linux/task_work.h:38 [inline] do_exit+0x5a0/0x16e0 kernel/exit.c:867 do_group_exit+0xfe/0x140 kernel/exit.c:1012 get_signal+0xb4b/0xc70 kernel/signal.c:2859 arch_do_signal_or_restart+0x85/0x290 arch/x86/kernel/signal.c:306 exit_to_user_mode_loop+0x78/0x130 kernel/entry/common.c:168 exit_to_user_mode_prepare+0x69/0x90 kernel/entry/common.c:203 irqentry_exit_to_user_mode+0x5/0x10 kernel/entry/common.c:309 irqentry_exit+0xe/0x40 kernel/entry/common.c:412 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:570 write to 0xffff8881078fb638 of 8 bytes by task 19034 on cpu 1: relay_switch_subbuf+0x39d/0x3b0 kernel/relay.c:708 relay_reserve include/linux/relay.h:248 [inline] __blk_add_trace+0x6a7/0x700 kernel/trace/blktrace.c:276 blk_add_trace_bio kernel/trace/blktrace.c:907 [inline] blk_add_trace_getrq+0x12e/0x140 kernel/trace/blktrace.c:944 trace_block_getrq include/trace/events/block.h:366 [inline] blk_mq_submit_bio+0xe74/0xed0 block/blk-mq.c:2971 __submit_bio block/blk-core.c:605 [inline] __submit_bio_noacct_mq block/blk-core.c:682 [inline] submit_bio_noacct_nocheck+0x83d/0xaa0 block/blk-core.c:699 submit_bio_noacct+0x6a5/0x810 block/blk-core.c:805 submit_bio+0xfb/0x110 block/blk-core.c:841 ext4_io_submit fs/ext4/page-io.c:378 [inline] io_submit_add_bh fs/ext4/page-io.c:420 [inline] ext4_bio_write_page+0x6dd/0xc20 fs/ext4/page-io.c:564 mpage_submit_page fs/ext4/inode.c:2129 [inline] mpage_map_and_submit_buffers fs/ext4/inode.c:2374 [inline] mpage_map_and_submit_extent fs/ext4/inode.c:2513 [inline] ext4_do_writepages+0x11a8/0x1e70 fs/ext4/inode.c:2877 ext4_writepages+0x11b/0x240 fs/ext4/inode.c:2965 do_writepages+0x1db/0x350 mm/page-writeback.c:2581 filemap_fdatawrite_wbc+0xd6/0xf0 mm/filemap.c:388 __filemap_fdatawrite_range mm/filemap.c:421 [inline] __filemap_fdatawrite mm/filemap.c:427 [inline] filemap_flush+0x93/0xc0 mm/filemap.c:454 ext4_alloc_da_blocks+0x47/0x100 fs/ext4/inode.c:3219 ext4_release_file+0x5b/0x1d0 fs/ext4/file.c:158 __fput+0x245/0x570 fs/file_table.c:320 ____fput+0x11/0x20 fs/file_table.c:348 task_work_run+0xde/0x110 kernel/task_work.c:179 exit_task_work include/linux/task_work.h:38 [inline] do_exit+0x5a0/0x16e0 kernel/exit.c:867 do_group_exit+0xfe/0x140 kernel/exit.c:1012 get_signal+0xb4b/0xc70 kernel/signal.c:2859 arch_do_signal_or_restart+0x85/0x290 arch/x86/kernel/signal.c:306 exit_to_user_mode_loop+0x78/0x130 kernel/entry/common.c:168 exit_to_user_mode_prepare+0x69/0x90 kernel/entry/common.c:203 irqentry_exit_to_user_mode+0x5/0x10 kernel/entry/common.c:309 irqentry_exit+0xe/0x40 kernel/entry/common.c:412 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:570 value changed: 0x0000000000000038 -> 0x0000000000000030 Reported by Kernel Concurrency Sanitizer on: CPU: 1 PID: 19034 Comm: syz-executor.0 Tainted: G W 6.2.0-rc2-syzkaller-00203-g1f5abbd77e2c-dirty #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 ==================================================================