syzkaller login: [ 40.678916] BUG: Bad rss-counter state mm:000000009f3ae9fd type:MM_FILEPAGES val:33 [ 40.680137] BUG: Bad rss-counter state mm:000000009f3ae9fd type:MM_ANONPAGES val:22 [ 40.835110] ================================================================== [ 40.836237] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 40.837351] Read of size 8 at addr ffff88800e042798 by task sshd/219 [ 40.838307] [ 40.838518] CPU: 1 PID: 219 Comm: sshd Not tainted 6.4.0-rc7-next-20230619 #1 [ 40.839330] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 40.840248] Call Trace: [ 40.840551] [ 40.840821] dump_stack_lvl+0x91/0xf0 [ 40.841286] print_report+0xcc/0x620 [ 40.841744] ? __virt_addr_valid+0x102/0x340 [ 40.842261] ? vma_interval_tree_remove+0xc75/0xec0 [ 40.842850] ? vma_interval_tree_remove+0xc75/0xec0 [ 40.843441] kasan_report+0xbe/0xf0 [ 40.843891] ? vma_interval_tree_remove+0xc75/0xec0 [ 40.844478] vma_interval_tree_remove+0xc75/0xec0 [ 40.845053] vma_prepare+0xc54/0x11a0 [ 40.845506] __split_vma+0x5af/0x950 [ 40.845952] ? __pfx___split_vma+0x10/0x10 [ 40.846473] ? find_held_lock+0x2c/0x110 [ 40.846969] do_vmi_align_munmap+0x2ba/0x11f0 [ 40.847506] ? lock_is_held_type+0x9f/0x120 [ 40.848017] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 40.848590] ? mtree_range_walk+0x632/0x900 [ 40.849115] ? mas_walk+0x5c7/0x7c0 [ 40.849569] do_vmi_munmap+0x1f1/0x2b0 [ 40.850034] mmap_region+0x1f9/0x2660 [ 40.850567] ? vm_mmap_pgoff+0x15c/0x3a0 [ 40.851049] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 40.851723] ? __pfx_lock_acquire+0x10/0x10 [ 40.852222] ? __pfx_mmap_region+0x10/0x10 [ 40.852728] ? security_mmap_addr+0x7d/0xa0 [ 40.853229] ? get_unmapped_area+0x1f5/0x3f0 [ 40.853753] do_mmap+0x854/0xf00 [ 40.854168] vm_mmap_pgoff+0x1a6/0x3a0 [ 40.854648] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 40.855193] ksys_mmap_pgoff+0x3af/0x500 [ 40.855692] do_syscall_64+0x3f/0x90 [ 40.856158] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 40.856804] RIP: 0033:0x7f640dd0bd82 [ 40.857253] 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 [ 40.859378] RSP: 002b:00007ffd5708e6b8 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 40.860281] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007f640dd0bd82 [ 40.861120] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007f640d145000 [ 40.861961] RBP: 00007f640d145000 R08: 0000000000000009 R09: 0000000000001000 [ 40.862809] R10: 0000000000000812 R11: 0000000000000206 R12: 0000562a68c84ec0 [ 40.863658] R13: 00007ffd5708e6d0 R14: 00007ffd5708e700 R15: 00007ffd5708ea60 [ 40.864511] [ 40.864803] [ 40.865015] Allocated by task 212: [ 40.865439] kasan_save_stack+0x22/0x50 [ 40.865946] kasan_set_track+0x25/0x30 [ 40.866431] __kasan_slab_alloc+0x59/0x70 [ 40.866939] kmem_cache_alloc+0x16b/0x370 [ 40.867449] vm_area_dup+0x20/0x160 [ 40.867897] __split_vma+0x170/0x950 [ 40.868363] split_vma+0xc6/0x110 [ 40.868797] mprotect_fixup+0x8d2/0xb30 [ 40.869301] do_mprotect_pkey+0x87e/0xd40 [ 40.869813] __x64_sys_mprotect+0x78/0xc0 [ 40.870342] do_syscall_64+0x3f/0x90 [ 40.870811] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 40.871450] [ 40.871667] Freed by task 212: [ 40.872055] kasan_save_stack+0x22/0x50 [ 40.872556] kasan_set_track+0x25/0x30 [ 40.873047] kasan_save_free_info+0x2b/0x50 [ 40.873581] __kasan_slab_free+0x10a/0x190 [ 40.874107] kmem_cache_free+0x10d/0x4d0 [ 40.874623] rcu_core+0x8c8/0x2860 [ 40.875064] __do_softirq+0x1b7/0x7d4 [ 40.875545] [ 40.875762] Last potentially related work creation: [ 40.876340] kasan_save_stack+0x22/0x50 [ 40.876840] __kasan_record_aux_stack+0x8e/0xa0 [ 40.877405] __call_rcu_common.constprop.0+0x6a/0xb90 [ 40.878038] remove_vma+0x139/0x170 [ 40.878503] do_vmi_align_munmap+0xd4a/0x11f0 [ 40.879141] do_vmi_munmap+0x1f1/0x2b0 [ 40.879626] __vm_munmap+0x138/0x3a0 [ 40.880089] __x64_sys_munmap+0x59/0x80 [ 40.880572] do_syscall_64+0x3f/0x90 [ 40.881031] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 40.881673] [ 40.881885] Second to last potentially related work creation: [ 40.882578] kasan_save_stack+0x22/0x50 [ 40.883071] __kasan_record_aux_stack+0x8e/0xa0 [ 40.883629] __call_rcu_common.constprop.0+0x6a/0xb90 [ 40.884261] remove_vma+0x139/0x170 [ 40.884705] do_vmi_align_munmap+0xd4a/0x11f0 [ 40.885264] do_vmi_munmap+0x1f1/0x2b0 [ 40.885745] mmap_region+0x1f9/0x2660 [ 40.886229] do_mmap+0x854/0xf00 [ 40.886682] vm_mmap_pgoff+0x1a6/0x3a0 [ 40.887161] ksys_mmap_pgoff+0x3af/0x500 [ 40.887664] do_syscall_64+0x3f/0x90 [ 40.888125] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 40.888749] [ 40.888965] The buggy address belongs to the object at ffff88800e042740 [ 40.888965] which belongs to the cache vm_area_struct of size 168 [ 40.890436] The buggy address is located 88 bytes inside of [ 40.890436] freed 168-byte region [ffff88800e042740, ffff88800e0427e8) [ 40.891846] [ 40.892061] The buggy address belongs to the physical page: [ 40.892719] page:000000004a868ac7 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0xe042 [ 40.893794] memcg:ffff888013096b01 [ 40.894220] anon flags: 0x100000000000200(slab|node=0|zone=1) [ 40.894920] page_type: 0xffffffff() [ 40.895377] raw: 0100000000000200 ffff88800879fc80 0000000000000000 dead000000000001 [ 40.896290] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff888013096b01 [ 40.897190] page dumped because: kasan: bad access detected [ 40.897854] [ 40.898067] Memory state around the buggy address: [ 40.898654] ffff88800e042680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 40.899494] ffff88800e042700: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb [ 40.900337] >ffff88800e042780: fb fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc [ 40.901186] ^ [ 40.901682] ffff88800e042800: fc fc fc fc fc 00 00 00 00 00 00 00 00 00 00 00 [ 40.902546] ffff88800e042880: 00 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc [ 40.903388] ================================================================== [ 40.904386] Disabling lock debugging due to kernel taint [ 43.486583] BUG: Bad rss-counter state mm:00000000d39a0899 type:MM_FILEPAGES val:33 [ 43.487730] BUG: Bad rss-counter state mm:00000000d39a0899 type:MM_ANONPAGES val:22 [ 43.960221] BUG: Bad rss-counter state mm:00000000ce5ceba5 type:MM_FILEPAGES val:33 [ 43.961399] BUG: Bad rss-counter state mm:00000000ce5ceba5 type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:49901' (ECDSA) to the list of known hosts. 2023/06/20 01:59:25 fuzzer started 2023/06/20 01:59:25 dialing manager at localhost:44161 2023/06/20 01:59:25 checking machine... 2023/06/20 01:59:25 checking revisions... [ 44.798588] kmemleak: Automatic memory scanning thread ended 2023/06/20 01:59:25 testing simple program... [ 44.843866] cgroup: Unknown subsys name 'net' [ 44.882162] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 01:59:23 Registers: info registers vcpu 0 RAX=0000000000000000 RBX=00000000000361a0 RCX=1ffffffff0ba77d6 RDX=0000000000000000 RSI=ffffffff8182e0f2 RDI=ffffffff8560b640 RBP=ffff88801651c000 RSP=ffff88801ca87c68 R8 =0000000000000000 R9 =fffffbfff0f70c08 R10=0000000000000003 R11=00000000000b6996 R12=0000000000000005 R13=0000000000001458 R14=0000000000000000 R15=0000000000000000 RIP=ffffffff8182e106 RFL=00000093 [--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 00007fd710413900 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=00007fd7109ca618 CR3=000000000d632000 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=00000000000000000000000000000000 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=0000001c7bf5ac18 RBX=0000000000000000 RCX=00000000000006e0 RDX=000000000000001c RSI=ffff88806cf28140 RDI=0000000000053cb3 RBP=ffff88806cf28140 RSP=ffff88806cf09ee0 R8 =0000000000000007 R9 =0000000000000000 R10=00000000000efdc6 R11=0000000000000001 R12=0000000000053cb3 R13=0000000000000000 R14=0000000000000000 R15=ffff88806cf2b940 RIP=ffffffff811062a5 RFL=00000012 [----A--] 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=00007f999f45ef50 CR3=000000000ca0c000 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=09e01b7f37aecfbecc49604e9e9bef45 XMM02=ec2efd57dc4c00df000000000011cf40 XMM03=94b0687dc1428a75000000000011d010 XMM04=14144267c7949f2d00000000000ae988 XMM05=dfcdbad4f1609c370000000000134568 XMM06=d302532b70da76290000000000133740 XMM07=e042d86d42eb936e0000000000123bd0 XMM08=94b0687dc1428a75000000000011d010 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000