syzkaller login: [ 39.000485] BUG: Bad rss-counter state mm:000000004ec27f4d type:MM_FILEPAGES val:33 [ 39.001803] BUG: Bad rss-counter state mm:000000004ec27f4d type:MM_ANONPAGES val:22 [ 39.040025] ================================================================== [ 39.040967] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 39.041919] Read of size 8 at addr ffff888019e15b38 by task sshd/219 [ 39.042705] [ 39.042927] CPU: 1 PID: 219 Comm: sshd Not tainted 6.4.0-rc7-next-20230619 #1 [ 39.043795] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 39.044917] Call Trace: [ 39.045293] [ 39.045583] dump_stack_lvl+0x91/0xf0 [ 39.046074] print_report+0xcc/0x620 [ 39.046682] ? __virt_addr_valid+0x102/0x340 [ 39.047390] ? vma_interval_tree_remove+0xc75/0xec0 [ 39.048072] ? vma_interval_tree_remove+0xc75/0xec0 [ 39.048823] kasan_report+0xbe/0xf0 [ 39.049302] ? vma_interval_tree_remove+0xc75/0xec0 [ 39.050059] vma_interval_tree_remove+0xc75/0xec0 [ 39.050795] vma_prepare+0xc54/0x11a0 [ 39.051440] __split_vma+0x5af/0x950 [ 39.051926] ? __pfx___split_vma+0x10/0x10 [ 39.052464] ? find_held_lock+0x2c/0x110 [ 39.052991] do_vmi_align_munmap+0x2ba/0x11f0 [ 39.053560] ? lock_is_held_type+0x9f/0x120 [ 39.054099] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 39.054711] ? mtree_range_walk+0x632/0x900 [ 39.055278] ? mas_walk+0x5c7/0x7c0 [ 39.055761] do_vmi_munmap+0x1f1/0x2b0 [ 39.056288] mmap_region+0x1f9/0x2660 [ 39.056784] ? vm_mmap_pgoff+0x15c/0x3a0 [ 39.057304] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 39.058034] ? __pfx_lock_acquire+0x10/0x10 [ 39.058570] ? __pfx_mmap_region+0x10/0x10 [ 39.059106] ? security_mmap_addr+0x7d/0xa0 [ 39.059644] ? get_unmapped_area+0x1f5/0x3f0 [ 39.060209] do_mmap+0x854/0xf00 [ 39.060651] vm_mmap_pgoff+0x1a6/0x3a0 [ 39.061148] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 39.061722] ksys_mmap_pgoff+0x3af/0x500 [ 39.062241] do_syscall_64+0x3f/0x90 [ 39.062729] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 39.063394] RIP: 0033:0x7fe6b50b8d82 [ 39.063868] 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 [ 39.066175] RSP: 002b:00007fffa9542308 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 39.067153] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007fe6b50b8d82 [ 39.068039] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007fe6b44f2000 [ 39.068935] RBP: 00007fe6b44f2000 R08: 0000000000000009 R09: 0000000000001000 [ 39.069795] R10: 0000000000000812 R11: 0000000000000206 R12: 000055b02d21fec0 [ 39.070667] R13: 00007fffa9542320 R14: 00007fffa9542350 R15: 00007fffa95426b0 [ 39.071527] [ 39.071834] [ 39.072050] Allocated by task 212: [ 39.072477] kasan_save_stack+0x22/0x50 [ 39.072998] kasan_set_track+0x25/0x30 [ 39.073503] __kasan_slab_alloc+0x59/0x70 [ 39.074037] kmem_cache_alloc+0x16b/0x370 [ 39.074567] vm_area_dup+0x20/0x160 [ 39.075026] __split_vma+0x170/0x950 [ 39.075492] split_vma+0xc6/0x110 [ 39.075949] mprotect_fixup+0x8d2/0xb30 [ 39.076455] do_mprotect_pkey+0x87e/0xd40 [ 39.076981] __x64_sys_mprotect+0x78/0xc0 [ 39.077501] do_syscall_64+0x3f/0x90 [ 39.077977] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 39.078621] [ 39.078839] Freed by task 212: [ 39.079238] kasan_save_stack+0x22/0x50 [ 39.079740] kasan_set_track+0x25/0x30 [ 39.080247] kasan_save_free_info+0x2b/0x50 [ 39.080783] __kasan_slab_free+0x10a/0x190 [ 39.081342] kmem_cache_free+0x10d/0x4d0 [ 39.081857] rcu_core+0x8c8/0x2860 [ 39.082308] __do_softirq+0x1b7/0x7d4 [ 39.082784] [ 39.083000] Last potentially related work creation: [ 39.083599] kasan_save_stack+0x22/0x50 [ 39.084142] __kasan_record_aux_stack+0x8e/0xa0 [ 39.084724] __call_rcu_common.constprop.0+0x6a/0xb90 [ 39.085380] remove_vma+0x139/0x170 [ 39.085828] do_vmi_align_munmap+0xd4a/0x11f0 [ 39.086405] do_vmi_munmap+0x1f1/0x2b0 [ 39.086896] __vm_munmap+0x138/0x3a0 [ 39.087365] __x64_sys_munmap+0x59/0x80 [ 39.087883] do_syscall_64+0x3f/0x90 [ 39.088363] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 39.089007] [ 39.089223] The buggy address belongs to the object at ffff888019e15ae0 [ 39.089223] which belongs to the cache vm_area_struct of size 168 [ 39.090697] The buggy address is located 88 bytes inside of [ 39.090697] freed 168-byte region [ffff888019e15ae0, ffff888019e15b88) [ 39.092125] [ 39.092342] The buggy address belongs to the physical page: [ 39.093003] page:00000000290796a1 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x19e15 [ 39.094089] memcg:ffff88800de5b501 [ 39.094514] flags: 0x100000000000200(slab|node=0|zone=1) [ 39.095162] page_type: 0xffffffff() [ 39.095615] raw: 0100000000000200 ffff88800879fc80 dead000000000122 0000000000000000 [ 39.096548] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff88800de5b501 [ 39.097460] page dumped because: kasan: bad access detected [ 39.098132] [ 39.098351] Memory state around the buggy address: [ 39.098933] ffff888019e15a00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 39.099792] ffff888019e15a80: 00 00 00 00 fc fc fc fc fc fc fc fc fa fb fb fb [ 39.100653] >ffff888019e15b00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 39.101503] ^ [ 39.102115] ffff888019e15b80: fb fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb [ 39.102968] ffff888019e15c00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fc fc [ 39.103852] ================================================================== [ 39.104868] Disabling lock debugging due to kernel taint [ 41.382738] BUG: Bad rss-counter state mm:00000000100de74c type:MM_FILEPAGES val:33 [ 41.383907] BUG: Bad rss-counter state mm:00000000100de74c type:MM_ANONPAGES val:22 [ 41.816585] BUG: Bad rss-counter state mm:000000006c7d8e05 type:MM_FILEPAGES val:33 [ 41.817792] BUG: Bad rss-counter state mm:000000006c7d8e05 type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:14770' (ECDSA) to the list of known hosts. 2023/06/19 15:54:46 fuzzer started 2023/06/19 15:54:46 dialing manager at localhost:44161 2023/06/19 15:54:46 checking machine... 2023/06/19 15:54:46 checking revisions... [ 42.555725] kmemleak: Automatic memory scanning thread ended 2023/06/19 15:54:46 testing simple program... [ 42.619902] cgroup: Unknown subsys name 'net' [ 42.653610] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 15:54:38 Registers: info registers vcpu 0 RAX=0000000000020f00 RBX=0000000000000002 RCX=ffffffff8180f43a RDX=0000000000000010 RSI=ffffffff86137dcc RDI=ffffffff85dfcfd4 RBP=ffff88806ce09af0 RSP=ffff88806ce09a18 R8 =ffffffff86137dcc R9 =ffff88806ce09ad8 R10=0000000000038001 R11=0000000000020f00 R12=ffff88806ce09af8 R13=ffff88806ce09ae0 R14=ffff88806ce09ad9 R15=ffff88806ce09a98 RIP=ffffffff8112fc12 RFL=00000202 [-------] 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 00007f5d07bd0900 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=00007f5d07021200 CR3=000000000c566000 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=355c9a8b0678018bb449df7f193f453c XMM02=ec2efd57dc4c00df000000000011d7c0 XMM03=3d33e81b4550954a000000000011d890 XMM04=5c7c2a5d4407fc4e00000000000ae988 XMM05=5138ae500b3a0dc700000000001355d8 XMM06=806171799158d96700000000001343c8 XMM07=fb795ef6d65770560000000000124940 XMM08=2c67c8bc2e329bc3000000000011d830 XMM09=00000000000000000000000000000000 XMM10=20200000000020202020202020200000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000 info registers vcpu 1 RAX=0000000080010000 RBX=0000000000000001 RCX=0000000000000000 RDX=ffff888015ea51c0 RSI=ffffffff813fc586 RDI=0000000000000006 RBP=ffff88806cf2ba08 RSP=ffff88806cf09e40 R8 =0000000000000006 R9 =00000000000f4240 R10=00000009aed68500 R11=0000000000000001 R12=ffff88806cf2c250 R13=ffff88806cf2b940 R14=ffff88806cf2b9c0 R15=dffffc0000000000 RIP=ffffffff814c07eb 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 =0000 0000000000000000 00000000 00000000 DS =0000 0000000000000000 00000000 00000000 FS =0000 00007f3074ec0900 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=00007ffe62c96000 CR3=000000000e554000 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=00000000000000000000000000000000 XMM02=00000000000000000000000000000000 XMM03=00000000000000000000000000000000 XMM04=0f8e3925f49abcd854e9569c95481b48 XMM05=00000000000000000000000000000000 XMM06=0f7339256375733d5465562068481b3d XMM07=672065736f6c635f6e6f69737365733a XMM08=652075253d64692073253d706f000000 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000