syzkaller login: [ 30.727411] BUG: Bad rss-counter state mm:00000000dd201309 type:MM_FILEPAGES val:33 [ 30.728744] BUG: Bad rss-counter state mm:00000000dd201309 type:MM_ANONPAGES val:22 [ 30.778635] ================================================================== [ 30.779701] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 30.780825] Read of size 8 at addr ffff88801a757058 by task sshd/220 [ 30.781736] [ 30.781999] CPU: 0 PID: 220 Comm: sshd Not tainted 6.4.0-rc7-next-20230620 #1 [ 30.783022] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 30.784180] Call Trace: [ 30.784558] [ 30.784890] dump_stack_lvl+0x91/0xf0 [ 30.785481] print_report+0xcc/0x620 [ 30.786045] ? __virt_addr_valid+0x102/0x340 [ 30.786698] ? vma_interval_tree_remove+0xc75/0xec0 [ 30.787427] ? vma_interval_tree_remove+0xc75/0xec0 [ 30.788165] kasan_report+0xbe/0xf0 [ 30.788740] ? vma_interval_tree_remove+0xc75/0xec0 [ 30.789521] vma_interval_tree_remove+0xc75/0xec0 [ 30.790119] vma_prepare+0xc54/0x11a0 [ 30.790593] __split_vma+0x5af/0x950 [ 30.791067] ? __pfx___split_vma+0x10/0x10 [ 30.791590] ? find_held_lock+0x2c/0x110 [ 30.792106] do_vmi_align_munmap+0x2ba/0x11f0 [ 30.792669] ? lock_is_held_type+0x9f/0x120 [ 30.793213] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 30.793815] ? mtree_range_walk+0x632/0x900 [ 30.794375] ? mas_walk+0x5c7/0x7c0 [ 30.794844] do_vmi_munmap+0x1f1/0x2b0 [ 30.795332] mmap_region+0x1f9/0x2660 [ 30.795814] ? vm_mmap_pgoff+0x15c/0x3a0 [ 30.796344] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 30.797093] ? __pfx_lock_acquire+0x10/0x10 [ 30.797649] ? __pfx_mmap_region+0x10/0x10 [ 30.798195] ? security_mmap_addr+0x7d/0xa0 [ 30.798744] ? get_unmapped_area+0x1f5/0x3f0 [ 30.799305] do_mmap+0x854/0xf00 [ 30.799759] vm_mmap_pgoff+0x1a6/0x3a0 [ 30.800269] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 30.800861] ksys_mmap_pgoff+0x3af/0x500 [ 30.801407] do_syscall_64+0x3f/0x90 [ 30.801904] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 30.802579] RIP: 0033:0x7f602e2bfd82 [ 30.803048] 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 [ 30.805253] RSP: 002b:00007ffedc761888 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 30.806187] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007f602e2bfd82 [ 30.807064] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007f602d6f9000 [ 30.807940] RBP: 00007f602d6f9000 R08: 0000000000000009 R09: 0000000000001000 [ 30.808812] R10: 0000000000000812 R11: 0000000000000206 R12: 0000565094784ec0 [ 30.809733] R13: 00007ffedc7618a0 R14: 00007ffedc7618d0 R15: 00007ffedc761c30 [ 30.810624] [ 30.810923] [ 30.811145] Allocated by task 213: [ 30.811590] kasan_save_stack+0x22/0x50 [ 30.812113] kasan_set_track+0x25/0x30 [ 30.812632] __kasan_slab_alloc+0x59/0x70 [ 30.813183] kmem_cache_alloc+0x16b/0x370 [ 30.813724] vm_area_dup+0x20/0x160 [ 30.814192] __split_vma+0x170/0x950 [ 30.814674] split_vma+0xc6/0x110 [ 30.815133] mprotect_fixup+0x8d2/0xb30 [ 30.815652] do_mprotect_pkey+0x87e/0xd40 [ 30.816195] __x64_sys_mprotect+0x78/0xc0 [ 30.816730] do_syscall_64+0x3f/0x90 [ 30.817228] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 30.817891] [ 30.818114] Freed by task 213: [ 30.818519] kasan_save_stack+0x22/0x50 [ 30.819036] kasan_set_track+0x25/0x30 [ 30.819546] kasan_save_free_info+0x2b/0x50 [ 30.820102] __kasan_slab_free+0x10a/0x190 [ 30.820652] kmem_cache_free+0x10d/0x4d0 [ 30.821193] rcu_core+0x8c8/0x2860 [ 30.821652] __do_softirq+0x1b7/0x7d4 [ 30.822148] [ 30.822367] Last potentially related work creation: [ 30.822977] kasan_save_stack+0x22/0x50 [ 30.823490] __kasan_record_aux_stack+0x8e/0xa0 [ 30.824087] __call_rcu_common.constprop.0+0x6a/0xb90 [ 30.824748] remove_vma+0x139/0x170 [ 30.825224] do_vmi_align_munmap+0xd4a/0x11f0 [ 30.825799] do_vmi_munmap+0x1f1/0x2b0 [ 30.826304] __vm_munmap+0x138/0x3a0 [ 30.826781] __x64_sys_munmap+0x59/0x80 [ 30.827291] do_syscall_64+0x3f/0x90 [ 30.827784] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 30.828448] [ 30.828668] The buggy address belongs to the object at ffff88801a757000 [ 30.828668] which belongs to the cache vm_area_struct of size 168 [ 30.830207] The buggy address is located 88 bytes inside of [ 30.830207] freed 168-byte region [ffff88801a757000, ffff88801a7570a8) [ 30.831659] [ 30.831882] The buggy address belongs to the physical page: [ 30.832561] page:000000000a8a5587 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1a757 [ 30.833698] memcg:ffff88801a6dc501 [ 30.834142] flags: 0x100000000000200(slab|node=0|zone=1) [ 30.834809] page_type: 0xffffffff() [ 30.835276] raw: 0100000000000200 ffff8880087a0c80 dead000000000122 0000000000000000 [ 30.836234] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff88801a6dc501 [ 30.837185] page dumped because: kasan: bad access detected [ 30.837869] [ 30.838091] Memory state around the buggy address: [ 30.838687] ffff88801a756f00: 00 00 00 00 00 00 fc fc fc fc fc fc fc fc fc fc [ 30.839577] ffff88801a756f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 30.840467] >ffff88801a757000: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 30.841363] ^ [ 30.842113] ffff88801a757080: fb fb fb fb fb fc fc fc fc fc fc fc fc fa fb fb [ 30.843000] ffff88801a757100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 30.843882] ================================================================== [ 30.845130] Disabling lock debugging due to kernel taint [ 32.720886] BUG: Bad rss-counter state mm:00000000a0dd79e2 type:MM_FILEPAGES val:33 [ 32.721643] BUG: Bad rss-counter state mm:00000000a0dd79e2 type:MM_ANONPAGES val:22 [ 33.202494] BUG: Bad rss-counter state mm:00000000d82a8a52 type:MM_FILEPAGES val:33 [ 33.203659] BUG: Bad rss-counter state mm:00000000d82a8a52 type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:26573' (ECDSA) to the list of known hosts. 2023/06/20 19:01:48 fuzzer started 2023/06/20 19:01:48 dialing manager at localhost:36067 2023/06/20 19:01:48 checking machine... 2023/06/20 19:01:48 checking revisions... [ 33.946973] kmemleak: Automatic memory scanning thread ended 2023/06/20 19:01:48 testing simple program... [ 33.994692] cgroup: Unknown subsys name 'net' [ 34.033636] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 19:01:48 Registers: info registers vcpu 0 RAX=0000000000000000 RBX=0000000000000000 RCX=0000000000000000 RDX=ffff888015a33680 RSI=ffff88800f06f0c0 RDI=ffff88800cc60c80 RBP=ffff88800cc60c80 RSP=ffff88801a557ed0 R8 =0000000000000003 R9 =0000000000004000 R10=000000000000c000 R11=0000000000000000 R12=ffff88800f06f0c0 R13=0000000000000000 R14=0000000000000000 R15=0000000000000000 RIP=ffffffff819cdb96 RFL=00000293 [--S-A-C] 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 00007fc71b9fd900 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=00007fc71bfb4618 CR3=00000000103cc000 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=563412feff00545000000000000080fe XMM01=6e69676f6c5f6d61702c78756e696c65 XMM02=755f6d61702c74696d7265705f6d6170 XMM03=2c766e655f6d61702c7374696d696c5f XMM04=6d61702c766e655f6d61702c7374696d XMM05=78696e755f6d61702c74696d7265705f XMM06=6469756e69676f6c5f6d61702c78756e XMM07=672065736f6c635f6e6f69737365733a XMM08=61662029286e65706f5f746964756100 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000 info registers vcpu 1 RAX=0000000000000000 RBX=0000000000000002 RCX=0000000000000000 RDX=ffff888008d69b40 RSI=ffffffff844f8515 RDI=0000000000000007 RBP=ffff888008d7f0d8 RSP=ffff888008d7f038 R8 =0000000000000007 R9 =0000000000000002 R10=0000000000000002 R11=0000000000009293 R12=ffff88801b8b0842 R13=dffffc0000000000 R14=0000000000000000 R15=0000000000000006 RIP=ffffffff814c089b RFL=00000046 [---Z-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 0000000000000000 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=00007fc71b993000 CR3=00000000103cc000 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=00000000000000000000000000000000 XMM01=000000000000003600000000000efa5c XMM02=00000000000000000000000000000000 XMM03=000000000000003600000000000dfb68 XMM04=000000000000003600000000000efa77 XMM05=00000000000000000000000000000000 XMM06=000000000000003600000000000dfb88 XMM07=00000000000000000000000000000000 XMM08=01000000000000000000000000000001 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000