From owner-freebsd-amd64@FreeBSD.ORG Sat Apr 28 17:10:05 2012 Return-Path: Delivered-To: freebsd-amd64@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AB55C106566B for ; Sat, 28 Apr 2012 17:10:05 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 7F8B98FC18 for ; Sat, 28 Apr 2012 17:10:05 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.5/8.14.5) with ESMTP id q3SHA5l6043866 for ; Sat, 28 Apr 2012 17:10:05 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.5/8.14.5/Submit) id q3SHA59W043865; Sat, 28 Apr 2012 17:10:05 GMT (envelope-from gnats) Resent-Date: Sat, 28 Apr 2012 17:10:05 GMT Resent-Message-Id: <201204281710.q3SHA59W043865@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-amd64@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Dave Vasilevsky Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B141B106566C for ; Sat, 28 Apr 2012 17:04:00 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22]) by mx1.freebsd.org (Postfix) with ESMTP id 9D34B8FC0A for ; Sat, 28 Apr 2012 17:04:00 +0000 (UTC) Received: from red.freebsd.org (localhost [127.0.0.1]) by red.freebsd.org (8.14.4/8.14.4) with ESMTP id q3SH40uR025903 for ; Sat, 28 Apr 2012 17:04:00 GMT (envelope-from nobody@red.freebsd.org) Received: (from nobody@localhost) by red.freebsd.org (8.14.4/8.14.4/Submit) id q3SH405a025873; Sat, 28 Apr 2012 17:04:00 GMT (envelope-from nobody) Message-Id: <201204281704.q3SH405a025873@red.freebsd.org> Date: Sat, 28 Apr 2012 17:04:00 GMT From: Dave Vasilevsky To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 X-Mailman-Approved-At: Sat, 28 Apr 2012 19:01:44 +0000 Cc: Subject: amd64/167393: MacBook4,1 hangs on SMP boot X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 28 Apr 2012 17:10:05 -0000 >Number: 167393 >Category: amd64 >Synopsis: MacBook4,1 hangs on SMP boot >Confidential: no >Severity: serious >Priority: low >Responsible: freebsd-amd64 >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sat Apr 28 17:10:04 UTC 2012 >Closed-Date: >Last-Modified: >Originator: Dave Vasilevsky >Release: 9.0-RELEASE >Organization: >Environment: FreeBSD anzio 9.0-RELEASE FreeBSD 9.0-RELEASE #0: Tue Jan 3 07:46:30 UTC 2012 root@farrell.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC amd64 >Description: Kernel hangs early in boot just after printing "ACPI APIC Table: ", and a few seconds later starts printing something so quickly I can't read it. Boot process does not continue. This sounds similar to bug 151385, but it's hard to tell if it's the same, and that bug is with an older kernel. >How-To-Repeat: Start up a MacBook4,1 from the FreeBSD-9.0-RELEASE-amd64-dvd1 DVD, observe that boot hangs and doesn't continue. Booting from an already installed FreeBSD 9.0 system will also produce this bug. >Fix: Turning off SMP (setting kern.smp.disabled=1 in loader) causes the bug to go away. This is how I was able to test an installed system. Losing use of the second CPU is non-optimal, though. Alternatively, patching sys/amd64/amd64/machdep.c to add MacBook4,1 to the LEGACY_USB_EN blacklist makes the bug go away too. I haven't noticed any negative side effects. However, if I boot using grub2 instead of loader(8), the bug still manifests, even with this patch. Patch attached with submission follows: --- sys/amd64/amd64/machdep.c.bak 2012-04-22 08:54:09.236707582 -0400 +++ sys/amd64/amd64/machdep.c 2012-04-22 08:54:33.477730871 -0400 @@ -225,6 +225,7 @@ if (sysenv != NULL) { if (strncmp(sysenv, "MacBook1,1", 10) == 0 || strncmp(sysenv, "MacBook3,1", 10) == 0 || + strncmp(sysenv, "MacBook4,1", 10) == 0 || strncmp(sysenv, "MacBookPro1,1", 13) == 0 || strncmp(sysenv, "MacBookPro1,2", 13) == 0 || strncmp(sysenv, "MacBookPro3,1", 13) == 0 || >Release-Note: >Audit-Trail: >Unformatted: