syzkaller login: [ 30.577917] BUG: Bad rss-counter state mm:00000000e44faa46 type:MM_FILEPAGES val:33 [ 30.579167] BUG: Bad rss-counter state mm:00000000e44faa46 type:MM_ANONPAGES val:22 [ 30.784116] ================================================================== [ 30.785116] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 30.786145] Read of size 8 at addr ffff888019ea2798 by task sshd/222 [ 30.787049] [ 30.787331] CPU: 1 PID: 222 Comm: sshd Not tainted 6.4.0-rc7-next-20230619 #1 [ 30.788287] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 30.789397] Call Trace: [ 30.789744] [ 30.790049] dump_stack_lvl+0x91/0xf0 [ 30.790586] print_report+0xcc/0x620 [ 30.791104] ? __virt_addr_valid+0x102/0x340 [ 30.791713] ? vma_interval_tree_remove+0xc75/0xec0 [ 30.792365] ? vma_interval_tree_remove+0xc75/0xec0 [ 30.793030] kasan_report+0xbe/0xf0 [ 30.793568] ? vma_interval_tree_remove+0xc75/0xec0 [ 30.794249] vma_interval_tree_remove+0xc75/0xec0 [ 30.794883] vma_prepare+0xc54/0x11a0 [ 30.795418] __split_vma+0x5af/0x950 [ 30.795913] ? __pfx___split_vma+0x10/0x10 [ 30.796489] ? find_held_lock+0x2c/0x110 [ 30.797044] do_vmi_align_munmap+0x2ba/0x11f0 [ 30.797668] ? lock_is_held_type+0x9f/0x120 [ 30.798252] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 30.798891] ? mtree_range_walk+0x632/0x900 [ 30.799507] ? mas_walk+0x5c7/0x7c0 [ 30.800006] do_vmi_munmap+0x1f1/0x2b0 [ 30.800537] mmap_region+0x1f9/0x2660 [ 30.801050] ? vm_mmap_pgoff+0x15c/0x3a0 [ 30.801615] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 30.802388] ? __pfx_lock_acquire+0x10/0x10 [ 30.802951] ? __pfx_mmap_region+0x10/0x10 [ 30.803542] ? security_mmap_addr+0x7d/0xa0 [ 30.804102] ? get_unmapped_area+0x1f5/0x3f0 [ 30.804694] do_mmap+0x854/0xf00 [ 30.805174] vm_mmap_pgoff+0x1a6/0x3a0 [ 30.805716] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 30.806329] ksys_mmap_pgoff+0x3af/0x500 [ 30.806868] do_syscall_64+0x3f/0x90 [ 30.807404] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 30.808083] RIP: 0033:0x7f26966dfd82 [ 30.808570] 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.810840] RSP: 002b:00007fff704f6c18 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 30.811823] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007f26966dfd82 [ 30.812731] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007f2695b19000 [ 30.813637] RBP: 00007f2695b19000 R08: 0000000000000009 R09: 0000000000001000 [ 30.814534] R10: 0000000000000812 R11: 0000000000000206 R12: 0000555c1bc6bf70 [ 30.815460] R13: 00007fff704f6c30 R14: 00007fff704f6c60 R15: 00007fff704f6fc0 [ 30.816374] [ 30.816682] [ 30.816909] Allocated by task 214: [ 30.817390] kasan_save_stack+0x22/0x50 [ 30.817922] kasan_set_track+0x25/0x30 [ 30.818453] __kasan_slab_alloc+0x59/0x70 [ 30.819008] kmem_cache_alloc+0x16b/0x370 [ 30.819600] vm_area_dup+0x20/0x160 [ 30.820071] __split_vma+0x170/0x950 [ 30.820612] split_vma+0xc6/0x110 [ 30.821216] mprotect_fixup+0x8d2/0xb30 [ 30.821906] do_mprotect_pkey+0x87e/0xd40 [ 30.822617] __x64_sys_mprotect+0x78/0xc0 [ 30.823347] do_syscall_64+0x3f/0x90 [ 30.823915] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 30.824640] [ 30.824865] Freed by task 214: [ 30.825298] kasan_save_stack+0x22/0x50 [ 30.825820] kasan_set_track+0x25/0x30 [ 30.826410] kasan_save_free_info+0x2b/0x50 [ 30.826967] __kasan_slab_free+0x10a/0x190 [ 30.827550] kmem_cache_free+0x10d/0x4d0 [ 30.828140] rcu_core+0x8c8/0x2860 [ 30.828599] __do_softirq+0x1b7/0x7d4 [ 30.829090] [ 30.829336] Last potentially related work creation: [ 30.829946] kasan_save_stack+0x22/0x50 [ 30.830481] __kasan_record_aux_stack+0x8e/0xa0 [ 30.831080] __call_rcu_common.constprop.0+0x6a/0xb90 [ 30.831779] remove_vma+0x139/0x170 [ 30.832257] do_vmi_align_munmap+0xd4a/0x11f0 [ 30.832829] do_vmi_munmap+0x1f1/0x2b0 [ 30.833349] __vm_munmap+0x138/0x3a0 [ 30.833836] __x64_sys_munmap+0x59/0x80 [ 30.834360] do_syscall_64+0x3f/0x90 [ 30.834846] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 30.835525] [ 30.835748] Second to last potentially related work creation: [ 30.836457] kasan_save_stack+0x22/0x50 [ 30.836974] __kasan_record_aux_stack+0x8e/0xa0 [ 30.837586] __call_rcu_common.constprop.0+0x6a/0xb90 [ 30.838260] remove_vma+0x139/0x170 [ 30.838721] do_vmi_align_munmap+0xd4a/0x11f0 [ 30.839327] do_vmi_munmap+0x1f1/0x2b0 [ 30.839836] mmap_region+0x1f9/0x2660 [ 30.840336] do_mmap+0x854/0xf00 [ 30.840787] vm_mmap_pgoff+0x1a6/0x3a0 [ 30.841319] ksys_mmap_pgoff+0x3af/0x500 [ 30.841831] do_syscall_64+0x3f/0x90 [ 30.842326] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 30.842983] [ 30.843228] The buggy address belongs to the object at ffff888019ea2740 [ 30.843228] which belongs to the cache vm_area_struct of size 168 [ 30.844801] The buggy address is located 88 bytes inside of [ 30.844801] freed 168-byte region [ffff888019ea2740, ffff888019ea27e8) [ 30.846304] [ 30.846529] The buggy address belongs to the physical page: [ 30.847225] page:000000000745f760 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x19ea2 [ 30.848379] memcg:ffff88800a37f901 [ 30.848817] flags: 0x100000000000200(slab|node=0|zone=1) [ 30.849512] page_type: 0xffffffff() [ 30.849979] raw: 0100000000000200 ffff88800879fc80 ffffea00003ad3c0 dead000000000008 [ 30.850920] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff88800a37f901 [ 30.851871] page dumped because: kasan: bad access detected [ 30.852561] [ 30.852780] Memory state around the buggy address: [ 30.853379] ffff888019ea2680: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 30.854262] ffff888019ea2700: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb [ 30.855144] >ffff888019ea2780: fb fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc [ 30.856015] ^ [ 30.856538] ffff888019ea2800: fc fc fc fc fc 00 00 00 00 00 00 00 00 00 00 00 [ 30.857513] ffff888019ea2880: 00 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc [ 30.858513] ================================================================== [ 30.859794] Disabling lock debugging due to kernel taint [ 32.911683] BUG: Bad rss-counter state mm:00000000e6580e0a type:MM_FILEPAGES val:33 [ 32.912820] BUG: Bad rss-counter state mm:00000000e6580e0a type:MM_ANONPAGES val:22 [ 33.396929] BUG: Bad rss-counter state mm:00000000d31b27dd type:MM_FILEPAGES val:33 [ 33.398105] BUG: Bad rss-counter state mm:00000000d31b27dd type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:29989' (ECDSA) to the list of known hosts. 2023/06/20 05:46:31 fuzzer started 2023/06/20 05:46:32 dialing manager at localhost:44161 2023/06/20 05:46:32 checking machine... 2023/06/20 05:46:32 checking revisions... [ 34.105611] kmemleak: Automatic memory scanning thread ended 2023/06/20 05:46:32 testing simple program... [ 34.157891] cgroup: Unknown subsys name 'net' [ 34.219046] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 05:46:30 Registers: info registers vcpu 0 RAX=0000000000000003 RBX=ffff88800c954000 RCX=1ffffffff0ba7a02 RDX=0000000000000000 RSI=00000000000001d0 RDI=ffffffff81371069 RBP=ffff88806ce09e38 RSP=ffff88806ce09e10 R8 =0000000000000000 R9 =0000000000000000 R10=ffffffff85d3bed7 R11=00000000000b6996 R12=ffff8880087b6780 R13=ffffea0000325500 R14=ffffffff8186b9c5 R15=ffff88800ca22800 RIP=ffffffff81809916 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 00007f4451df9900 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=00007f445131a000 CR3=000000000d7b0000 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=e99101ed2ffacb93a14ff16f823faa57 XMM02=ec2efd57dc4c00df000000000011c0e8 XMM03=0ed51afa127913d4000000000011c1b8 XMM04=e6fcb0060f6b3ab400000000000ae988 XMM05=3e7d6f66b17391160000000000135dd8 XMM06=00c3ffa147b8d8570000000000134bc8 XMM07=fb795ef6d65770560000000000123678 XMM08=2c67c8bc2e329bc3000000000011c158 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000 info registers vcpu 1 RAX=dffffc0000000000 RBX=ffff888008e57958 RCX=ffff888008e579f8 RDX=1ffff110011caf36 RSI=ffff888008e579f0 RDI=ffff888008e57958 RBP=ffff888008e579b0 RSP=ffff888008e57940 R8 =0000000000000001 R9 =ffff888008e57998 R10=0000000000038001 R11=0000000000003c0d R12=ffff888008e57a20 R13=0000000000000000 R14=ffff888008e2d1c0 R15=ffff88800ca22800 RIP=ffffffff8113038e RFL=00000246 [---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=00007fe2d600a0b0 CR3=00000000165aa000 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=36343a3530203032206e754a3e36383c XMM01=7365733a646873732878696e755f6d61 XMM02=736f6c63206e6f6973736573203a296e XMM03=5f6d6170203a5d3133325b6468737320 XMM04=6456774875434142334f726f59427469 XMM05=485320415352203a3268737320303437 XMM06=206d6f726620746f6f7220726f662079 XMM07=00000000000000000000000000000000 XMM08=3a677562656420676f6c737973720000 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000