Date: Tue, 11 Jun 2002 16:27:32 GMT From: Tor.Egge@cvsup.no.freebsd.org To: killer@lothlorien.no, hsu@freebsd.org Cc: current@freebsd.org Subject: Re: Crash after world/kernel upgrade Message-ID: <20020611162732B.tegge@cvsup.no.freebsd.org> In-Reply-To: <1023807519.376.46.camel@vampire.lothlorien.no> References: <1023807519.376.46.camel@vampire.lothlorien.no>
next in thread | previous in thread | raw e-mail | index | archive | help
----Next_Part(Tue_Jun_11_16:26:55_2002_809)-- Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit > System crashed after updating today. > During the start of system services, in specific > at the start of sendmail the system crashes with > the new kernel. :/ There are some problems with the inpcb locking: - attempts to destroy held lock in in_pcbdetach. - typo in unlocking (causing recursive lock instead) - lack of inet6 support for inpcb locking, e.g. no handling of locks in in6_pcbdetach. I had to comment out INET6 from my kernel config file and apply the enclosed patch to get my machine to boot today. - Tor Egge ----Next_Part(Tue_Jun_11_16:26:55_2002_809)-- Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=netinetfix Index: sys/netinet/in_pcb.c =================================================================== RCS file: /home/ncvs/src/sys/netinet/in_pcb.c,v retrieving revision 1.106 diff -u -r1.106 in_pcb.c --- sys/netinet/in_pcb.c 10 Jun 2002 20:05:36 -0000 1.106 +++ sys/netinet/in_pcb.c 11 Jun 2002 16:13:29 -0000 @@ -573,6 +573,11 @@ rtfree(inp->inp_route.ro_rt); ip_freemoptions(inp->inp_moptions); inp->inp_vflag = 0; + /* XXX: Kludge: Unlock inp before crashing */ + if (mtx_owned(&inp->inp_mtx)) { + printf("Warning: INP_LOCK held in in_pcbdetach\n"); + INP_UNLOCK(inp); + } INP_LOCK_DESTROY(inp); uma_zfree(ipi->ipi_zone, inp); } @@ -741,7 +746,7 @@ } INP_UNLOCK(inp); } - INP_INFO_RLOCK(pcbinfo); + INP_INFO_RUNLOCK(pcbinfo); } /* ----Next_Part(Tue_Jun_11_16:26:55_2002_809)---- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020611162732B.tegge>