From owner-freebsd-bugs@freebsd.org Thu Apr 26 09:29:06 2018 Return-Path: Delivered-To: freebsd-bugs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 72213FA7AC2 for ; Thu, 26 Apr 2018 09:29:06 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id CB8247310E for ; Thu, 26 Apr 2018 09:29:05 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.ysv.freebsd.org (Postfix) id 82FB3FA7ABC; Thu, 26 Apr 2018 09:29:05 +0000 (UTC) Delivered-To: bugs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 48522FA7ABA for ; Thu, 26 Apr 2018 09:29:05 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.ysv.freebsd.org (mxrelay.ysv.freebsd.org [IPv6:2001:1900:2254:206a::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.ysv.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id BF315730E5 for ; Thu, 26 Apr 2018 09:29:04 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.ysv.freebsd.org (Postfix) with ESMTPS id 0F350137B0 for ; Thu, 26 Apr 2018 09:29:04 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id w3Q9T39F090212 for ; Thu, 26 Apr 2018 09:29:03 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id w3Q9T3vu090211 for bugs@FreeBSD.org; Thu, 26 Apr 2018 09:29:03 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 227787] kldunload sem: panic: deadlkres: possible deadlock detected for 0xfffff80141b04560, blocked for 1801695 ticks Date: Thu, 26 Apr 2018 09:29:04 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: eadler@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Apr 2018 09:29:06 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D227787 Bug ID: 227787 Summary: kldunload sem: panic: deadlkres: possible deadlock detected for 0xfffff80141b04560, blocked for 1801695 ticks Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: eadler@FreeBSD.org # kldload sem # kldunload sem # kldunload sem < wait debug.deadlkres.slptime_threshold seconds > Reading symbols from ./kernel/kernel...Reading symbols from /usr/home/eax/crashes/sem_load_dklres/kernel/kernel.debug...done. done. Unread portion of the kernel message buffer: [29474] panic: deadlkres: possible deadlock detected for 0xfffff80141b04560, blocked for 1801695 ticks [29474] [29474] cpuid =3D 31 [29474] time =3D 1523493929 [29474] KDB: stack backtrace: [29474] db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xfffffe00a6204960 [29474] vpanic() at vpanic+0x18d/frame 0xfffffe00a62049c0 [29474] panic() at panic+0x43/frame 0xfffffe00a6204a20 [29474] deadlkres() at deadlkres+0x3a6/frame 0xfffffe00a6204a70 [29474] fork_exit() at fork_exit+0x84/frame 0xfffffe00a6204ab0 [29474] fork_trampoline() at fork_trampoline+0xe/frame 0xfffffe00a6204ab0 [29474] --- trap 0, rip =3D 0, rsp =3D 0, rbp =3D 0 --- [29474] KDB: enter: panic __curthread () at ./machine/pcpu.h:230 230 __asm("movq %%gs:%1,%0" : "=3Dr" (td) (kgdb) bt #0 __curthread () at ./machine/pcpu.h:230 #1 doadump (textdump=3D0x1) at /usr/src/sys/kern/kern_shutdown.c:361 #2 0xffffffff80434f4c in db_fncall_generic (addr=3D, rv=3D, nargs=3D, args=3D) at /usr/src/sys/ddb/db_command.c:609 #3 db_fncall (dummy1=3D, dummy2=3D, dummy3=3D, dummy4=3D) at /usr/src/sys/ddb/db_command.c:657 #4 0xffffffff80434a99 in db_command (last_cmdp=3D, cmd_table=3D, dopager=3D) at /usr/src/sys/ddb/db_command.c:481 #5 0xffffffff80434814 in db_command_loop () at /usr/src/sys/ddb/db_command.c:534 #6 0xffffffff80437a3f in db_trap (type=3D, code=3D) at /usr/src/sys/ddb/db_main.c:250 #7 0xffffffff80babf53 in kdb_trap (type=3D0x3, code=3D0xffff0ff0, tf=3D) at /usr/src/sys/kern/subr_kdb.c:697 #8 0xffffffff81024aa8 in trap (frame=3D0xfffffe00a6204890) at /usr/src/sys/amd64/amd64/trap.c:548 #9 #10 kdb_enter (why=3D0xffffffff8129f663 "panic", msg=3D) at /usr/src/sys/kern/subr_kdb.c:479 #11 0xffffffff80b66b5a in vpanic (fmt=3D, ap=3D0xfffffe00a62= 04a00) at /usr/src/sys/kern/kern_shutdown.c:826 #12 0xffffffff80b66be3 in panic (fmt=3D0xffffffff81deab08 "5i&\201\377\377\377\377") at /usr/src/sys/kern/kern_shutdown.c:764 #13 0xffffffff80b00466 in deadlkres () at /usr/src/sys/kern/kern_clock.c:288 #14 0xffffffff80b26e34 in fork_exit (callout=3D0xffffffff80b000c0 , arg=3D0x0, frame=3D0xfffffe00a6204ac0) at /usr/src/sys/kern/kern_fork.c:1039 #15 (kgdb) #13 0xffffffff80b00466 in deadlkres () at /usr/src/sys/kern/kern_clock.c:288 288 panic("%s: possible deadlock detected for %p, blocked for %d ticks\n", (kgdb) info locals tryl =3D slpticks =3D 0x1b7740 blkticks =3D 0xdbba0 p =3D 0xfffff80141b00538 td =3D wchan =3D 0xffffffff81deb2d8 tticks =3D 0x1b7ddf slptype =3D i =3D (kgdb) info registers rax 0x12 0x12 rbx 0xffffffff81deb2d8 0xffffffff81deb2d8 rcx 0x80 0x80 rdx 0xfffffe00a6204850 0xfffffe00a6204850 rsi 0x80 0x80 rdi 0xffffffff81deab08 0xffffffff81deab08 rbp 0xfffffe00a6204a70 0xfffffe00a6204a70 rsp 0xfffffe00a6204a30 0xfffffe00a6204a30 r8 0x1 0x1 r9 0x0 0x0 r10 0xffffffff81cdc698 0xffffffff81cdc698 r11 0x0 0x0 r12 0xfffff80141b04560 0xfffff80141b04560 r13 0xdbba0 0xdbba0 r14 0xfffff80141b00538 0xfffff80141b00538 r15 0x1b7ddf 0x1b7ddf rip 0xffffffff80b00466 0xffffffff80b00466 eflags 0x82 [ SF ] cs 0x20 0x20 ss 0x28 0x28 ds es fs gs fs_base gs_base (kgdb) p *p $3 =3D { p_list =3D { le_next =3D 0xfffff80200103000,=20 le_prev =3D 0xfffff8001f187000 },=20 p_threads =3D { tqh_first =3D 0xfffff80141b04560,=20 tqh_last =3D 0xfffff80141b04570 },=20 p_slock =3D { lock_object =3D { lo_name =3D 0xffffffff8129ab1c "process slock",=20 lo_flags =3D 0x20030000,=20 lo_data =3D 0x0,=20 lo_witness =3D 0x0 },=20 mtx_lock =3D 0x0 },=20 p_ucred =3D 0xfffff80200216c00,=20 p_fd =3D 0xfffff800398548a0,=20 p_fdtol =3D 0x0,=20 p_stats =3D 0xfffff80012fea000,=20 p_limit =3D 0xfffff8001fa23500,=20 p_limco =3D { c_links =3D { le =3D { le_next =3D 0x0,=20 le_prev =3D 0x0 },=20 sle =3D { sle_next =3D 0x0 },=20 tqe =3D { tqe_next =3D 0x0,=20 tqe_prev =3D 0x0 } },=20 c_time =3D 0x0,=20 c_precision =3D 0x0,=20 c_arg =3D 0x0,=20 c_func =3D 0x0,=20 c_lock =3D 0xfffff80141b00658,=20 c_flags =3D 0x0,=20 c_iflags =3D 0x0,=20 c_cpu =3D 0x0 },=20 p_sigacts =3D 0xfffff80285537000,=20 p_flag =3D 0x10004002,=20 p_flag2 =3D 0x0,=20 p_state =3D PRS_NORMAL,=20 p_pid =3D 0xbc73,=20 p_hash =3D { le_next =3D 0x0,=20 le_prev =3D 0xfffffe00063ae398 },=20 p_pglist =3D { le_next =3D 0x0,=20 le_prev =3D 0xfffff800390bc710 },=20 p_pptr =3D 0xfffff80003696538,=20 p_sibling =3D { le_next =3D 0xfffff80294339a70,=20 le_prev =3D 0xfffff8001f5c4620 },=20 p_children =3D { lh_first =3D 0x0 },=20 p_reaper =3D 0xfffff80003696538,=20 p_reaplist =3D { lh_first =3D 0x0 },=20 p_reapsibling =3D { le_next =3D 0xfffff80200103000,=20 le_prev =3D 0xfffff8001f187110 },=20 p_mtx =3D { lock_object =3D { lo_name =3D 0xffffffff812297e6 "process lock",=20 lo_flags =3D 0x21430000,=20 lo_data =3D 0x0,=20 lo_witness =3D 0xfffff8087f063400 },=20 mtx_lock =3D 0x0 },=20 p_statmtx =3D { lock_object =3D { lo_name =3D 0xffffffff811e2c04 "pstatl",=20 lo_flags =3D 0x20030000,=20 lo_data =3D 0x0,=20 lo_witness =3D 0x0 },=20 mtx_lock =3D 0x0 },=20 p_itimmtx =3D { lock_object =3D { lo_name =3D 0xffffffff8121fea2 "pitiml",=20 lo_flags =3D 0x20030000,=20 lo_data =3D 0x0,=20 lo_witness =3D 0x0 },=20 mtx_lock =3D 0x0 },=20 p_profmtx =3D { lock_object =3D { lo_name =3D 0xffffffff8127b6d4 "pprofl",=20 lo_flags =3D 0x20030000,=20 lo_data =3D 0x0,=20 lo_witness =3D 0x0 },=20 mtx_lock =3D 0x0 },=20 p_ksi =3D 0xfffff8000756a000,=20 p_sigqueue =3D { sq_signals =3D { __bits =3D {0x100, 0x0, 0x0, 0x0} },=20 sq_kill =3D { __bits =3D {0x100, 0x0, 0x0, 0x0} },=20 sq_ptrace =3D { __bits =3D {0x0, 0x0, 0x0, 0x0} },=20 sq_list =3D { tqh_first =3D 0x0,=20 tqh_last =3D 0xfffff80141b00710 },=20 sq_proc =3D 0xfffff80141b00538,=20 sq_flags =3D 0x1 },=20 p_oppid =3D 0x0,=20 p_vmspace =3D 0xfffff80141f6c000,=20 p_swtick =3D 0x819d1360,=20 p_cowgen =3D 0x2,=20 p_realtimer =3D { it_interval =3D { tv_sec =3D 0x0,=20 tv_usec =3D 0x0 },=20 it_value =3D { tv_sec =3D 0x0,=20 tv_usec =3D 0x0 } },=20 p_ru =3D { ru_utime =3D { tv_sec =3D 0x0,=20 tv_usec =3D 0x0 },=20 ru_stime =3D { tv_sec =3D 0x0,=20 tv_usec =3D 0x0 },=20 ru_maxrss =3D 0x0,=20 ru_ixrss =3D 0x0,=20 ru_idrss =3D 0x0,=20 ru_isrss =3D 0x0,=20 ru_minflt =3D 0x0,=20 ru_majflt =3D 0x0,=20 ru_nswap =3D 0x0,=20 ru_inblock =3D 0x0,=20 ru_oublock =3D 0x0,=20 ru_msgsnd =3D 0x0,=20 ru_msgrcv =3D 0x0,=20 ru_nsignals =3D 0x0,=20 ru_nvcsw =3D 0x0,=20 ru_nivcsw =3D 0x0 },=20 p_rux =3D { rux_runtime =3D 0x300256,=20 rux_uticks =3D 0x0,=20 rux_sticks =3D 0x0,=20 rux_iticks =3D 0x0,=20 rux_uu =3D 0x0,=20 rux_su =3D 0x39f,=20 rux_tu =3D 0x39f },=20 p_crux =3D { rux_runtime =3D 0x0,=20 rux_uticks =3D 0x0,=20 rux_sticks =3D 0x0,=20 rux_iticks =3D 0x0,=20 rux_uu =3D 0x0,=20 rux_su =3D 0x0,=20 rux_tu =3D 0x0 },=20 p_profthreads =3D 0x0,=20 p_exitthreads =3D 0x0,=20 p_traceflag =3D 0x0,=20 p_tracevp =3D 0x0,=20 p_tracecred =3D 0x0,=20 p_textvp =3D 0xfffff80014df4d20,=20 p_lock =3D 0x0,=20 p_sigiolst =3D { slh_first =3D 0x0 },=20 p_sigparent =3D 0x14,=20 p_sig =3D 0x0,=20 p_code =3D 0x0,=20 p_stops =3D 0x0,=20 p_stype =3D 0x0,=20 p_step =3D 0x0,=20 p_pfsflags =3D 0x0,=20 p_ptevents =3D 0x0,=20 p_nlminfo =3D 0x0,=20 p_aioinfo =3D 0x0,=20 p_singlethread =3D 0x0,=20 p_suspcount =3D 0x0,=20 p_xthread =3D 0x0,=20 p_boundary_count =3D 0x0,=20 p_pendingcnt =3D 0x0,=20 p_itimers =3D 0x0,=20 p_procdesc =3D 0x0,=20 p_treeflag =3D 0x0,=20 p_pendingexits =3D 0x0,=20 p_filemon =3D 0x0,=20 p_magic =3D 0xbeefface,=20 p_osrel =3D 0x124fbd,=20 p_comm =3D "kldload",=20 p_sysent =3D 0xffffffff81b68d48 ,=20 p_args =3D 0xfffff80039abd280,=20 p_cpulimit =3D 0x7fffffffffffffff,=20 p_nice =3D 0x0,=20 p_fibnum =3D 0x0,=20 p_reapsubtree =3D 0xcbc,=20 p_elf_machine =3D 0x3e,=20 p_elf_flags =3D 0x0,=20 p_xexit =3D 0x0,=20 p_xsig =3D 0x0,=20 p_pgrp =3D 0xfffff800390bc700,=20 p_klist =3D 0xfffff800031068c0,=20 p_numthreads =3D 0x1,=20 p_md =3D { md_ldt =3D 0x0,=20 md_ldt_sd =3D { sd_lolimit =3D 0x0,=20 sd_lobase =3D 0x0,=20 sd_type =3D 0x0,=20 sd_dpl =3D 0x0,=20 sd_p =3D 0x0,=20 sd_hilimit =3D 0x0,=20 sd_xx0 =3D 0x0,=20 sd_gran =3D 0x0,=20 sd_hibase =3D 0x0,=20 sd_xx1 =3D 0x0,=20 sd_mbz =3D 0x0,=20 sd_xx2 =3D 0x0 } },=20 p_itcallout =3D { c_links =3D { le =3D { le_next =3D 0x0,=20 le_prev =3D 0x0 },=20 sle =3D { sle_next =3D 0x0 },=20 tqe =3D { tqe_next =3D 0x0,=20 tqe_prev =3D 0x0 } },=20 c_time =3D 0x0,=20 c_precision =3D 0x0,=20 c_arg =3D 0x0,=20 c_func =3D 0x0,=20 c_lock =3D 0xfffff80141b00658,=20 c_flags =3D 0x0,=20 c_iflags =3D 0x0,=20 c_cpu =3D 0x0 },=20 p_acflag =3D 0x0,=20 p_peers =3D 0x0,=20 p_leader =3D 0xfffff80141b00538,=20 p_emuldata =3D 0x0,=20 p_label =3D 0x0,=20 p_ktr =3D { stqh_first =3D 0x0,=20 stqh_last =3D 0xfffff80141b00a00 },=20 p_mqnotifier =3D { lh_first =3D 0x0 },=20 p_dtrace =3D 0xfffff80200ed04c0,=20 p_pwait =3D { cv_description =3D 0xffffffff811f7ade "ppwait",=20 cv_waiters =3D 0x0 },=20 p_dbgwait =3D { cv_description =3D 0xffffffff8125c296 "dbgwait",=20 cv_waiters =3D 0x0 },=20 p_prev_runtime =3D 0x0,=20 p_racct =3D 0x0,=20 p_throttled =3D 0x0,=20 p_orphan =3D { le_next =3D 0x0,=20 le_prev =3D 0x0 },=20 p_orphans =3D { lh_first =3D 0x0 } } (kgdb) p (*(struct thread*)0xfffff80141b04560).td_tid $2 =3D 0x18bd8 (kgdb) tid 18bd8 (kgdb) bt #0 sched_switch (td=3D0xfffff80141b04560, newtd=3D0xfffff80003699000, flags=3D) at /usr/src/sys/kern/sched_ule.c:2115 #1 0xffffffff80b7156c in mi_switch (flags=3D0x104, newtd=3D0x0) at /usr/src/sys/kern/kern_synch.c:437 #2 0xffffffff80bba7ed in sleepq_switch (wchan=3D0xffffffff81deb2d8 , pri=3D0x0) at /usr/src/sys/kern/subr_sleepqueue.c:613 #3 0xffffffff80bba693 in sleepq_wait (wchan=3D0xffffffff81deb2d8 , pri=3D0x0) at /usr/src/sys/kern/subr_sleepqueue.c:692 #4 0xffffffff80b6f329 in _sx_xlock_hard (sx=3D0xffffffff81deb2d8 , x=3D, opts=3D, file=3D, line= =3D) at /usr/src/sys/kern/kern_sx.c:777 #5 0xffffffff80b6ef31 in _sx_xlock (sx=3D0xffffffff81deb2d8 , opts= =3D0x0, file=3D0xffffffff811a5d65 "/usr/src/sys/kern/kern_linker.c", line=3D0x42e) = at /usr/src/sys/kern/kern_sx.c:319 #6 0xffffffff80b3834e in kern_kldload (td=3D, file=3D, fileid=3D0xfffffe00af1f8964) at /usr/src/sys/kern/kern_linker.c:1070 #7 0xffffffff80b3848b in sys_kldload (td=3D0xfffff80141b04560, uap=3D) at /usr/src/sys/kern/kern_linker.c:1097 #8 0xffffffff8102606b in syscallenter (td=3D0xfffff80141b04560) at /usr/src/sys/amd64/amd64/../../kern/subr_syscall.c:134 #9 amd64_syscall (td=3D0xfffff80141b04560, traced=3D0x0) at /usr/src/sys/amd64/amd64/trap.c:936 #10 #11 0x00000008002cfd8a in ?? () Backtrace stopped: Cannot access memory at address 0x7fffffffd478 (kgdb) frame Stack level 3, frame at 0xfffffe00af1f8820: rip =3D 0xffffffff80bba693 in sleepq_wait (/usr/src/sys/kern/subr_sleepqueue.c:692); saved rip =3D 0xffffffff80b6f329 called by frame at 0xfffffe00af1f88d0, caller of frame at 0xfffffe00af1f87= f0 source language c. Arglist at 0xfffffe00af1f8810, args: wchan=3D0xffffffff81deb2d8 , pri=3D0x0 Locals at 0xfffffe00af1f8810, Previous frame's sp is 0xfffffe00af1f8820 Saved registers: rbx at 0xfffffe00af1f87f8, rbp at 0xfffffe00af1f8810, r14 at 0xfffffe00af1f8800, r15 at 0xfffffe00af1f8808, rip at 0xfffffe00af1f8818 wchan =3D 0xffffffff81deb2d8 pri =3D 0x0 td =3D 0xfffff80141b04560 (kgdb) p td $4 =3D (struct thread *) 0xfffff80141b04560 (kgdb) p *td $5 =3D { td_lock =3D 0xffffffff81ed3648 , td_proc =3D 0xfffff80141b00538, td_plist =3D { tqe_next =3D 0x0, tqe_prev =3D 0xfffff80141b00548 }, td_runq =3D { tqe_next =3D 0x0, tqe_prev =3D 0xffffffff81e06448 }, td_slpq =3D { tqe_next =3D 0xfffff802946fb560, tqe_prev =3D 0xfffff80007f33080 }, td_lockq =3D { tqe_next =3D 0xfffff80039b57000, tqe_prev =3D 0xfffffe01020e55e8 }, td_hash =3D { le_next =3D 0x0, le_prev =3D 0xfffffe00063c5ec0 }, td_cpuset =3D 0xfffff8000366ef00, td_domain =3D { dr_policy =3D 0xffffffff81deac18 , dr_iterator =3D 0x0 }, td_sel =3D 0xfffff8001f462c80, td_sleepqueue =3D 0x0, td_turnstile =3D 0xfffff8001f627540, td_rlqe =3D 0xfffff80014fe1280, td_umtxq =3D 0xfffff8001ffd5280, td_tid =3D 0x18bd8, .... --=20 You are receiving this mail because: You are the assignee for the bug.=