From owner-freebsd-current@FreeBSD.ORG Tue Aug 18 13:04:28 2009 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 18978106568B; Tue, 18 Aug 2009 13:04:28 +0000 (UTC) (envelope-from andy@fud.org.nz) Received: from mail-vw0-f180.google.com (mail-vw0-f180.google.com [209.85.212.180]) by mx1.freebsd.org (Postfix) with ESMTP id B79938FC3D; Tue, 18 Aug 2009 13:04:27 +0000 (UTC) Received: by vws10 with SMTP id 10so3083183vws.7 for ; Tue, 18 Aug 2009 06:04:27 -0700 (PDT) MIME-Version: 1.0 Received: by 10.220.42.143 with SMTP id s15mr6282984vce.116.1250600667002; Tue, 18 Aug 2009 06:04:27 -0700 (PDT) Date: Tue, 18 Aug 2009 06:04:26 -0700 Message-ID: <1280352d0908180604s6b3bf050l9bde52f3c57a5a75@mail.gmail.com> From: Andrew Thompson To: Attilio Rao Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Mailman-Approved-At: Tue, 18 Aug 2009 13:29:30 +0000 Cc: current , Hans Petter Selasky Subject: USB newbus livelock X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 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: Tue, 18 Aug 2009 13:04:28 -0000 Hi Attilio, At the moment usb controller modules can not be unloaded due to a newbus locking problem, roughly... # kldunload ehci syscall() driver_module_handler() --> newbus xlock (subr_bus.c:4127) usb_detach() usb_proc_mwait() <- wakeup, detach and drain the usb thread [usb thread, detaching...] usb_bus_detach() --> newbus xlock (livelock, the kldunload process has this) Hans has made some changes WRT this, perforce changes 167093 and possibly 167087. Do you want to review this or maybe go for a similar fix? cheers, Andrew