================================================================== BUG: KCSAN: data-race in delete_from_page_cache_batch / folio_mapping write to 0xffffea0004d51398 of 8 bytes by task 18350 on cpu 1: page_cache_delete_batch mm/filemap.c:322 [inline] delete_from_page_cache_batch+0x35c/0x780 mm/filemap.c:353 truncate_inode_pages_range+0x1d5/0xa00 mm/truncate.c:336 truncate_inode_pages mm/truncate.c:435 [inline] truncate_pagecache+0x4f/0x70 mm/truncate.c:750 ext4_setattr+0x792/0xb30 fs/ext4/inode.c:5468 notify_change+0x8a3/0xac0 fs/attr.c:410 do_truncate+0xf7/0x140 fs/open.c:64 handle_truncate fs/namei.c:3082 [inline] do_open fs/namei.c:3430 [inline] path_openat+0x191f/0x1eb0 fs/namei.c:3559 do_filp_open+0x105/0x220 fs/namei.c:3586 do_sys_openat2+0xb5/0x2b0 fs/open.c:1212 do_sys_open fs/open.c:1228 [inline] __do_sys_openat fs/open.c:1244 [inline] __se_sys_openat fs/open.c:1239 [inline] __x64_sys_openat+0xef/0x110 fs/open.c:1239 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae read to 0xffffea0004d51398 of 8 bytes by task 18342 on cpu 0: folio_mapping+0x92/0x120 mm/util.c:722 page_mapping+0x37/0x50 mm/folio-compat.c:13 page_evictable mm/internal.h:124 [inline] move_pages_to_lru+0x13d/0x7c0 mm/vmscan.c:2319 shrink_inactive_list+0x414/0x730 mm/vmscan.c:2438 shrink_list mm/vmscan.c:2662 [inline] shrink_lruvec+0x3c9/0x710 mm/vmscan.c:2981 shrink_node_memcgs+0x23e/0x410 mm/vmscan.c:3170 shrink_node+0x8f6/0x1190 mm/vmscan.c:3293 shrink_zones+0x2d1/0x5e0 mm/vmscan.c:3530 do_try_to_free_pages+0x193/0x6c0 mm/vmscan.c:3588 try_to_free_mem_cgroup_pages+0x1cb/0x420 mm/vmscan.c:3902 try_charge_memcg+0x280/0xa50 mm/memcontrol.c:2592 try_charge mm/memcontrol.c:2717 [inline] mem_cgroup_charge_skmem+0x4d/0x190 mm/memcontrol.c:6998 sock_reserve_memory+0xaf/0x200 net/core/sock.c:988 sock_setsockopt+0x10a0/0x1fb0 net/core/sock.c:1443 __sys_setsockopt+0x239/0x2a0 net/socket.c:2172 __do_sys_setsockopt net/socket.c:2187 [inline] __se_sys_setsockopt net/socket.c:2184 [inline] __x64_sys_setsockopt+0x62/0x70 net/socket.c:2184 do_syscall_x64 arch/x86/entry/common.c:50 [inline] do_syscall_64+0x44/0xd0 arch/x86/entry/common.c:80 entry_SYSCALL_64_after_hwframe+0x44/0xae value changed: 0xffff88813bcadb60 -> 0x0000000000000000 Reported by Kernel Concurrency Sanitizer on: CPU: 0 PID: 18342 Comm: syz-executor.5 Not tainted 5.16.0-rc8-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 ==================================================================