NetBSD Problem Report #52229

From www@NetBSD.org  Fri May 12 00:49:11 2017
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.netbsd.org", Issuer "Postmaster NetBSD.org" (verified OK))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 277A47A210
	for <gnats-bugs@gnats.NetBSD.org>; Fri, 12 May 2017 00:49:11 +0000 (UTC)
Message-Id: <20170512004910.401817A2B0@mollari.NetBSD.org>
Date: Fri, 12 May 2017 00:49:10 +0000 (UTC)
From: venture37@geeklan.co.uk
Reply-To: venture37@geeklan.co.uk
To: gnats-bugs@NetBSD.org
Subject: 11" mid-2012 MacBook Air crashes very early in boot from UEFI
X-Send-Pr-Version: www-1.0

>Number:         52229
>Category:       kern
>Synopsis:       11" mid-2012 MacBook Air crashes very early in boot from UEFI
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri May 12 00:50:00 +0000 2017
>Last-Modified:  Sat Aug 18 12:10:00 +0000 2018
>Originator:     Sevan Janiyan
>Release:        NetBSD-HEAD
>Organization:
>Environment:
>Description:
Attempting to boot the latest NetBSD-7.99.71-amd64-uefi-install.img on a MacBookAir5,1 results in a crash.
System in question has 8GB of RAM but kernel only reports 512MB

Photos of crash along with output from memmap & efivar commands can be found at 
http://www.netbsd.org/~sevan/mbp2012/
>How-To-Repeat:
Boot NetBSD-7.99.71-amd64-uefi-install.img on a 11" mid-2012 MacBook Air
>Fix:

>Audit-Trail:
From: Sevan Janiyan <venture37@geeklan.co.uk>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/52229: 11" mid-2012 MacBook Air crashes very early in boot
 from UEFI
Date: Tue, 13 Feb 2018 22:43:17 +0000

 As stated in kern/52995 (duplicate pr) and in the photos linked to in
 this PR, the kernel panics on efi_getsystbl() when booting on a Mac.

 I recompiled a kernel with options DDB_COMMANDONENTER="bt" set & tried
 booting it on a white late 2009 Macbook (mentioned in pr 52995).
 System panicked as expected and I now have a backtrace.

 vpanic()
 snprintf()
 kmem_alloc()
 AcpiUtUpdateRefCount()
 AcpiUtUpdateObjectReference()
 AcpiRsSetSrsMethodData()
 AcpiSetCurrentResources()
 acpi_pci_link_srs()
 acpi_pci_link_route_interrupt()
 mpacpi_findintr_linkdev()
 intr_find_mpmapping()
 pci_intr_map()
 ohci_pci_attach()
 config_attach_loc()
 pci_probe_device()
 pci_enumerate_bus()
 pcirescan()
 pciattach()
 config_attach_loc()
 mp_pci_scan()
 mainbus_attach()
 config_attach_loc()
 cpu_configure()
 main()

 Photo of the backtrace http://www.netbsd.org/~sevan/pr-52229.jpg


 Sevan

From: coypu@sdf.org
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/52229: 11" mid-2012 MacBook Air crashes very early in boot
 from UEFI
Date: Fri, 27 Apr 2018 09:38:41 +0000

 this might even be the same laptop as
 https://mjg59.dreamwidth.org/11235.html

 https://twitter.com/whitequark/status/989585717419372544 mentions the
 fix

From: Sevan Janiyan <venture37@geeklan.co.uk>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/52229: 11" mid-2012 MacBook Air crashes very early in boot
 from UEFI
Date: Sat, 18 Aug 2018 13:09:14 +0100

 With the update of gnu-efi this week, I thought I'd try booting today's
 daily build to see if anything had changed and it looks like they have.
 The system still blows up in efi_getsystbl but now I have a different
 message / backtrace.
 panic: kernel diagnostic assertion "va < VM_MIN_KERNEL_ADDRESS" failed:
 file "./x86/pmap.h", line 491
 cpu0: Begin traceback...
 vpanic() at netbsd:vpanic+0x16f
 ch_voltag_convert_in() at netbsd:ch_voltag_covert_in
 db_disasm() at netbsd:db_disasm+0x10b
 db_trap() at netbsd:db_trap+0xf7
 kdb_trap() at netbsd:kdb_trap+0xe2
 trap() at netbsd:trap+0x51a
 --- trap (number 6) ---
 efi_getsystbl.part.4() at netbsd:efi_getsystbl.part.4+0x4c
 efi_init() at netbsd:efi_init+0x2d
 cpu_configure() at netbsd:cpu_configure+0xe
 main() at netbsd:main+0x331
 cpu0: End trackback
 fatal breakpoint trap in supervisor mode
 trap type 1 code 0 rip 0xffffffff8021de45 cs 0x8 rflags 0x202 cr2
 0xffffec319068ee20 ilevel 0x8 rsp 0xffffffff817fc9e0
 curlwp 0xffffffff81456c40 pid 0.1 lowest kstack 0xffffffff817f82c0
 Stopped in pid 0.0 (system) at netbsd:breakpoint+0x5: leave

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.