From owner-freebsd-current@FreeBSD.ORG Fri Dec 19 00:06:32 2003 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B5E8916A4CE; Fri, 19 Dec 2003 00:06:32 -0800 (PST) Received: from gw.catspoiler.org (217-ip-163.nccn.net [209.79.217.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id A442443D1F; Fri, 19 Dec 2003 00:06:30 -0800 (PST) (envelope-from truckman@FreeBSD.org) Received: from FreeBSD.org (mousie.catspoiler.org [192.168.101.2]) by gw.catspoiler.org (8.12.9p2/8.12.9) with ESMTP id hBJ86LeF076901; Fri, 19 Dec 2003 00:06:24 -0800 (PST) (envelope-from truckman@FreeBSD.org) Message-Id: <200312190806.hBJ86LeF076901@gw.catspoiler.org> Date: Fri, 19 Dec 2003 00:06:21 -0800 (PST) From: Don Lewis To: mezz7@cox.net In-Reply-To: <200312190753.hBJ7rGeF076868@gw.catspoiler.org> MIME-Version: 1.0 Content-Type: TEXT/plain; charset=us-ascii cc: freebsd-current@FreeBSD.org cc: gibbs@FreeBSD.org Subject: Re: The reboot doesn't work anymore in today -CURRENT.. X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 19 Dec 2003 08:06:32 -0000 On 18 Dec, Don Lewis wrote: > Something that looks odd to me is that it appears that > aic_terminate_recovery_thread() can be called twice in at least one > case. In ahc_free(), ahc_terminate_recovery_thread() is unconditionaly > called, and then depending on the init level, ahc_shutdown() may be > called. When the recovery thread is killed, > aic->platform_data->recovery_thread does not get cleared, so if the > first call to ahc_terminate_recovery_thread() kills the recovery thread, > the second call to ahc_terminate_recovery_thread() (from ahc_shutdown()) > will hang because the recovery thread will not be around to wake it up > the second time. > > It looks like either ahc_terminate_recovery_thread() or > aic_recovery_thread() should clear aic->platform_data->recovery_thread > when the thread exits. I was just comparing the ahc code with the ahd code and noticed that ahc_shutdown() calls ahc_terminate_recovery_thread(), but ahd_shutdown() does not call ahd_terminate_recovery_thread() ...