From owner-freebsd-current@FreeBSD.ORG Mon Nov 17 00:34:40 2014 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 7F469673; Mon, 17 Nov 2014 00:34:40 +0000 (UTC) Received: from mail-wi0-x231.google.com (mail-wi0-x231.google.com [IPv6:2a00:1450:400c:c05::231]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 1EEF5FC5; Mon, 17 Nov 2014 00:34:40 +0000 (UTC) Received: by mail-wi0-f177.google.com with SMTP id l15so7490357wiw.10 for ; Sun, 16 Nov 2014 16:34:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date:message-id:subject :from:to:cc:content-type; bh=nOXW/sPHYGV/g6ZAG6+BlGxMmgeucdoiM69ByrpkUzY=; b=unFwvpaf2tv17Vama7ap8udGusBPfFfgozofwH2dxeEd+Tb6DqpuggRErYhDMgWK0R bRevz+nYnZLSVhP3je7rijxLl8zVqzgle+rTmv4YfaCjYi+p6Hm2CVc5q0CiF/SkCwXg W7HlPrvXIxvlSlWluE2KXaRWXJ1X34Kn2gCBMH5RNIGtlEGXPLCEpmi/G7dHiNtQXHry ayf693vN1VePiXo3LFwSG1ICR6BNwD2vlL9TlohFDRVpVyTePATUC3OoVgD5CzqQ9oWe 206xEvDohlKt4AgqE2gVDaXPCLqDBxjlGM7wQ3nFs3C1ZQTTy1gLK8YSbH/0KleLjTmy GNXQ== MIME-Version: 1.0 X-Received: by 10.194.71.84 with SMTP id s20mr135529wju.128.1416184478285; Sun, 16 Nov 2014 16:34:38 -0800 (PST) Sender: adrian.chadd@gmail.com Received: by 10.216.106.136 with HTTP; Sun, 16 Nov 2014 16:34:38 -0800 (PST) In-Reply-To: <5468FBFB.1090208@selasky.org> References: <20141116175102.GA35649@troutmask.apl.washington.edu> <1416162070.4781.186.camel@revolution.hippie.lan> <1416162718.4781.192.camel@revolution.hippie.lan> <4F3B4E02-0ADD-46EB-BB90-BF360E810585@FreeBSD.org> <20141116185141.GB36021@troutmask.apl.washington.edu> <4443FEFB-17F1-4516-959F-4C70AB2A4382@FreeBSD.org> <20141116190344.GC36021@troutmask.apl.washington.edu> <5468F814.6010702@selasky.org> <20141116192959.GB36339@troutmask.apl.washington.edu> <5468FBFB.1090208@selasky.org> Date: Sun, 16 Nov 2014 16:34:38 -0800 X-Google-Sender-Auth: -8sX4G8oYPbfkl9JMGdkOU4LN40 Message-ID: Subject: Re: USB locks up system -- WAS Re: shutdown or acpi problem From: Adrian Chadd To: Hans Petter Selasky Content-Type: text/plain; charset=UTF-8 Cc: Dag-Erling Sm?rgrav , freebsd-current , Ian Lepore , Steve Kargl X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.18-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: Mon, 17 Nov 2014 00:34:40 -0000 ... or since you can ssh into the thing, try as root: procstat -ka -adrian On 16 November 2014 11:33, Hans Petter Selasky wrote: > On 11/16/14 20:29, Steve Kargl wrote: >> >> On Sun, Nov 16, 2014 at 08:16:36PM +0100, Hans Petter Selasky wrote: >>> >>> On 11/16/14 20:03, Steve Kargl wrote: >>>> >>>> On Sun, Nov 16, 2014 at 06:55:53PM +0000, Mark R V Murray wrote: >>>>> >>>>> >>>>>> On 16 Nov 2014, at 18:51, Steve Kargl >>>>>> wrote: >>>>>> >>>>>> If you have not read the entire thread, once the laptop keyboard and >>>>>> video output lock up, I can ssh into the laptop. If I run usbconfig, >>>>>> it hangs, ^T tells me it is stuck in SX Lock, and the /dev/da0* >>>>>> devices >>>>>> have not been destroyed. >>>>> >>>>> >>>>> Weirder and weirder :-(. >>>>> >>>>> Something with SX locks? Hmm. I do use those for attach and detach for >>>>> RNG sources. Could it be that that stick of yours is somehow getting >>>>> involved in the RNG source locks? >>>>> >>>> >>>> It's not limited to a single usb device. Plugging in/Unplugging >>>> a logitech mouse dongle, the memstick, a Western Digital MY Passport >>>> external usb hard drive, all lead to the locked keyboard and video. >>>> >>>> I tried adding both RANDOM_DEBUG and USBDEBUG to the kernel, but the >>>> mount of output is mind numbing. >>>> >>> >>> >>> Can you enter kgdb when the usbconfig is froozen, and backtrace all >>> kernel threads. You should see exactly what locks are the problem. >>> >>> Maybe some lock didn't get properly unlocked! >>> >> >> I haven't tried kgdb. I did try to attach gdb to the usbconfig >> process via its pid, but gdb dumped core. >> >> I haven't looked at locks in kgdb, what command or commands should >> I try. >> >> > > Hi, > > You enter: > > thread apply all bt > > That will give you the backtrace of all threads. Grep for usbconfig, and > figure out which line is causing the problem in the kernel. Then look at the > USB explore threads and see where they are stuck in the detach of umass! > > --HPS