================================================================== BUG: KCSAN: data-race in delete_from_page_cache_batch / folio_mapping write to 0xffffea0004eb7698 of 8 bytes by task 4843 on cpu 0: page_cache_delete_batch mm/filemap.c:310 [inline] delete_from_page_cache_batch+0x32d/0x750 mm/filemap.c:336 truncate_inode_pages_range+0x34f/0x800 mm/truncate.c:369 truncate_inode_pages+0x24/0x30 mm/truncate.c:448 kill_bdev block/bdev.c:76 [inline] blkdev_flush_mapping+0xc0/0x1c0 block/bdev.c:584 blkdev_put_whole block/bdev.c:615 [inline] blkdev_put+0x36d/0x470 block/bdev.c:875 blkdev_close+0x36/0x40 block/fops.c:507 __fput+0x245/0x570 fs/file_table.c:321 ____fput+0x15/0x20 fs/file_table.c:349 task_work_run+0x123/0x160 kernel/task_work.c:179 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0xcf/0xe0 kernel/entry/common.c:171 exit_to_user_mode_prepare+0x6a/0xa0 kernel/entry/common.c:203 __syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline] syscall_exit_to_user_mode+0x26/0x140 kernel/entry/common.c:296 do_syscall_64+0x4d/0xc0 arch/x86/entry/common.c:86 entry_SYSCALL_64_after_hwframe+0x63/0xcd read to 0xffffea0004eb7698 of 8 bytes by task 3125 on cpu 1: folio_mapping+0x92/0x110 mm/util.c:774 folio_evictable mm/internal.h:156 [inline] lru_add_fn+0x92/0x450 mm/swap.c:181 folio_batch_move_lru+0x21e/0x300 mm/swap.c:217 lru_add_drain_cpu+0x77/0x250 mm/swap.c:652 lru_add_drain+0x25/0x60 mm/swap.c:752 __pagevec_release+0x3e/0x80 mm/swap.c:1059 pagevec_release include/linux/pagevec.h:63 [inline] folio_batch_release include/linux/pagevec.h:132 [inline] shmem_undo_range+0x341/0xc20 mm/shmem.c:946 shmem_truncate_range mm/shmem.c:1041 [inline] shmem_evict_inode+0x130/0x4d0 mm/shmem.c:1156 evict+0x1aa/0x410 fs/inode.c:665 iput_final fs/inode.c:1748 [inline] iput+0x42c/0x5b0 fs/inode.c:1774 dentry_unlink_inode+0x22a/0x240 fs/dcache.c:401 __dentry_kill+0x2db/0x4a0 fs/dcache.c:607 dentry_kill+0x8d/0x1e0 dput+0x118/0x1f0 fs/dcache.c:913 __fput+0x3bf/0x570 fs/file_table.c:329 ____fput+0x15/0x20 fs/file_table.c:349 task_work_run+0x123/0x160 kernel/task_work.c:179 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop+0xcf/0xe0 kernel/entry/common.c:171 exit_to_user_mode_prepare+0x6a/0xa0 kernel/entry/common.c:203 __syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline] syscall_exit_to_user_mode+0x26/0x140 kernel/entry/common.c:296 do_syscall_64+0x4d/0xc0 arch/x86/entry/common.c:86 entry_SYSCALL_64_after_hwframe+0x63/0xcd value changed: 0xffff8881023e3bc8 -> 0x0000000000000000 Reported by Kernel Concurrency Sanitizer on: CPU: 1 PID: 3125 Comm: syz-executor.0 Not tainted 6.3.0-rc3-syzkaller-00322-g4bdec23f971b #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023 ==================================================================