syzkaller login: [ 29.759254] BUG: Bad rss-counter state mm:00000000f9663fdd type:MM_FILEPAGES val:33 [ 29.761250] BUG: Bad rss-counter state mm:00000000f9663fdd type:MM_ANONPAGES val:22 [ 29.935645] ================================================================== [ 29.936872] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 29.938131] Read of size 8 at addr ffff8880103356b0 by task sshd/221 [ 29.939223] [ 29.939485] CPU: 1 PID: 221 Comm: sshd Not tainted 6.4.0-rc7-next-20230619 #1 [ 29.940387] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 29.941444] Call Trace: [ 29.941781] [ 29.942097] dump_stack_lvl+0x91/0xf0 [ 29.942624] print_report+0xcc/0x620 [ 29.943146] ? __virt_addr_valid+0x102/0x340 [ 29.943729] ? vma_interval_tree_remove+0xc75/0xec0 [ 29.944386] ? vma_interval_tree_remove+0xc75/0xec0 [ 29.945046] kasan_report+0xbe/0xf0 [ 29.945544] ? vma_interval_tree_remove+0xc75/0xec0 [ 29.946179] vma_interval_tree_remove+0xc75/0xec0 [ 29.946787] vma_prepare+0xc54/0x11a0 [ 29.947275] __split_vma+0x5af/0x950 [ 29.947755] ? __pfx___split_vma+0x10/0x10 [ 29.948310] ? find_held_lock+0x2c/0x110 [ 29.948871] do_vmi_align_munmap+0x2ba/0x11f0 [ 29.949443] ? lock_is_held_type+0x9f/0x120 [ 29.949989] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 29.950605] ? mtree_range_walk+0x632/0x900 [ 29.951158] ? mas_walk+0x5c7/0x7c0 [ 29.951632] do_vmi_munmap+0x1f1/0x2b0 [ 29.952126] mmap_region+0x1f9/0x2660 [ 29.952630] ? vm_mmap_pgoff+0x15c/0x3a0 [ 29.953146] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 29.953863] ? __pfx_lock_acquire+0x10/0x10 [ 29.954398] ? __pfx_mmap_region+0x10/0x10 [ 29.954932] ? security_mmap_addr+0x7d/0xa0 [ 29.955465] ? get_unmapped_area+0x1f5/0x3f0 [ 29.956065] do_mmap+0x854/0xf00 [ 29.956536] vm_mmap_pgoff+0x1a6/0x3a0 [ 29.957088] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 29.957693] ksys_mmap_pgoff+0x3af/0x500 [ 29.958244] do_syscall_64+0x3f/0x90 [ 29.958756] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 29.959449] RIP: 0033:0x7f62efc7ed82 [ 29.959936] Code: eb aa 66 0f 1f 44 00 00 41 f7 c1 ff 0f 00 00 75 27 55 48 89 fd 53 89 cb 48 85 ff 74 33 41 89 da 48 89 ef b8 09 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 56 5b 5d c3 0f 1f 00 c7 05 ae 03 01 00 16 00 [ 29.962208] RSP: 002b:00007ffcf833f8e8 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 29.963174] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007f62efc7ed82 [ 29.964083] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007f62ef0b8000 [ 29.964989] RBP: 00007f62ef0b8000 R08: 0000000000000009 R09: 0000000000001000 [ 29.965892] R10: 0000000000000812 R11: 0000000000000206 R12: 0000558834312ec0 [ 29.966800] R13: 00007ffcf833f900 R14: 00007ffcf833f930 R15: 00007ffcf833fc90 [ 29.967713] [ 29.968028] [ 29.968258] Allocated by task 212: [ 29.968735] kasan_save_stack+0x22/0x50 [ 29.969268] kasan_set_track+0x25/0x30 [ 29.969797] __kasan_slab_alloc+0x59/0x70 [ 29.970356] kmem_cache_alloc+0x16b/0x370 [ 29.970907] vm_area_dup+0x20/0x160 [ 29.971391] __split_vma+0x170/0x950 [ 29.971886] split_vma+0xc6/0x110 [ 29.972356] mprotect_fixup+0x8d2/0xb30 [ 29.972902] do_mprotect_pkey+0x87e/0xd40 [ 29.973452] __x64_sys_mprotect+0x78/0xc0 [ 29.974005] do_syscall_64+0x3f/0x90 [ 29.974508] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 29.975192] [ 29.975421] Freed by task 212: [ 29.975840] kasan_save_stack+0x22/0x50 [ 29.976377] kasan_set_track+0x25/0x30 [ 29.976917] kasan_save_free_info+0x2b/0x50 [ 29.977483] __kasan_slab_free+0x10a/0x190 [ 29.978049] kmem_cache_free+0x10d/0x4d0 [ 29.978589] rcu_core+0x8c8/0x2860 [ 29.979068] __do_softirq+0x1b7/0x7d4 [ 29.979570] [ 29.979871] Last potentially related work creation: [ 29.980506] kasan_save_stack+0x22/0x50 [ 29.981062] __kasan_record_aux_stack+0x8e/0xa0 [ 29.981675] __call_rcu_common.constprop.0+0x6a/0xb90 [ 29.982361] remove_vma+0x139/0x170 [ 29.982839] do_vmi_align_munmap+0xd4a/0x11f0 [ 29.983435] do_vmi_munmap+0x1f1/0x2b0 [ 29.983961] __vm_munmap+0x138/0x3a0 [ 29.984462] __x64_sys_munmap+0x59/0x80 [ 29.985006] do_syscall_64+0x3f/0x90 [ 29.985508] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 29.986186] [ 29.986417] Second to last potentially related work creation: [ 29.987147] kasan_save_stack+0x22/0x50 [ 29.987684] __kasan_record_aux_stack+0x8e/0xa0 [ 29.988292] __call_rcu_common.constprop.0+0x6a/0xb90 [ 29.989001] remove_vma+0x139/0x170 [ 29.989482] do_vmi_align_munmap+0xd4a/0x11f0 [ 29.990070] do_vmi_munmap+0x1f1/0x2b0 [ 29.990587] mmap_region+0x1f9/0x2660 [ 29.991098] do_mmap+0x854/0xf00 [ 29.991556] vm_mmap_pgoff+0x1a6/0x3a0 [ 29.992080] ksys_mmap_pgoff+0x3af/0x500 [ 29.992625] do_syscall_64+0x3f/0x90 [ 29.993132] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 29.993820] [ 29.994053] The buggy address belongs to the object at ffff888010335658 [ 29.994053] which belongs to the cache vm_area_struct of size 168 [ 29.995633] The buggy address is located 88 bytes inside of [ 29.995633] freed 168-byte region [ffff888010335658, ffff888010335700) [ 29.997189] [ 29.997421] The buggy address belongs to the physical page: [ 29.998133] page:00000000a10087e1 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x10335 [ 29.999295] memcg:ffff88800e03ef01 [ 29.999754] anon flags: 0x100000000000200(slab|node=0|zone=1) [ 30.000496] page_type: 0xffffffff() [ 30.000997] raw: 0100000000000200 ffff88800879fc80 0000000000000000 dead000000000001 [ 30.001981] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff88800e03ef01 [ 30.002945] page dumped because: kasan: bad access detected [ 30.003648] [ 30.003873] Memory state around the buggy address: [ 30.004491] ffff888010335580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 30.005426] ffff888010335600: fb fb fb fc fc fc fc fc fc fc fc fa fb fb fb fb [ 30.006350] >ffff888010335680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 30.007269] ^ [ 30.007895] ffff888010335700: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb [ 30.008826] ffff888010335780: fb fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc [ 30.009729] ================================================================== [ 30.010780] Disabling lock debugging due to kernel taint [ 32.783471] BUG: Bad rss-counter state mm:00000000bd915d13 type:MM_FILEPAGES val:33 [ 32.784507] BUG: Bad rss-counter state mm:00000000bd915d13 type:MM_ANONPAGES val:22 [ 33.304003] BUG: Bad rss-counter state mm:00000000afa07fec type:MM_FILEPAGES val:33 [ 33.305234] BUG: Bad rss-counter state mm:00000000afa07fec type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:2213' (ECDSA) to the list of known hosts. 2023/06/19 21:19:52 fuzzer started 2023/06/19 21:19:52 dialing manager at localhost:44161 2023/06/19 21:19:52 checking machine... 2023/06/19 21:19:52 checking revisions... [ 33.948006] kmemleak: Automatic memory scanning thread ended 2023/06/19 21:19:53 testing simple program... [ 33.991815] cgroup: Unknown subsys name 'net' [ 34.037114] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 21:19:51 Registers: info registers vcpu 0 RAX=ffffffff8460144a RBX=0000000000000002 RCX=ffff888016ce8000 RDX=ffff888016ce7b01 RSI=ffff888016ce7b00 RDI=ffff888016ce7b00 RBP=ffff88806ce09aa8 RSP=ffff88806ce099d8 R8 =0000000000000000 R9 =ffff88806ce09a90 R10=0000000000038001 R11=00000000000b523e R12=ffff88806ce09ab0 R13=ffff88806ce09a98 R14=ffff888016ce7b08 R15=ffff88806ce09a50 RIP=ffffffff8112fbf3 RFL=00000202 [-------] CPL=0 II=0 A20=1 SMM=0 HLT=0 ES =0000 0000000000000000 00000000 00000000 CS =0010 0000000000000000 ffffffff 00a09b00 DPL=0 CS64 [-RA] SS =0018 0000000000000000 ffffffff 00c09300 DPL=0 DS [-WA] DS =0000 0000000000000000 00000000 00000000 FS =0000 00007f4d79e29700 00000000 00000000 GS =0000 ffff88806ce00000 00000000 00000000 LDT=0000 fffffe0000000000 00000000 00000000 TR =0040 fffffe0000003000 00004087 00008b00 DPL=0 TSS64-busy GDT= fffffe0000001000 0000007f IDT= fffffe0000000000 00000fff CR0=80050033 CR2=00007f6784abb7c0 CR3=000000000e9a6000 CR4=00350ef0 DR0=0000000000000000 DR1=0000000000000000 DR2=0000000000000000 DR3=0000000000000000 DR6=00000000ffff0ff0 DR7=0000000000000400 EFER=0000000000000d01 FCW=037f FSW=0000 [ST=0] FTW=00 MXCSR=00001f80 FPR0=0000000000000000 0000 FPR1=0000000000000000 0000 FPR2=0000000000000000 0000 FPR3=0000000000000000 0000 FPR4=0000000000000000 0000 FPR5=0000000000000000 0000 FPR6=0000000000000000 0000 FPR7=0000000000000000 0000 XMM00=2032353a39313a3132203931206e754a XMM01=73732878696e755f6d6170203a5d3932 XMM02=65736f6c63206e6f6973736573203a29 XMM03=755f6d6170203a5d3932325b64687373 XMM04=69662068637573206f4e203a656c6163 XMM05=3a656c696620766e65206e65706f206f XMM06=65733a6468737328766e655f6d617020 XMM07=6b7a79732032353a39313a3132203931 XMM08=3d656e696c646d632022656369767265 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000 info registers vcpu 1 RAX=0000000000000000 RBX=ffff888008f92000 RCX=ffffffff812e0423 RDX=0000000000000000 RSI=0000000000000004 RDI=ffff8880196a9200 RBP=ffff8880196a9200 RSP=ffff888019cbfc98 R8 =0000000000000000 R9 =ffffed10032d5251 R10=ffff8880196a928b R11=00000000000b6996 R12=ffff8880196a93b8 R13=0000000000000020 R14=ffff8880196a9288 R15=ffff8880196a92d8 RIP=ffffffff818de4c2 RFL=00000286 [--S--P-] CPL=0 II=0 A20=1 SMM=0 HLT=0 ES =0000 0000000000000000 00000000 00000000 CS =0010 0000000000000000 ffffffff 00a09b00 DPL=0 CS64 [-RA] SS =0018 0000000000000000 ffffffff 00c09300 DPL=0 DS [-WA] DS =0000 0000000000000000 00000000 00000000 FS =0000 00007f121d110900 00000000 00000000 GS =0000 ffff88806cf00000 00000000 00000000 LDT=0000 fffffe0000000000 00000000 00000000 TR =0040 fffffe000004a000 00004087 00008b00 DPL=0 TSS64-busy GDT= fffffe0000048000 0000007f IDT= fffffe0000000000 00000fff CR0=80050033 CR2=00007ffffb045000 CR3=000000001a850000 CR4=00350ee0 DR0=0000000000000000 DR1=0000000000000000 DR2=0000000000000000 DR3=0000000000000000 DR6=00000000ffff0ff0 DR7=0000000000000400 EFER=0000000000000d01 FCW=037f FSW=0000 [ST=0] FTW=00 MXCSR=00001f80 FPR0=0000000000000000 0000 FPR1=0000000000000000 0000 FPR2=0000000000000000 0000 FPR3=0000000000000000 0000 FPR4=0000000000000000 0000 FPR5=0000000000000000 0000 FPR6=0000000000000000 0000 FPR7=0000000000000000 0000 XMM00=563412feff00545000000000000080fe XMM01=74696d7265705f6d61703d73726f746e XMM02=000000000000000000000000000000ff XMM03=5320444f4854454d5f54505952434e45 XMM04=40404040404040404040404040404040 XMM05=5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a XMM06=20202020202020202020202020202020 XMM07=00000000000000000000000000000000 XMM08=61662029286e65706f5f746964756100 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000