From owner-freebsd-hardware@FreeBSD.ORG Fri Mar 21 19:24:38 2008 Return-Path: Delivered-To: freebsd-hardware@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4A37B1065670 for ; Fri, 21 Mar 2008 19:24:38 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from speedfactory.net (mail.speedfactory.net [66.23.216.219]) by mx1.freebsd.org (Postfix) with ESMTP id 3A1548FC1B for ; Fri, 21 Mar 2008 19:24:36 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from server.baldwin.cx (unverified [66.23.211.162]) by speedfactory.net (SurgeMail 3.8s) with ESMTP id 236285210-1834499 for multiple; Fri, 21 Mar 2008 15:08:50 -0400 Received: from localhost.corp.yahoo.com (john@localhost [127.0.0.1]) (authenticated bits=0) by server.baldwin.cx (8.14.2/8.14.2) with ESMTP id m2LJ7UnZ029638; Fri, 21 Mar 2008 15:07:31 -0400 (EDT) (envelope-from jhb@freebsd.org) From: John Baldwin To: freebsd-hardware@freebsd.org, David Wolfskill Date: Fri, 21 Mar 2008 11:02:35 -0400 User-Agent: KMail/1.9.7 References: <20080318171434.GA49159@bunrab.catwhisker.org> <200803190917.17502.jhb@freebsd.org> <20080319204148.GZ53010@bunrab.catwhisker.org> In-Reply-To: <20080319204148.GZ53010@bunrab.catwhisker.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200803211102.35682.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH authentication, not delayed by milter-greylist-2.0.2 (server.baldwin.cx [127.0.0.1]); Fri, 21 Mar 2008 15:07:31 -0400 (EDT) X-Virus-Scanned: ClamAV 0.91.2/6316/Fri Mar 21 10:29:54 2008 on server.baldwin.cx X-Virus-Status: Clean X-Spam-Status: No, score=-4.1 required=4.2 tests=ALL_TRUSTED,AWL,BAYES_00, DATE_IN_PAST_03_06 autolearn=ham version=3.1.3 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on server.baldwin.cx Cc: Subject: Re: Dell Optiplex 755 hangs every other boot before 82801 Family Hub Interface to PCI Bridge probed X-BeenThere: freebsd-hardware@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: General discussion of FreeBSD hardware List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Mar 2008 19:24:38 -0000 On Wednesday 19 March 2008 04:41:48 pm David Wolfskill wrote: > On Wed, Mar 19, 2008 at 09:17:17AM -0400, John Baldwin wrote: > > ... > > Do a verbose boot. It might be enumerating the PCI bus when it hangs or some > > such and a verbose boot would tell us more of where it is at when it hangs. > > Other than that, you'll have to add printfs to track down exactly where it > > hangs. :-/ > > OK; I switched it to boot (verbosely) from slice 4 (HEAD/CURRENT > as of a couple weeks ago) -- figuring that there might be more > "interesting" information available that way, then ran tip(1) within > script(1) to capture the output. > > I edited the typescript file in a couple of ways: > > * I removed the ^M characters (saving about 2K in file size) > * I split the file into "console_755-hang" and "console_755-nohang" to > make comparing the results of the experiments a bit easier. In the > same spirit, I removed the beginning and ending script- and > tip-generated stuff that wasn't relevant. > > I've attached both files. > > The last bit of stuff in the "hang" case was: > > usb6: USB revision 2.0 > uhub6: on usb6 > uhub6: 6 ports with 6 removable, self powered > pcib2: at device 30.0 on pci0 > pcib2: domain 0 > pcib2: secondary bus 2 > pcib2: subordinate bus 2 > pcib2: I/O decode 0xf000-0xfff > pcib2: no prefetched decode > pcib2: Subtractively decoded bridge. > > > and in the "nohang" case, that bit was followed by: > > pci2: on pcib2 > pci2: domain=0, physical bus=2 Ok. Please apply the patch below and report back which printfs you see. > I note, too, that running diff(1) to compare the 2 files shows that the > "nohang" case is missing some curious lines that show up in the "hang" > case, e.g.: > > ioapic0: routing intpin 22 (PCI IRQ 22) to vector 53 > ehci0: [GIANT-LOCKED] > ehci0: [ITHREAD] > -usb2: waiting for BIOS to give up control > usb2: EHCI version 1.0 > usb2: wrong number of companions (3 != 2) > usb2: companion controllers, 2 ports each: usb0 usb1 > ... > ehci1: Reserved 0x400 bytes for rid 0x10 type 3 at 0xff980800 > ehci1: [GIANT-LOCKED] > ehci1: [ITHREAD] > -usb6: waiting for BIOS to give up control > -usb6: timed out waiting for BIOS > usb6: EHCI version 1.0 > usb6: companion controllers, 2 ports each: usb3 usb4 usb5 > usb6: on ehci1 This is due to the ehci(4) boot time hangs fixed in the last commit to ehci_pci.c. You can ignore it. Index: acpi_pcib.c =================================================================== RCS file: /usr/cvs/src/sys/dev/acpica/acpi_pcib.c,v retrieving revision 1.60 diff -u -r1.60 acpi_pcib.c --- acpi_pcib.c 3 Dec 2005 21:17:17 -0000 1.60 +++ acpi_pcib.c 21 Mar 2008 15:00:34 -0000 @@ -147,6 +147,7 @@ * are several valid bridges in the field that do not have a _PRT, so * only warn about missing tables if bootverbose is set. */ + device_printf(dev, "fetching _PRT\n"); prt->Length = ACPI_ALLOCATE_BUFFER; status = AcpiGetIrqRoutingTable(acpi_get_handle(dev), prt); if (ACPI_FAILURE(status) && (bootverbose || status != AE_NOT_FOUND)) @@ -157,6 +158,7 @@ /* * Attach the PCI bus proper. */ + device_printf(dev, "adding pci bus child device\n"); if ((child = device_add_child(dev, "pci", busno)) == NULL) { device_printf(device_get_parent(dev), "couldn't attach pci bus\n"); return_VALUE(ENXIO); @@ -165,8 +167,10 @@ /* * Now go scan the bus. */ + device_printf(dev, "force attaching PCI link devices found in _PRT\n"); prt_walk_table(prt, prt_attach_devices, dev); + device_printf(dev, "attaching the PCI child bus device\n"); return_VALUE (bus_generic_attach(dev)); } -- John Baldwin