syzkaller login: [ 31.659963] BUG: Bad rss-counter state mm:000000001a156a0c type:MM_FILEPAGES val:33 [ 31.661104] BUG: Bad rss-counter state mm:000000001a156a0c type:MM_ANONPAGES val:22 [ 31.704365] ================================================================== [ 31.705336] BUG: KASAN: slab-use-after-free in vma_interval_tree_remove+0xc75/0xec0 [ 31.706392] Read of size 8 at addr ffff88800d9ba6b0 by task sshd/221 [ 31.707314] [ 31.707531] CPU: 1 PID: 221 Comm: sshd Not tainted 6.4.0-rc7-next-20230619 #1 [ 31.708485] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.12.0-1 04/01/2014 [ 31.709575] Call Trace: [ 31.709964] [ 31.710253] dump_stack_lvl+0x91/0xf0 [ 31.710802] print_report+0xcc/0x620 [ 31.711343] ? __virt_addr_valid+0x102/0x340 [ 31.711961] ? vma_interval_tree_remove+0xc75/0xec0 [ 31.712654] ? vma_interval_tree_remove+0xc75/0xec0 [ 31.713350] kasan_report+0xbe/0xf0 [ 31.713880] ? vma_interval_tree_remove+0xc75/0xec0 [ 31.714578] vma_interval_tree_remove+0xc75/0xec0 [ 31.715176] vma_prepare+0xc54/0x11a0 [ 31.715768] __split_vma+0x5af/0x950 [ 31.716236] ? __pfx___split_vma+0x10/0x10 [ 31.716769] ? find_held_lock+0x2c/0x110 [ 31.717291] do_vmi_align_munmap+0x2ba/0x11f0 [ 31.717853] ? lock_is_held_type+0x9f/0x120 [ 31.718388] ? __pfx_do_vmi_align_munmap+0x10/0x10 [ 31.718997] ? mtree_range_walk+0x632/0x900 [ 31.719544] ? mas_walk+0x5c7/0x7c0 [ 31.720017] do_vmi_munmap+0x1f1/0x2b0 [ 31.720507] mmap_region+0x1f9/0x2660 [ 31.720990] ? vm_mmap_pgoff+0x15c/0x3a0 [ 31.721495] ? __pfx_arch_get_unmapped_area_topdown+0x10/0x10 [ 31.722201] ? __pfx_lock_acquire+0x10/0x10 [ 31.722736] ? __pfx_mmap_region+0x10/0x10 [ 31.723268] ? security_mmap_addr+0x7d/0xa0 [ 31.723795] ? get_unmapped_area+0x1f5/0x3f0 [ 31.724342] do_mmap+0x854/0xf00 [ 31.724795] vm_mmap_pgoff+0x1a6/0x3a0 [ 31.725283] ? __pfx_vm_mmap_pgoff+0x10/0x10 [ 31.725838] ksys_mmap_pgoff+0x3af/0x500 [ 31.726339] do_syscall_64+0x3f/0x90 [ 31.726822] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 31.727473] RIP: 0033:0x7f6dc7cfad82 [ 31.727928] 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.730044] RSP: 002b:00007ffef4c591f8 EFLAGS: 00000206 ORIG_RAX: 0000000000000009 [ 31.730942] RAX: ffffffffffffffda RBX: 0000000000000812 RCX: 00007f6dc7cfad82 [ 31.731783] RDX: 0000000000000005 RSI: 0000000000001000 RDI: 00007f6dc7134000 [ 31.732626] RBP: 00007f6dc7134000 R08: 0000000000000009 R09: 0000000000001000 [ 31.733482] R10: 0000000000000812 R11: 0000000000000206 R12: 0000561f0c6fcf70 [ 31.734318] R13: 00007ffef4c59210 R14: 00007ffef4c59240 R15: 00007ffef4c595a0 [ 31.735170] [ 31.735460] [ 31.735673] Allocated by task 214: [ 31.736108] kasan_save_stack+0x22/0x50 [ 31.736611] kasan_set_track+0x25/0x30 [ 31.737114] __kasan_slab_alloc+0x59/0x70 [ 31.737640] kmem_cache_alloc+0x16b/0x370 [ 31.738157] vm_area_dup+0x20/0x160 [ 31.738610] __split_vma+0x170/0x950 [ 31.739072] split_vma+0xc6/0x110 [ 31.739508] mprotect_fixup+0x8d2/0xb30 [ 31.740004] do_mprotect_pkey+0x87e/0xd40 [ 31.740520] __x64_sys_mprotect+0x78/0xc0 [ 31.741048] do_syscall_64+0x3f/0x90 [ 31.741519] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 31.742156] [ 31.742372] Freed by task 13: [ 31.742759] kasan_save_stack+0x22/0x50 [ 31.743264] kasan_set_track+0x25/0x30 [ 31.743756] kasan_save_free_info+0x2b/0x50 [ 31.744288] __kasan_slab_free+0x10a/0x190 [ 31.744831] kmem_cache_free+0x10d/0x4d0 [ 31.745365] rcu_core+0x8c8/0x2860 [ 31.745822] __do_softirq+0x1b7/0x7d4 [ 31.746298] [ 31.746514] Last potentially related work creation: [ 31.747093] kasan_save_stack+0x22/0x50 [ 31.747597] __kasan_record_aux_stack+0x8e/0xa0 [ 31.748162] __call_rcu_common.constprop.0+0x6a/0xb90 [ 31.748808] remove_vma+0x139/0x170 [ 31.749259] do_vmi_align_munmap+0xd4a/0x11f0 [ 31.749811] do_vmi_munmap+0x1f1/0x2b0 [ 31.750294] __vm_munmap+0x138/0x3a0 [ 31.750763] __x64_sys_munmap+0x59/0x80 [ 31.751253] do_syscall_64+0x3f/0x90 [ 31.751724] entry_SYSCALL_64_after_hwframe+0x6e/0xd8 [ 31.752364] [ 31.752579] The buggy address belongs to the object at ffff88800d9ba658 [ 31.752579] which belongs to the cache vm_area_struct of size 168 [ 31.754069] The buggy address is located 88 bytes inside of [ 31.754069] freed 168-byte region [ffff88800d9ba658, ffff88800d9ba700) [ 31.755468] [ 31.755683] The buggy address belongs to the physical page: [ 31.756333] page:000000005794c507 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0xd9ba [ 31.757424] memcg:ffff888009647b01 [ 31.757853] flags: 0x100000000000200(slab|node=0|zone=1) [ 31.758488] page_type: 0xffffffff() [ 31.758935] raw: 0100000000000200 ffff88800879fc80 dead000000000122 0000000000000000 [ 31.759844] raw: 0000000000000000 0000000000110011 00000001ffffffff ffff888009647b01 [ 31.760758] page dumped because: kasan: bad access detected [ 31.761415] [ 31.761629] Memory state around the buggy address: [ 31.762207] ffff88800d9ba580: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 31.763053] ffff88800d9ba600: 00 00 00 fc fc fc fc fc fc fc fc fa fb fb fb fb [ 31.763900] >ffff88800d9ba680: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb [ 31.764755] ^ [ 31.765339] ffff88800d9ba700: fc fc fc fc fc fc fc fc fa fb fb fb fb fb fb fb [ 31.766203] ffff88800d9ba780: fb fb fb fb fb fb fb fb fb fb fb fb fb fc fc fc [ 31.767049] ================================================================== [ 31.767974] Disabling lock debugging due to kernel taint [ 33.698299] BUG: Bad rss-counter state mm:0000000054fdf2f2 type:MM_FILEPAGES val:33 [ 33.699317] BUG: Bad rss-counter state mm:0000000054fdf2f2 type:MM_ANONPAGES val:22 [ 34.192962] BUG: Bad rss-counter state mm:00000000183686ee type:MM_FILEPAGES val:33 [ 34.194730] BUG: Bad rss-counter state mm:00000000183686ee type:MM_ANONPAGES val:22 Warning: Permanently added '[localhost]:62927' (ECDSA) to the list of known hosts. 2023/06/19 13:48:18 fuzzer started 2023/06/19 13:48:18 dialing manager at localhost:44161 2023/06/19 13:48:18 checking machine... 2023/06/19 13:48:18 checking revisions... [ 34.946819] kmemleak: Automatic memory scanning thread ended 2023/06/19 13:48:19 testing simple program... [ 34.991130] cgroup: Unknown subsys name 'net' [ 35.031151] cgroup: Unknown subsys name 'rlimit' executing program executing program executing program VM DIAGNOSIS: 13:48:17 Registers: info registers vcpu 0 RAX=ffffffff86605df9 RBX=0000000000000001 RCX=ffffffff864bb9ee RDX=dffffc0000000000 RSI=ffffffff85407f00 RDI=1ffff1100d9c135e RBP=ffff88806ce09af0 RSP=ffff88806ce09a28 R8 =ffffffff864bb9f2 R9 =ffff88806ce09ad8 R10=ffffffff85d3bed7 R11=00000000000b5420 R12=ffff88806ce09af8 R13=ffff88806ce09ae0 R14=ffffffff85407f08 R15=ffff88806ce09a98 RIP=ffffffff8113106f 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 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=00007ffd2fbcb518 CR3=0000000005482000 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=00007f5c6365b510000055ea4fb0c790 XMM02=6f6974707972636e6561737268746977 XMM03=00000000000000000000000000777074 XMM04=40404040404040404040404040404040 XMM05=5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a XMM06=20202020202020202020202020202020 XMM07=ffffffffffff00ffffff00ffffff00ff XMM08=00002000000000202020002020200000 XMM09=ffffffffffff00ffffff00ffffff00ff XMM10=00002000000000202020002020200000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000 info registers vcpu 1 RAX=00000000000000a4 RBX=ffff8880172df718 RCX=0000000000000000 RDX=ffff88801464e57c RSI=ffffffff8372674d RDI=0000000000000005 RBP=ffff88801464e000 RSP=ffff8880172df6b0 R8 =0000000000000005 R9 =0000000000000000 R10=00000000000000a4 R11=0000094a0000094a R12=ffff8880166f9780 R13=ffff88801464e57c R14=ffff88801464e579 R15=ffff88801464e600 RIP=ffffffff83869201 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 00007efedde7e900 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=00007efede435618 CR3=000000000fd14000 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=6e69676f6c5f6d61702c78756e696c65 XMM02=755f6d61702c74696d7265705f6d6170 XMM03=2c766e655f6d61702c7374696d696c5f XMM04=6d61702c766e655f6d61702c7374696d XMM05=78696e755f6d61702c74696d7265705f XMM06=6469756e69676f6c5f6d61702c78756e XMM07=672065736f6c635f6e6f69737365733a XMM08=61662029286e65706f5f746964756100 XMM09=00000000000000000000000000000000 XMM10=00000000000000000000000000000000 XMM11=00000000000000000000000000000000 XMM12=00000000000000000000000000000000 XMM13=00000000000000000000000000000000 XMM14=00000000000000000000000000000000 XMM15=00000000000000000000000000000000