loop2: detected capacity change from 0 to 128 ================================================================== BUG: KCSAN: data-race in xas_find_marked / xas_set_mark read-write to 0xffff888106bb1478 of 8 bytes by task 22793 on cpu 1: instrument_read_write include/linux/instrumented.h:55 [inline] __instrument_read_write_bitop include/asm-generic/bitops/instrumented-non-atomic.h:84 [inline] ___test_and_set_bit include/asm-generic/bitops/instrumented-non-atomic.h:99 [inline] node_set_mark lib/xarray.c:95 [inline] xas_set_mark+0x86/0x140 lib/xarray.c:885 tag_pages_for_writeback+0xaa/0x2a0 mm/page-writeback.c:2350 write_cache_pages+0x1ad/0x740 mm/page-writeback.c:2420 mpage_writepages+0x72/0xe0 fs/mpage.c:672 fat_writepages+0x24/0x30 fs/fat/inode.c:200 do_writepages+0x1c2/0x340 mm/page-writeback.c:2553 filemap_fdatawrite_wbc+0xdb/0xf0 mm/filemap.c:388 __filemap_fdatawrite_range mm/filemap.c:421 [inline] file_write_and_wait_range+0xf4/0x190 mm/filemap.c:779 __generic_file_fsync+0x4c/0x140 fs/libfs.c:1438 fat_file_fsync+0x4c/0x100 fs/fat/file.c:191 vfs_fsync_range fs/sync.c:188 [inline] vfs_fsync fs/sync.c:202 [inline] do_fsync fs/sync.c:212 [inline] __do_sys_fdatasync fs/sync.c:225 [inline] __se_sys_fdatasync fs/sync.c:223 [inline] __x64_sys_fdatasync+0x84/0xd0 fs/sync.c:223 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xcd/0x1d0 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x63/0x6b read to 0xffff888106bb1478 of 8 bytes by task 22792 on cpu 0: xas_find_chunk include/linux/xarray.h:1723 [inline] xas_find_marked+0x216/0x660 lib/xarray.c:1354 find_get_entry+0x5d/0x290 mm/filemap.c:1961 filemap_get_folios_tag+0x136/0x210 mm/filemap.c:2211 write_cache_pages+0x20d/0x740 mm/page-writeback.c:2429 mpage_writepages+0x72/0xe0 fs/mpage.c:672 fat_writepages+0x24/0x30 fs/fat/inode.c:200 do_writepages+0x1c2/0x340 mm/page-writeback.c:2553 filemap_fdatawrite_wbc+0xdb/0xf0 mm/filemap.c:388 __filemap_fdatawrite_range mm/filemap.c:421 [inline] file_write_and_wait_range+0xf4/0x190 mm/filemap.c:779 __generic_file_fsync+0x4c/0x140 fs/libfs.c:1438 fat_file_fsync+0x4c/0x100 fs/fat/file.c:191 vfs_fsync_range fs/sync.c:188 [inline] vfs_fsync fs/sync.c:202 [inline] do_fsync fs/sync.c:212 [inline] __do_sys_fdatasync fs/sync.c:225 [inline] __se_sys_fdatasync fs/sync.c:223 [inline] __x64_sys_fdatasync+0x84/0xd0 fs/sync.c:223 do_syscall_x64 arch/x86/entry/common.c:52 [inline] do_syscall_64+0xcd/0x1d0 arch/x86/entry/common.c:83 entry_SYSCALL_64_after_hwframe+0x63/0x6b value changed: 0xffffffffffffffff -> 0xfffffffffffffff8 Reported by Kernel Concurrency Sanitizer on: CPU: 0 PID: 22792 Comm: syz-executor.2 Not tainted 6.8.0-rc4-syzkaller-00410-gc02197fc9076 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/25/2024 ================================================================== syz-executor.2: attempt to access beyond end of device loop2: rw=524288, sector=209, nr_sectors = 144 limit=128 syz-executor.2: attempt to access beyond end of device loop2: rw=0, sector=209, nr_sectors = 8 limit=128