From owner-freebsd-bugs Thu Jun 17 23:20: 8 1999 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id CBA0314E2F for ; Thu, 17 Jun 1999 23:20:06 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id XAA45974; Thu, 17 Jun 1999 23:20:06 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Date: Thu, 17 Jun 1999 23:20:06 -0700 (PDT) Message-Id: <199906180620.XAA45974@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: dirk.meyer@dinoex.sub.org (Dirk Meyer) Subject: Re: kern/12247: userlevel program let kernel hang Reply-To: dirk.meyer@dinoex.sub.org (Dirk Meyer) Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org The following reply was made to PR kern/12247; it has been noted by GNATS. From: dirk.meyer@dinoex.sub.org (Dirk Meyer) To: bug-followup@FreeBSD.org, bde@zeta.org.au (Bruce Evans) Cc: Subject: Re: kern/12247: userlevel program let kernel hang Date: Fri, 18 Jun 1999 06:44:57 +0200 Bruce Evans wrote:, > >>Description: > > > > while debugging a userlevel program > > The user can hang the system, > > no other processes seem to work. > > Try this fix. tsleep()'s return codes are poorly documented and were > misinterpreted in lf_setlock(). tsleep() can return 0 if the process > was restarted by a debugger, `so tsleep() != 0' is not the condition for > the lock having been removed from the blocked list. Leaving the lock > on the list corrupts the list. In your program, the corrupt list > happens to be circular and this caused an endless loop in lf_wakelock() > when the list is traversed. Fine this fix is runing here now. It solve the stated problem. Only if gdb try to exit in the second time, It keep hangin and kann be killed with the debugged application will terminate too. But the system keep runninng as intended. We could close this PR. In my opinion, the hanging gdb might be a gdb bug. kind regards Dirk -- Dirk Meyer, Im Grund 4, 34317 Habichtswald, Germany -- Tel. +49-5606-6512 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message