Date: Wed, 5 Jul 2006 11:39:01 -0400 From: John Baldwin <jhb@freebsd.org> To: freebsd-current@freebsd.org Cc: Martin Blapp <mb@imp.ch>, mlaier@freebsd.org Subject: Re: Please help reviewing ! Got another crash because of the ttymodem() / ttyclose() race Message-ID: <200607051139.02615.jhb@freebsd.org> In-Reply-To: <20060630101132.S14714@godot.imp.ch> References: <20060630101132.S14714@godot.imp.ch>
next in thread | previous in thread | raw e-mail | index | archive | help
On Friday 30 June 2006 05:09, Martin Blapp wrote: > > Hi all, > > This time its FreeBSD 5.5 RELEASE. Same code is in 6.X (which crashed on a > different server 5 days ago) and CURRENT. > > #25 0xc064f4bd in ttymodem () > #26 0xc06532bd in ptcclose () > #27 0xc05e4e14 in spec_close () > #28 0xc05e3edf in spec_vnoperate () > #29 0xc06815e0 in vn_close () > #30 0xc06825f2 in vn_closefile () > #31 0xc0601ba4 in fdrop_locked () > #32 0xc0601af1 in fdrop () > #33 0xc060015b in closef () > #34 0xc05fd5e5 in close () > #35 0xc07c5e97 in syscall () > > Can PLEASE PLEASE someone help me fix this problem > and review the patch ? > > The patch is based on Max Laiers tty.t_pgrp patch. > > http://mx.imp.ch/patch-tty.t_pgrp.diff > > Especially the part in ttyinfo() needs to be reviewed > carefully. I'm not sure that the proctree_lock should protect t_pgrp as that is part of the tty structure, not process groups or session structures. I think probably it should be protected by Giant for now until the tty subsystem is locked. Also, the ttyinfo() part will not work since it tries to acquire a mutex (PGRP_LOCK()) while holding a spin mutex (sched_lock). -- John Baldwin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200607051139.02615.jhb>