syzkaller login: [ 28.763487] BUG: Bad rss-counter state mm:0000000046b1ccb2 type:MM_FILEPAGES val:33 [ 28.764939] BUG: Bad rss-counter state mm:0000000046b1ccb2 type:MM_ANONPAGES val:22 [ 28.852156] ================================================================== [ 28.853252] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 28.854514] Read of size 8 at addr ffff8880147c4140 by task sshd/221 [ 28.855471] [ 28.855728] CPU: 1 PID: 221 Comm: sshd Not tainted 6.4.0-rc7-next-20230620 #1 [ 28.856774] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 28.857834] Call Trace: [ 28.858154] [ 28.858440] dump_stack_lvl+0x91/0xf0 [ 28.858930] print_report+0xcc/0x620 [ 28.859431] ? __virt_addr_valid+0x102/0x340 [ 28.859995] ? vma_interval_tree_remove+0xc75/0xec0 [ 28.860620] ? vma_interval_tree_remove+0xc75/0xec0 [ 28.861251] kasan_report+0xbe/0xf0 [ 28.861747] ? vma_interval_tree_remove+0xc75/0xec0 [ 28.862367] vma_interval_tree_remove+0xc75/0xec0 [ 28.862982] vma_prepare+0xc54/0x11a0 [ 28.863465] __split_vma+0x5af/0x950 [ 28.863944] ? __pfx___split_vma+0x10/0x10 [ 28.864480] ? find_held_lock+0x2c/0x110 [ 28.865007] do_vmi_align_munmap+0x2ba/0x11f0 [ 28.865598] ? lock_is_held_type+0x9f/0x120 [ 28.866143] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 28.866755] ? mtree_range_walk+0x632/0x900 [ 28.867315] ? mas_walk+0x5c7/0x7c0 [ 28.867799] do_vmi_munmap+0x1f1/0x2b0 [ 28.868312] mmap_region+0x1f9/0x2660 [ 28.868806] ? vm_mmap_pgoff+0x15c/0x3a0 [ 28.869322] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 28.870069] ? __pfx_lock_acquire+0x10/0x10 [ 28.870614] ? __pfx_mmap_region+0x10/0x10 [ 28.871151] ? security_mmap_addr+0x7d/0xa0 [ 28.871691] ? get_unmapped_area+0x1f5/0x3f0 [ 28.872240] do_mmap+0x854/0xf00 [ 28.872681] vm_mmap_pgoff+0x1a6/0x3a0 [ 28.873177] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 28.873768] ksys_mmap_pgoff+0x3af/0x500 [ 28.874285] do_syscall_64+0x3f/0x90 [ 28.874781] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 28.875444] RIP: 0033:0x7fe432338d82 [ 28.875915] 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 [ 28.878065] RSP: 002b:00007ffe89e025e8 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 28.878983] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007fe432338d82 [ 28.879849] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007fe431772000 [ 28.880700] RBP: 00007fe431772000 R08: 0000000000000009 R09: 0000000000001000 [ 28.881573] R10: 0000000000000812 R11: 0000000000000206 R12: 000055a8543b4b20 [ 28.882429] R13: 00007ffe89e02600 R14: 00007ffe89e02630 R15: 00007ffe89e02990 [ 28.883292] [ 28.883585] [ 28.883804] Allocated by task 214: [ 28.884241] kasan_save_stack+0x22/0x50 [ 28.884761] kasan_set_track+0x25/0x30 [ 28.885262] __kasan_slab_alloc+0x59/0x70 [ 28.885807] kmem_cache_alloc+0x16b/0x370 [ 28.886322] vm_area_dup+0x20/0x160 [ 28.886782] __split_vma+0x170/0x950 [ 28.887249] split_vma+0xc6/0x110 [ 28.887694] mprotect_fixup+0x8d2/0xb30 [ 28.888199] do_mprotect_pkey+0x87e/0xd40 [ 28.888723] __x64_sys_mprotect+0x78/0xc0 [ 28.889245] do_syscall_64+0x3f/0x90 [ 28.889737] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 28.890391] [ 28.890616] Freed by task 214: [ 28.891011] kasan_save_stack+0x22/0x50 [ 28.891533] kasan_set_track+0x25/0x30 [ 28.892038] kasan_save_free_info+0x2b/0x50 [ 28.892587] __kasan_slab_free+0x10a/0x190 [ 28.893126] kmem_cache_free+0x10d/0x4d0 [ 28.893670] rcu_core+0x8c8/0x2860 [ 28.894119] __do_softirq+0x1b7/0x7d4 [ 28.894602] [ 28.894827] Last potentially related work creation: [ 28.895414] kasan_save_stack+0x22/0x50 [ 28.895928] __kasan_record_aux_stack+0x8e/0xa0 [ 28.896562] __call_rcu_common.constprop.0+0x6a/0xb90 [ 28.897221] remove_vma+0x139/0x170 [ 28.897688] do_vmi_align_munmap+0xd4a/0x11f0 [ 28.898253] do_vmi_munmap+0x1f1/0x2b0 [ 28.898750] __vm_munmap+0x138/0x3a0 [ 28.899231] __x64_sys_munmap+0x59/0x80 [ 28.899755] do_syscall_64+0x3f/0x90 [ 28.900206] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 28.900825] [ 28.901029] The buggy address belongs to the object at ffff8880147c40e8 [ 28.901029] which belongs to the cache vm_area_struct of size 168 [ 28.902445] The buggy address is located 88 bytes inside of [ 28.902445] freed 168-byte region [ffff8880147c40e8, ffff8880147c4190) [ 28.903902] [ 28.904118] The buggy address belongs to the physical page: [ 28.904781] page:00000000e826c58e refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x147c4 [ 28.905899] memcg:ffff888019caf801 [ 28.906328] flags: 0x100000000000200(slab|node=0|zone=1) [ 28.906979] page_type: 0xffffffff() [ 28.907438] raw: 0100000000000200 ffff8880087a0c80 dead000000000122 0000000000000000 [ 28.908415] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff888019caf801 [ 28.909348] page dumped because: kasan: bad access detected [ 28.910050] [ 28.910268] Memory state around the buggy address: [ 28.910855] ffff8880147c4000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 28.911723] ffff8880147c4080: 00 00 00 00 00 fc fc fc fc fc fc fc fc fa fb fb [ 28.912594] >ffff8880147c4100: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.913465] ^ [ 28.914120] ffff8880147c4180: fb fb fc fc fc fc fc fc fc fc fa fb fb fb fb fb [ 28.915035] ffff8880147c4200: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fc [ 28.915901] ================================================================== [ 28.916871] Disabling lock debugging due to kernel taint [ 30.692977] BUG: Bad rss-counter state mm:000000005fa502d1 type:MM_FILEPAGES val:33 [ 30.694041] BUG: Bad rss-counter state mm:000000005fa502d1 type:MM_ANONPAGES val:22 [ 31.198435] BUG: Bad rss-counter state mm:0000000005528f89 type:MM_FILEPAGES val:33 [ 31.200195] BUG: Bad rss-counter state mm:0000000005528f89 type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:11865' (ECDSA) to the list of known hosts. 2023/06/20 23:04:13 fuzzer started 2023/06/20 23:04:13 dialing manager at localhost:36067 2023/06/20 23:04:13 checking machine... 2023/06/20 23:04:13 checking revisions... [ 31.927846] kmemleak: Automatic memory scanning thread ended 2023/06/20 23:04:14 testing simple program... [ 31.982762] cgroup: Unknown subsys name 'net' [ 32.030095] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 23:04:13 Registers: info registers vcpu 0 RAX=0000000019cf5bc7 RBX=000000002dfb155c RCX=ffff888008d9faac RDX=0000000000000007 RSI=0000000000000005 RDI=000000006ccfa908 RBP=0000000000000000 RSP=ffff888008d9fa20 R8 =00000000cffb2bfa R9 =ffff888008d9f990 R10=0000000000038001 R11=0000000000000128 R12=0000000000000000 R13=0000000000000000 R14=ffff888008d9fa88 R15=0000000000000007 RIP=ffffffff822704a9 RFL=00000206 [-----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 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=00007fd6cfbf8650 CR3=000000000ebee000 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=2033313a34303a3332203032206e754a XMM01=657463656e6e6f63736944203a5d3133 XMM02=302e303120746f6f722072657375206d XMM03=203a5d3133325b646873732072656c6c XMM04=69662068637573206f4e203a656c6163 XMM05=3a656c696620766e65206e65706f206f XMM06=65733a6468737328766e655f6d617020 XMM07=6b7a79732032313a34303a3332203032 XMM08=3d656e696c646d632022656369767265 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000 info registers vcpu 1 RAX=0000000000000000 RBX=0000000000000000 RCX=00007fb62c131320 RDX=00007fb62c130d4c RSI=00007ffd47fcb768 RDI=0000560f80e03330 RBP=00007ffd47fcb7e8 RSP=00007ffd47fcb788 R8 =0000000000000038 R9 =0000000000132d00 R10=0000000000000002 R11=00007fb62aa5de10 R12=00007fb62aa5cd00 R13=0000000000133cb0 R14=0000000000000006 R15=00007ffd47fcb770 RIP=00007fb62c0c242c RFL=00000206 [-----P-] CPL=3 II=0 A20=1 SMM=0 HLT=0 ES =0000 0000000000000000 00000000 00000000 CS =0033 0000000000000000 ffffffff 00a0fb00 DPL=3 CS64 [-RA] SS =002b 0000000000000000 ffffffff 00c0f300 DPL=3 DS [-WA] DS =0000 0000000000000000 00000000 00000000 FS =0000 00007fb62b53f900 00000000 00000000 GS =0000 0000000000000000 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=00007fb62a938450 CR3=000000000d602000 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=b3285ca56c489dff000000000010cf10 XMM01=b7ce8732947fe2ac064a84bb26f44564 XMM02=ec2efd57dc4c00df000000000011f9e0 XMM03=4167939713f33423000000000011fab0 XMM04=b073a89818a0c41100000000000ae988 XMM05=11b709d95db390fe00000000001330d0 XMM06=00c3ffa147b8d8570000000000132768 XMM07=e042d86d42eb936e0000000000122cc0 XMM08=4167939713f33423000000000011fab0 XMM09=00000000000000000000000000000000 XMM10=20200000000020202020202020200000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000