From owner-cvs-src@FreeBSD.ORG Tue Feb 20 18:00:04 2007 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C9A6716A76C; Tue, 20 Feb 2007 18:00:04 +0000 (UTC) (envelope-from rizzo@icir.org) Received: from xorpc.icir.org (xorpc.icir.org [192.150.187.68]) by mx1.freebsd.org (Postfix) with ESMTP id 8B97E13C46B; Tue, 20 Feb 2007 18:00:00 +0000 (UTC) (envelope-from rizzo@icir.org) Received: from xorpc.icir.org (localhost [127.0.0.1]) by xorpc.icir.org (8.12.11/8.13.6) with ESMTP id l1KHfVUq076770; Tue, 20 Feb 2007 09:41:31 -0800 (PST) (envelope-from rizzo@xorpc.icir.org) Received: (from rizzo@localhost) by xorpc.icir.org (8.12.11/8.12.3/Submit) id l1KHfVQI076769; Tue, 20 Feb 2007 09:41:31 -0800 (PST) (envelope-from rizzo) Date: Tue, 20 Feb 2007 09:41:31 -0800 From: Luigi Rizzo To: Sam Leffler Message-ID: <20070220094131.A76388@xorpc.icir.org> References: <200702201545.l1KFjxF8052100@repoman.freebsd.org> <45DB2A80.1060404@errno.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5.1i In-Reply-To: <45DB2A80.1060404@errno.com>; from sam@errno.com on Tue, Feb 20, 2007 at 09:06:08AM -0800 Cc: cvs-src@FreeBSD.org, Luigi Rizzo , src-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/dev/iwi if_iwi.c if_iwivar.h X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Feb 2007 18:00:04 -0000 On Tue, Feb 20, 2007 at 09:06:08AM -0800, Sam Leffler wrote: > Luigi Rizzo wrote: > > > + add debugging code IWI_LOCK_ASSERT() to detect missing locks. > > These only do a printf, and should go away once we figure out why > > the driver sometimes freezes the system due to a (yet unidentified) > > race condition. > > LOCK_ASSERT should do a mtx_assert and not printf. If you want to > diverge from existing convention in all other drivers please use a > different name; e.g. IWI_LOCK_CHECK. done, thanks for pointing it out. > > + add a device_printf() in iwi_ioctl() in certain conditions > > (see comment in the code). This helps preventing the race condition > > mentioned above, and makes the system survive. This printf will > > also go away once fixing this bug is completed. > > Please don't commit debug stuff like this; we've discussed this Also replaced with better code to address the problem. > privately. This driver has been in use for many months w/o complaints > of the sort you are seeing. The fact that I am the only one seeing (or reporting) the problem does not mean that there is no bug (or i wouldn't spend so much time trying to fix it :). cheers luigi