syzkaller login: [ 31.198155] BUG: Bad rss-counter state mm:00000000489ec161 type:MM_FILEPAGES val:33 [ 31.198982] BUG: Bad rss-counter state mm:00000000489ec161 type:MM_ANONPAGES val:22 [ 31.328429] ================================================================== [ 31.329108] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 31.329834] Read of size 8 at addr ffff8880168aeb38 by task sshd/220 [ 31.330426] [ 31.330588] CPU: 1 PID: 220 Comm: sshd Not tainted 6.4.0-rc7-next-20230619 #1 [ 31.331161] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 31.332081] Call Trace: [ 31.332330] [ 31.332519] dump_stack_lvl+0x91/0xf0 [ 31.332870] print_report+0xcc/0x620 [ 31.333221] ? __virt_addr_valid+0x102/0x340 [ 31.333600] ? vma_interval_tree_remove+0xc75/0xec0 [ 31.334006] ? vma_interval_tree_remove+0xc75/0xec0 [ 31.334467] kasan_report+0xbe/0xf0 [ 31.334801] ? vma_interval_tree_remove+0xc75/0xec0 [ 31.335234] vma_interval_tree_remove+0xc75/0xec0 [ 31.335706] vma_prepare+0xc54/0x11a0 [ 31.336050] __split_vma+0x5af/0x950 [ 31.336362] ? __pfx___split_vma+0x10/0x10 [ 31.336719] ? find_held_lock+0x2c/0x110 [ 31.337077] do_vmi_align_munmap+0x2ba/0x11f0 [ 31.337460] ? lock_is_held_type+0x9f/0x120 [ 31.337832] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 31.338271] ? mtree_range_walk+0x632/0x900 [ 31.338660] ? mas_walk+0x5c7/0x7c0 [ 31.338985] do_vmi_munmap+0x1f1/0x2b0 [ 31.339389] mmap_region+0x1f9/0x2660 [ 31.339739] ? vm_mmap_pgoff+0x15c/0x3a0 [ 31.340093] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 31.340600] ? __pfx_lock_acquire+0x10/0x10 [ 31.340967] ? __pfx_mmap_region+0x10/0x10 [ 31.341330] ? security_mmap_addr+0x7d/0xa0 [ 31.341686] ? get_unmapped_area+0x1f5/0x3f0 [ 31.342037] do_mmap+0x854/0xf00 [ 31.342324] vm_mmap_pgoff+0x1a6/0x3a0 [ 31.342655] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 31.343032] ksys_mmap_pgoff+0x3af/0x500 [ 31.343395] do_syscall_64+0x3f/0x90 [ 31.343703] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 31.344148] RIP: 0033:0x7fb22de53d82 [ 31.344472] 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 [ 31.345918] RSP: 002b:00007ffd4761e728 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 31.346552] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007fb22de53d82 [ 31.347118] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007fb22d28d000 [ 31.347713] RBP: 00007fb22d28d000 R08: 0000000000000009 R09: 0000000000001000 [ 31.348300] R10: 0000000000000812 R11: 0000000000000206 R12: 0000557b3b474ec0 [ 31.348904] R13: 00007ffd4761e740 R14: 00007ffd4761e770 R15: 00007ffd4761ead0 [ 31.349486] [ 31.349689] [ 31.349833] Allocated by task 213: [ 31.350115] kasan_save_stack+0x22/0x50 [ 31.350453] kasan_set_track+0x25/0x30 [ 31.350767] __kasan_slab_alloc+0x59/0x70 [ 31.351116] kmem_cache_alloc+0x16b/0x370 [ 31.351521] vm_area_dup+0x20/0x160 [ 31.351835] __split_vma+0x170/0x950 [ 31.352164] split_vma+0xc6/0x110 [ 31.352445] mprotect_fixup+0x8d2/0xb30 [ 31.352760] do_mprotect_pkey+0x87e/0xd40 [ 31.353090] __x64_sys_mprotect+0x78/0xc0 [ 31.353427] do_syscall_64+0x3f/0x90 [ 31.353739] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 31.354167] [ 31.354309] Freed by task 19: [ 31.354557] kasan_save_stack+0x22/0x50 [ 31.354895] kasan_set_track+0x25/0x30 [ 31.355238] kasan_save_free_info+0x2b/0x50 [ 31.356590] __kasan_slab_free+0x10a/0x190 [ 31.356958] kmem_cache_free+0x10d/0x4d0 [ 31.357293] rcu_core+0x8c8/0x2860 [ 31.357586] __do_softirq+0x1b7/0x7d4 [ 31.357933] [ 31.358079] Last potentially related work creation: [ 31.358489] kasan_save_stack+0x22/0x50 [ 31.358841] __kasan_record_aux_stack+0x8e/0xa0 [ 31.359236] __call_rcu_common.constprop.0+0x6a/0xb90 [ 31.359710] remove_vma+0x139/0x170 [ 31.360006] do_vmi_align_munmap+0xd4a/0x11f0 [ 31.360368] do_vmi_munmap+0x1f1/0x2b0 [ 31.360680] __vm_munmap+0x138/0x3a0 [ 31.360984] __x64_sys_munmap+0x59/0x80 [ 31.361322] do_syscall_64+0x3f/0x90 [ 31.361656] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 31.362091] [ 31.362243] The buggy address belongs to the object at ffff8880168aeae0 [ 31.362243] which belongs to the cache vm_area_struct of size 168 [ 31.363250] The buggy address is located 88 bytes inside of [ 31.363250] freed 168-byte region [ffff8880168aeae0, ffff8880168aeb88) [ 31.364257] [ 31.364414] The buggy address belongs to the physical page: [ 31.364881] page:0000000048d45f57 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x168ae [ 31.365642] memcg:ffff8880168af001 [ 31.365981] anon flags: 0x100000000000200(slab|node=0|zone=1) [ 31.366457] page_type: 0xffffffff() [ 31.366765] raw: 0100000000000200 ffff88800879fc80 ffffea0000602980 dead000000000003 [ 31.367451] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff8880168af001 [ 31.368103] page dumped because: kasan: bad access detected [ 31.368567] [ 31.368717] Memory state around the buggy address: [ 31.369118] ffff8880168aea00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 31.369757] ffff8880168aea80: fb fb fb fb fc fc fc fc fc fc fc fc fa fb fb fb [ 31.370359] >ffff8880168aeb00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 31.370939] ^ [ 31.371389] ffff8880168aeb80: fb fc fc fc fc fc fc fc fc 00 00 00 00 00 00 00 [ 31.371984] ffff8880168aec00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc fc [ 31.372581] ================================================================== [ 31.373331] Disabling lock debugging due to kernel taint [ 33.112733] BUG: Bad rss-counter state mm:00000000fcdf3bd7 type:MM_FILEPAGES val:33 [ 33.113470] BUG: Bad rss-counter state mm:00000000fcdf3bd7 type:MM_ANONPAGES val:22 [ 33.507243] BUG: Bad rss-counter state mm:00000000fbc9f8c4 type:MM_FILEPAGES val:33 [ 33.507932] BUG: Bad rss-counter state mm:00000000fbc9f8c4 type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:11398' (ECDSA) to the list of known hosts. 2023/06/20 08:52:58 fuzzer started 2023/06/20 08:52:58 dialing manager at localhost:44161 2023/06/20 08:52:58 checking machine... 2023/06/20 08:52:58 checking revisions... [ 34.121694] kmemleak: Automatic memory scanning thread ended 2023/06/20 08:52:58 testing simple program... [ 34.155790] cgroup: Unknown subsys name 'net' [ 34.217695] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 08:52:57 Registers: info registers vcpu 0 RAX=ffff88801681a600 RBX=ffff88800eb5f8b8 RCX=1ffff11001fc7a60 RDX=dffffc0000000000 RSI=ffff88801687e000 RDI=ffff88800eb5f8e8 RBP=ffff88800fe3d2d0 RSP=ffff88801d07f638 R8 =0000000000000001 R9 =0000000000000246 R10=0000000000000003 R11=00000000000b6996 R12=ffff88801687c000 R13=0000000000000000 R14=ffff88800eb0ac28 R15=ffff88800eb0abe0 RIP=ffffffff81847508 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 00007fca56e2e900 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=00007fca573e5618 CR3=000000000d970000 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=2037353a32353a3830203032206e754a XMM01=73732878696e755f6d6170203a5d3932 XMM02=65736f6c63206e6f6973736573203a29 XMM03=755f6d6170203a5d3932325b64687373 XMM04=69662068637573206f4e203a656c6163 XMM05=3a656c696620766e65206e65706f206f XMM06=65733a6468737328766e655f6d617020 XMM07=6b7a79732037353a32353a3830203032 XMM08=3d656e696c646d632022656369767265 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000 info registers vcpu 1 RAX=ffff88806cf35000 RBX=0000000000000001 RCX=ffffffff8450c50e RDX=ffffed100d9e6a01 RSI=0000000000000004 RDI=ffffffff812889a5 RBP=dffffc0000000000 RSP=ffff888008e27e70 R8 =0000000000000000 R9 =ffffed100d9e6a00 R10=ffff88806cf35003 R11=0000000000000001 R12=ffffffff85d3bed0 R13=1ffff110011c4fd3 R14=0000000000000000 R15=0000000000000000 RIP=ffffffff8450d49f RFL=00000246 [---Z-P-] CPL=0 II=0 A20=1 SMM=0 HLT=1 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=00007fde18e6f0d0 CR3=000000000cba6000 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=6ec478ab3a97e3a4744c2e6c106b1655 XMM02=000000000011c458eff9b2d0a8fce9cb XMM03=000000000011c5282c67c8bc2e329bc3 XMM04=2b65d1f01296557100000000000ae988 XMM05=19e9129bd510f2350000000000133540 XMM06=7e3b6417b3b01c5200000000001323a8 XMM07=e042d86d42eb936e0000000000123cc0 XMM08=004d1aefe3a69fd1000000000011c528 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000