================================================================== BUG: KCSAN: data-race in page_cache_delete / shmem_getpage_gfp read-write to 0xffff8881397085b0 of 8 bytes by task 4154 on cpu 0: page_cache_delete+0x32c/0x360 mm/filemap.c:145 __filemap_remove_folio+0x3b/0xf0 mm/filemap.c:223 filemap_remove_folio+0x69/0x120 mm/filemap.c:255 truncate_inode_folio+0x204/0x210 mm/truncate.c:196 shmem_undo_range+0x3d2/0x1160 mm/shmem.c:952 shmem_truncate_range mm/shmem.c:1044 [inline] shmem_fallocate+0x29b/0x980 mm/shmem.c:2698 vfs_fallocate+0x355/0x3d0 fs/open.c:323 madvise_remove+0x126/0x1e0 mm/madvise.c:976 madvise_vma_behavior mm/madvise.c:1000 [inline] madvise_walk_vmas mm/madvise.c:1232 [inline] do_madvise+0x556/0x1300 mm/madvise.c:1410 __do_sys_madvise mm/madvise.c:1423 [inline] __se_sys_madvise mm/madvise.c:1421 [inline] __x64_sys_madvise+0x5d/0x70 mm/madvise.c:1421 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+0x63/0xcd read to 0xffff8881397085b0 of 8 bytes by task 4152 on cpu 1: shmem_recalc_inode mm/shmem.c:362 [inline] shmem_getpage_gfp+0xd8b/0x1750 mm/shmem.c:1949 shmem_fault+0xd2/0x350 mm/shmem.c:2116 __do_fault mm/memory.c:4165 [inline] do_read_fault mm/memory.c:4511 [inline] do_fault+0x500/0xb20 mm/memory.c:4640 handle_pte_fault mm/memory.c:4904 [inline] __handle_mm_fault mm/memory.c:5043 [inline] handle_mm_fault+0x889/0xa90 mm/memory.c:5141 faultin_page mm/gup.c:953 [inline] __get_user_pages+0x34a/0xbf0 mm/gup.c:1174 populate_vma_page_range mm/gup.c:1518 [inline] __mm_populate+0x26e/0x3a0 mm/gup.c:1631 mm_populate include/linux/mm.h:2706 [inline] vm_mmap_pgoff+0x160/0x1f0 mm/util.c:557 ksys_mmap_pgoff+0xc2/0x320 mm/mmap.c:1633 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+0x63/0xcd value changed: 0x00000000000007f0 -> 0x00000000000007e4 Reported by Kernel Concurrency Sanitizer on: CPU: 1 PID: 4152 Comm: syz-executor.5 Not tainted 5.19.0-rc6-syzkaller-00104-g72a8e05d4f66-dirty #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 06/29/2022 ==================================================================