syzkaller login: [ 28.784801] BUG: Bad rss-counter state mm:000000005ed02fba type:MM_FILEPAGES val:33 [ 28.786000] BUG: Bad rss-counter state mm:000000005ed02fba type:MM_ANONPAGES val:22 [ 28.826959] ================================================================== [ 28.828002] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 28.829120] Read of size 8 at addr ffff88801623d5c8 by task sshd/220 [ 28.829988] [ 28.830221] CPU: 1 PID: 220 Comm: sshd Not tainted 6.4.0-rc7-next-20230620 #1 [ 28.831177] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 28.832273] Call Trace: [ 28.832635] [ 28.832951] dump_stack_lvl+0x91/0xf0 [ 28.833480] print_report+0xcc/0x620 [ 28.833972] ? __virt_addr_valid+0x102/0x340 [ 28.834543] ? vma_interval_tree_remove+0xc75/0xec0 [ 28.835199] ? vma_interval_tree_remove+0xc75/0xec0 [ 28.835838] kasan_report+0xbe/0xf0 [ 28.836332] ? vma_interval_tree_remove+0xc75/0xec0 [ 28.836956] vma_interval_tree_remove+0xc75/0xec0 [ 28.837598] vma_prepare+0xc54/0x11a0 [ 28.838098] __split_vma+0x5af/0x950 [ 28.838598] ? __pfx___split_vma+0x10/0x10 [ 28.839151] ? find_held_lock+0x2c/0x110 [ 28.839704] do_vmi_align_munmap+0x2ba/0x11f0 [ 28.840289] ? lock_is_held_type+0x9f/0x120 [ 28.840832] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 28.841477] ? mtree_range_walk+0x632/0x900 [ 28.842030] ? mas_walk+0x5c7/0x7c0 [ 28.842532] do_vmi_munmap+0x1f1/0x2b0 [ 28.843037] mmap_region+0x1f9/0x2660 [ 28.843550] ? vm_mmap_pgoff+0x15c/0x3a0 [ 28.844093] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 28.844825] ? __pfx_lock_acquire+0x10/0x10 [ 28.845390] ? __pfx_mmap_region+0x10/0x10 [ 28.845930] ? security_mmap_addr+0x7d/0xa0 [ 28.846491] ? get_unmapped_area+0x1f5/0x3f0 [ 28.847044] do_mmap+0x854/0xf00 [ 28.847520] vm_mmap_pgoff+0x1a6/0x3a0 [ 28.848020] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 28.848595] ksys_mmap_pgoff+0x3af/0x500 [ 28.849130] do_syscall_64+0x3f/0x90 [ 28.849624] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 28.850298] RIP: 0033:0x7fa112b3dd82 [ 28.850755] 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.852918] RSP: 002b:00007ffd1a13ccf8 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 28.853863] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007fa112b3dd82 [ 28.854742] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007fa111f77000 [ 28.855634] RBP: 00007fa111f77000 R08: 0000000000000009 R09: 0000000000001000 [ 28.856520] R10: 0000000000000812 R11: 0000000000000206 R12: 0000560395fbfec0 [ 28.857419] R13: 00007ffd1a13cd10 R14: 00007ffd1a13cd40 R15: 00007ffd1a13d0a0 [ 28.858302] [ 28.858601] [ 28.858817] Allocated by task 213: [ 28.859290] kasan_save_stack+0x22/0x50 [ 28.859815] kasan_set_track+0x25/0x30 [ 28.860326] __kasan_slab_alloc+0x59/0x70 [ 28.860860] kmem_cache_alloc+0x16b/0x370 [ 28.861423] vm_area_dup+0x20/0x160 [ 28.861894] __split_vma+0x170/0x950 [ 28.862383] split_vma+0xc6/0x110 [ 28.862830] mprotect_fixup+0x8d2/0xb30 [ 28.863374] do_mprotect_pkey+0x87e/0xd40 [ 28.863895] __x64_sys_mprotect+0x78/0xc0 [ 28.864434] do_syscall_64+0x3f/0x90 [ 28.864909] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 28.865592] [ 28.865812] Freed by task 213: [ 28.866220] kasan_save_stack+0x22/0x50 [ 28.866725] kasan_set_track+0x25/0x30 [ 28.867237] kasan_save_free_info+0x2b/0x50 [ 28.867804] __kasan_slab_free+0x10a/0x190 [ 28.868387] kmem_cache_free+0x10d/0x4d0 [ 28.868898] rcu_core+0x8c8/0x2860 [ 28.869376] __do_softirq+0x1b7/0x7d4 [ 28.869856] [ 28.870084] Last potentially related work creation: [ 28.870674] kasan_save_stack+0x22/0x50 [ 28.871194] __kasan_record_aux_stack+0x8e/0xa0 [ 28.871798] __call_rcu_common.constprop.0+0x6a/0xb90 [ 28.872455] remove_vma+0x139/0x170 [ 28.872909] do_vmi_align_munmap+0xd4a/0x11f0 [ 28.873497] do_vmi_munmap+0x1f1/0x2b0 [ 28.873984] __vm_munmap+0x138/0x3a0 [ 28.874466] __x64_sys_munmap+0x59/0x80 [ 28.874968] do_syscall_64+0x3f/0x90 [ 28.875479] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 28.876150] [ 28.876369] The buggy address belongs to the object at ffff88801623d570 [ 28.876369] which belongs to the cache vm_area_struct of size 168 [ 28.877870] The buggy address is located 88 bytes inside of [ 28.877870] freed 168-byte region [ffff88801623d570, ffff88801623d618) [ 28.879335] [ 28.879555] The buggy address belongs to the physical page: [ 28.880239] page:0000000024ac4c9e refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1623d [ 28.881366] memcg:ffff8880162ae701 [ 28.881794] flags: 0x100000000000200(slab|node=0|zone=1) [ 28.882465] page_type: 0xffffffff() [ 28.882922] raw: 0100000000000200 ffff8880087a0c80 dead000000000122 0000000000000000 [ 28.883871] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff8880162ae701 [ 28.885065] page dumped because: kasan: bad access detected [ 28.885956] [ 28.886254] Memory state around the buggy address: [ 28.887046] ffff88801623d480: fc 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 28.888236] ffff88801623d500: 00 00 00 00 00 00 fc fc fc fc fc fc fc fc fa fb [ 28.889197] >ffff88801623d580: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.890049] ^ [ 28.890725] ffff88801623d600: fb fb fb fc fc fc fc fc fc fc fc fa fb fb fb fb [ 28.891623] ffff88801623d680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 28.892501] ================================================================== [ 28.893455] Disabling lock debugging due to kernel taint [ 31.147818] BUG: Bad rss-counter state mm:00000000d455557e type:MM_FILEPAGES val:33 [ 31.149006] BUG: Bad rss-counter state mm:00000000d455557e type:MM_ANONPAGES val:22 [ 31.577794] BUG: Bad rss-counter state mm:0000000017a89f27 type:MM_FILEPAGES val:33 [ 31.579247] BUG: Bad rss-counter state mm:0000000017a89f27 type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:42345' (ECDSA) to the list of known hosts. 2023/06/21 02:47:10 fuzzer started 2023/06/21 02:47:10 dialing manager at localhost:36067 2023/06/21 02:47:10 checking machine... 2023/06/21 02:47:10 checking revisions... [ 32.286384] kmemleak: Automatic memory scanning thread ended 2023/06/21 02:47:10 testing simple program... [ 32.334206] cgroup: Unknown subsys name 'net' [ 32.376497] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 02:47:10 Registers: info registers vcpu 0 RAX=dffffc0000000000 RBX=ffff88806ce09a78 RCX=0000000000000001 RDX=1ffff1100d9c135a RSI=ffff88806ce09e50 RDI=ffffffff813782f8 RBP=ffff88806ce09ad0 RSP=ffff88806ce09a60 R8 =0000000000000001 R9 =ffff88806ce09ab8 R10=0000000000038001 R11=0000000000022978 R12=ffff88806ce09b40 R13=0000000000000000 R14=ffff888015861b40 R15=ffff8880161d4780 RIP=ffffffff811303b2 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 00007fc25d4b6900 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=00007fc25c905e60 CR3=000000000caba000 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=1f06cf3f1b7fbd9b0d4ff74bf325047a XMM02=0000000000119c90eff9b2d0a8fce9cb XMM03=0000000000119d602c67c8bc2e329bc3 XMM04=0ad160dee117c6ce00000000000ae988 XMM05=a38cf1590e7b15ab0000000000132440 XMM06=4fda316b135da52b0000000000131230 XMM07=fb795ef6d65770560000000000121508 XMM08=2c67c8bc2e329bc30000000000119d00 XMM09=00000000000000000000000000000000 XMM10=20200000000020202020202020200000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000 info registers vcpu 1 RAX=dffffc0000000000 RBX=ffff88806cf09b60 RCX=0000000000000001 RDX=0000000000000000 RSI=ffffffff846000aa RDI=ffff88806cf09b6c RBP=0000000000000012 RSP=ffff88806cf09a78 R8 =0000000000000001 R9 =ffff88806cf09ad8 R10=0000000000038001 R11=00000000000b5080 R12=ffff88806cf09b60 R13=0000000000000000 R14=ffff888015b69b40 R15=ffff88800d764958 RIP=ffffffff813ad4ee RFL=00000213 [----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 00007f60397ba700 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=00007fc62e0f0618 CR3=000000001428c000 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=37343a3230203132206e754a3e36383c XMM01=7365733a646873732878696e755f6d61 XMM02=736f6c63206e6f6973736573203a296e XMM03=5f6d6170203a5d3932325b6468737320 XMM04=6456774875434142334f726f59427469 XMM05=485320415352203a3268737320383830 XMM06=206d6f726620746f6f7220726f662079 XMM07=00000000000000000000000000000000 XMM08=3a677562656420676f6c737973720000 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000