loop4: detected capacity change from 0 to 264192 ================================================================== BUG: KCSAN: data-race in drain_all_stock / drain_stock write to 0xffff888237c283e8 of 8 bytes by task 14937 on cpu 0: drain_stock+0x88/0x110 mm/memcontrol.c:2209 __refill_stock mm/memcontrol.c:2245 [inline] refill_stock+0x85/0x130 mm/memcontrol.c:2260 try_charge_memcg+0x7bb/0xa40 mm/memcontrol.c:2711 obj_cgroup_charge_pages mm/memcontrol.c:3040 [inline] obj_cgroup_charge+0x171/0x2b0 mm/memcontrol.c:3330 memcg_slab_pre_alloc_hook mm/slab.h:496 [inline] slab_pre_alloc_hook mm/slab.h:705 [inline] slab_alloc mm/slab.c:3278 [inline] __kmem_cache_alloc_lru mm/slab.c:3471 [inline] kmem_cache_alloc+0x92/0x2f0 mm/slab.c:3491 kmem_cache_zalloc include/linux/slab.h:723 [inline] __alloc_file+0x2e/0x150 fs/file_table.c:138 alloc_empty_file+0xcd/0x1c0 fs/file_table.c:187 path_openat+0x65/0x1b00 fs/namei.c:3677 do_filp_open+0x105/0x220 fs/namei.c:3718 do_sys_openat2+0xb5/0x2a0 fs/open.c:1313 do_sys_open fs/open.c:1329 [inline] __do_sys_openat fs/open.c:1345 [inline] __se_sys_openat fs/open.c:1340 [inline] __x64_sys_openat+0xef/0x110 fs/open.c:1340 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 0xffff888237c283e8 of 8 bytes by task 14927 on cpu 1: drain_all_stock+0xcc/0x310 mm/memcontrol.c:2289 try_charge_memcg+0x63a/0xa40 mm/memcontrol.c:2635 try_charge mm/memcontrol.c:2769 [inline] mem_cgroup_charge_skmem+0x4d/0x130 mm/memcontrol.c:7119 sock_reserve_memory+0xb0/0x3a0 net/core/sock.c:1016 sock_setsockopt+0xeeb/0x1a40 net/core/sock.c:1482 __sys_setsockopt+0x242/0x2b0 net/socket.c:2248 __do_sys_setsockopt net/socket.c:2263 [inline] __se_sys_setsockopt net/socket.c:2260 [inline] __x64_sys_setsockopt+0x62/0x70 net/socket.c:2260 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: 0xffff888139514000 -> 0xffff888139349000 Reported by Kernel Concurrency Sanitizer on: CPU: 1 PID: 14927 Comm: syz-executor.4 Not tainted 6.0.0-rc7-syzkaller-00250-ga962b54e162c-dirty #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/22/2022 ==================================================================