================================================================== BUG: KCSAN: data-race in __filemap_add_folio / file_write_and_wait_range read-write to 0xffff88810aef67b0 of 8 bytes by task 12300 on cpu 0: __filemap_add_folio+0x38c/0x720 mm/filemap.c:900 filemap_add_folio+0x6f/0x150 mm/filemap.c:935 page_cache_ra_unbounded+0x15e/0x2e0 mm/readahead.c:251 do_page_cache_ra mm/readahead.c:300 [inline] page_cache_ra_order mm/readahead.c:560 [inline] ondemand_readahead+0x550/0x6c0 mm/readahead.c:682 page_cache_sync_ra+0x284/0x2a0 mm/readahead.c:709 page_cache_sync_readahead include/linux/pagemap.h:1210 [inline] filemap_get_pages mm/filemap.c:2601 [inline] filemap_read+0x415/0x14b0 mm/filemap.c:2695 generic_file_read_iter+0x76/0x320 mm/filemap.c:2841 ext4_file_read_iter+0x1cc/0x290 call_read_iter include/linux/fs.h:1843 [inline] generic_file_splice_read+0xe3/0x290 fs/splice.c:309 do_splice_to fs/splice.c:793 [inline] splice_direct_to_actor+0x25a/0x5f0 fs/splice.c:865 do_splice_direct+0x104/0x180 fs/splice.c:974 do_sendfile+0x3b8/0x950 fs/read_write.c:1255 __do_sys_sendfile64 fs/read_write.c:1323 [inline] __se_sys_sendfile64 fs/read_write.c:1309 [inline] __x64_sys_sendfile64+0x110/0x150 fs/read_write.c:1309 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd read to 0xffff88810aef67b0 of 8 bytes by task 12299 on cpu 1: mapping_needs_writeback mm/filemap.c:624 [inline] file_write_and_wait_range+0x6a/0x190 mm/filemap.c:776 ext4_sync_file+0x10d/0x720 fs/ext4/fsync.c:151 vfs_fsync_range+0x10b/0x120 fs/sync.c:188 generic_write_sync include/linux/fs.h:2450 [inline] iomap_dio_complete+0x3f1/0x470 fs/iomap/direct-io.c:128 iomap_dio_rw+0x62/0x90 fs/iomap/direct-io.c:693 ext4_dio_write_iter fs/ext4/file.c:587 [inline] ext4_file_write_iter+0xadf/0x1270 fs/ext4/file.c:698 do_iter_write+0x418/0x700 fs/read_write.c:861 vfs_iter_write+0x50/0x70 fs/read_write.c:902 iter_file_splice_write+0x42b/0x7b0 fs/splice.c:686 do_splice_from fs/splice.c:764 [inline] direct_splice_actor+0x84/0xa0 fs/splice.c:931 splice_direct_to_actor+0x2ee/0x5f0 fs/splice.c:886 do_splice_direct+0x104/0x180 fs/splice.c:974 do_sendfile+0x3b8/0x950 fs/read_write.c:1255 __do_sys_sendfile64 fs/read_write.c:1323 [inline] __se_sys_sendfile64 fs/read_write.c:1309 [inline] __x64_sys_sendfile64+0x110/0x150 fs/read_write.c:1309 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x63/0xcd value changed: 0x00000000000000d5 -> 0x00000000000000d6 Reported by Kernel Concurrency Sanitizer on: CPU: 1 PID: 12299 Comm: syz-executor.5 Not tainted 6.2.0-syzkaller-00081-g91bc559d8d3a-dirty #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/21/2023 ==================================================================