1st 0xfffffd807f00c9f0 vmmaplk (&map->lock) @ /syzkaller/managers/setuid/kernel/sys/uvm/uvm_fault.c:1442 2nd 0xfffffd806792c700 inode (&ip->i_lock) @ /syzkaller/managers/setuid/kernel/sys/ufs/ufs/ufs_vnops.c:1547 lock order "&ip->i_lock"(rrwlock) -> "&map->lock"(rwlock) first seen at: #0 witness_checkorder+0x6d8 #1 _rw_enter+0xbf #2 vm_map_lock_ln+0x14e #3 uvm_map+0x2e2 #4 km_alloc+0x19a #5 pool_multi_alloc_ni+0xe4 #6 pool_p_alloc+0x70 #7 pool_do_get+0x127 #8 pool_get+0x104 #9 ufsdirhash_build+0x40b #10 ufs_lookup+0x2a5 #11 VOP_LOOKUP+0x63 #12 vfs_lookup+0x552 #13 namei+0x4af #14 start_init+0xd6 lock order "&map->lock"(rwlock) -> "&ip->i_lock"(rrwlock) first seen at: #0 witness_checkorder+0x6d8 #1 _rw_enter+0xbf #2 _rrw_enter+0x5c #3 VOP_LOCK+0x55 #4 vn_lock+0x6e #5 uvn_io+0x2ca #6 uvn_get+0x206 #7 uvm_fault+0x12c1 #8 uvm_fault_wire+0x70 #9 uvm_map_pageable_wire+0x2fd #10 uvm_map_protect+0x610 #11 syscall+0x5a0 #12 Xsyscall+0x128 Stopped at db_enter+0x18: addq $0x8,%rsp ddb{1}> ddb{1}> set $lines = 0 ddb{1}> show panic the kernel did not panic ddb{1}> trace db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:399 witness_checkorder(81189923de967ac2,81,fffffd806792c6f0,fffffd806792c6f0,0) at witness_checkorder+0x12f9 witness_debugger sys/kern/subr_witness.c:2543 [inline] witness_checkorder(81189923de967ac2,81,fffffd806792c6f0,fffffd806792c6f0,0) at witness_checkorder+0x12f9 sys/kern/subr_witness.c:1089 _rw_enter(c46a56861cdc87bd,60b,fffffd806792c6f0,ffffffff81edebdf) at _rw_enter+0xbf _rrw_enter(c6b6bf24e22b17e5,fffffd8079355e98,ffffffff8139fd50,0) at _rrw_enter+0x5c sys/kern/kern_rwlock.c:410 VOP_LOCK(bd9ffecc8bdfbdae,fffffd8079355e98) at VOP_LOCK+0x55 sys/kern/vfs_vops.c:598 vn_lock(654a1a9727c16892,1000) at vn_lock+0x6e sys/kern/vfs_vnops.c:549 uvn_io(c89c40114248f88,0,0,fffffd807bcf96d8,0) at uvn_io+0x2ca sys/uvm/uvm_vnode.c:1188 uvn_get(a0f28d0f7868ab26,ffffffff8146c190,fffffd807bcf96d8,fffffd806bd8e178,0,4) at uvn_get+0x206 sys/uvm/uvm_vnode.c:1048 uvm_fault(c89c40114d07bde,20ff9000,0,4) at uvm_fault+0x12c1 sys/uvm/uvm_fault.c:1023 uvm_fault_wire(5f6bca5533307c66,4,20ff9000,fffffd806bd8e178) at uvm_fault_wire+0x70 sys/uvm/uvm_fault.c:1293 uvm_map_pageable_wire(bd9ffecc8baffa90,fffffd806bd8e178,21000000,20a00000,0,4) at uvm_map_pageable_wire+0x2fd sys/uvm/uvm_map.c:2258 uvm_map_protect(1917bbbeda9c33fd,10,ffff800020b92e28,d0d77e58078,0) at uvm_map_protect+0x610 sys/uvm/uvm_map.c:3294 syscall(487842b9050bca90) at syscall+0x5a0 mi_syscall sys/sys/syscall_mi.h:99 [inline] syscall(487842b9050bca90) at syscall+0x5a0 sys/arch/amd64/amd64/trap.c:583 Xsyscall(6,0,ffffffffffffffa4,0,3,d0b1c0b7010) at Xsyscall+0x128 end of kernel end trace frame: 0xd0d77e58100, count: -14 ddb{1}> show registers rdi 0x3 rsi 0x3ffff acpi_pdirpa+0x2be67 rbp 0xffff800020c6ae20 rbx 0x3 rdx 0x40000 acpi_pdirpa+0x2be68 rcx 0xffff800001f47000 rax 0xffff800001746440 r8 0xffffffff817c727f witness_checkorder+0x12cf r9 0x5 r10 0xb787bd4684e1bba4 r11 0x2d73e1651c56c975 r12 0xfffffd80025cdc30 r13 0xffffffff81ebbd52 cmd0646_9_tim_udma+0xc96d r14 0xffffffff822789e0 w_lodata+0x4e3f0 r15 0xffffffff82280440 w_lodata+0x55e50 rip 0xffffffff81107618 db_enter+0x18 cs 0x8 rflags 0x246 rsp 0xffff800020c6ae10 ss 0x10 db_enter+0x18: addq $0x8,%rsp ddb{1}> show proc PROC (syz-executor0) pid=306160 stat=onproc flags process=10 proc=4000000 pri=81, usrpri=81, nice=20 forw=0xffffffffffffffff, list=0xffff800020b92978,0xffffffff82300be0 process=0xffff800020b95a50 user=0xffff800020c66000, vmspace=0xfffffd807f00c9d8 estcpu=36, cpticks=0, pctcpu=0.0 user=0, sys=0, intr=0 ddb{1}> ps PID TID PPID UID S FLAGS WAIT COMMAND 45588 116809 49394 32767 7 0x10 syz-executor0 *45588 306160 49394 32767 7 0x4000010 syz-executor0 49394 44094 87186 32767 3 0x90 nanosleep syz-executor0 87186 118703 62903 0 3 0x82 wait syz-executor0 12611 304095 51869 32767 3 0x90 nanosleep syz-executor1 51869 439493 62903 0 3 0x82 wait syz-executor1 90498 103184 0 0 3 0x14200 bored sosplice 62903 108124 53783 0 3 0x82 thrsleep syz-fuzzer 62903 400671 53783 0 3 0x4000082 nanosleep syz-fuzzer 62903 61845 53783 0 3 0x4000082 thrsleep syz-fuzzer 62903 511859 53783 0 3 0x4000082 thrsleep syz-fuzzer 62903 228608 53783 0 3 0x4000082 thrsleep syz-fuzzer 62903 492500 53783 0 3 0x4000082 thrsleep syz-fuzzer 62903 65180 53783 0 3 0x4000082 thrsleep syz-fuzzer 62903 466947 53783 0 3 0x4000082 thrsleep syz-fuzzer 62903 24578 53783 0 3 0x4000082 nanosleep syz-fuzzer 62903 173195 53783 0 3 0x4000082 kqread syz-fuzzer 53783 504605 57679 0 3 0x10008a pause ksh 57679 204641 38685 0 3 0x92 select sshd 86172 476030 1 0 3 0x100083 ttyin getty 38685 194690 1 0 3 0x80 select sshd 10879 73720 80485 73 2 0x100090 syslogd 80485 210192 1 0 3 0x100082 netio syslogd 42387 524288 1 77 3 0x100090 poll dhclient 60749 146576 1 0 3 0x80 poll dhclient 42888 391076 0 0 3 0x14200 pgzero zerothread 91155 457822 0 0 3 0x14200 aiodoned aiodoned 47369 431589 0 0 3 0x14200 syncer update 62995 312098 0 0 3 0x14200 cleaner cleaner 89556 11767 0 0 3 0x14200 reaper reaper 12899 519934 0 0 3 0x14200 pgdaemon pagedaemon 21561 172960 0 0 3 0x14200 bored crynlk 86316 366040 0 0 3 0x14200 bored crypto 80906 340458 0 0 3 0x40014200 acpi0 acpi0 49500 113937 0 0 3 0x40014200 idle1 11916 200036 0 0 3 0x14200 bored softnet 58850 47117 0 0 3 0x14200 bored systqmp 21518 279260 0 0 3 0x14200 bored systq 15204 326600 0 0 3 0x40014200 bored softclock 62442 226925 0 0 3 0x40014200 idle0 1 443477 0 0 3 0x82 wait init 0 0 -1 0 3 0x10200 scheduler swapper