From owner-freebsd-bugs@FreeBSD.ORG Wed Oct 29 21:48:20 2014 Return-Path: Delivered-To: freebsd-bugs@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 6C0FFA22 for ; Wed, 29 Oct 2014 21:48:20 +0000 (UTC) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4E059BE9 for ; Wed, 29 Oct 2014 21:48:20 +0000 (UTC) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.14.9/8.14.9) with ESMTP id s9TLmKFB028556 for ; Wed, 29 Oct 2014 21:48:20 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 193758] either gptzfsboot or zfsloader hangs during boot after kernel and pool upgrade Date: Wed, 29 Oct 2014 21:48:20 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: 8.4-STABLE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Many People X-Bugzilla-Who: mark@exonetric.com X-Bugzilla-Status: Needs Triage X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-bugs@FreeBSD.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Oct 2014 21:48:20 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=193758 --- Comment #7 from mark@exonetric.com --- Ok, I was looking at the difference between 8.4 and 9.2 just for the zfsboot directory. There is more to gptzfsboot than just zfsboot and I'd didn't look at all the contributions separately. $ svn diff https://svn0.eu.freebsd.org/base/releng/8.4/sys/boot/i386/zfsboot https://svn0.eu.freebsd.org/base/releng/9.2/sys/boot/i386/zfsboot Index: zfsboot.c =================================================================== --- zfsboot.c (.../8.4/sys/boot/i386/zfsboot) (revision 273837) +++ zfsboot.c (.../9.2/sys/boot/i386/zfsboot) (revision 273837) @@ -54,7 +54,7 @@ #define NOPT 14 #define NDEV 3 -#define BIOS_NUMDRIVES 0x475 +#define BIOS_NUMDRIVES 0x475 #define DRV_HARD 0x80 #define DRV_MASK 0x7f @@ -489,7 +489,12 @@ * will find any other available pools and it may fill in missing * vdevs for the boot pool. */ - for (i = 0; i < *(unsigned char *)PTOV(BIOS_NUMDRIVES); i++) { +#ifndef VIRTUALBOX + for (i = 0; i < *(unsigned char *)PTOV(BIOS_NUMDRIVES); i++) +#else + for (i = 0; i < MAXBDDEV; i++) +#endif + { if ((i | DRV_HARD) == *(uint8_t *)PTOV(ARGS)) continue; @@ -780,8 +785,10 @@ } ioctrl = OPT_CHECK(RBX_DUAL) ? (IO_SERIAL|IO_KEYBOARD) : OPT_CHECK(RBX_SERIAL) ? IO_SERIAL : IO_KEYBOARD; - if (ioctrl & IO_SERIAL) - sio_init(115200 / comspeed); + if (ioctrl & IO_SERIAL) { + if (sio_init(115200 / comspeed) != 0) + ioctrl &= ~IO_SERIAL; + } } if (c == '?') { dnode_phys_t dn; Index: Makefile =================================================================== --- Makefile (.../8.4/sys/boot/i386/zfsboot) (revision 273837) +++ Makefile (.../9.2/sys/boot/i386/zfsboot) (revision 273837) @@ -16,7 +16,6 @@ CFLAGS= -DBOOTPROG=\"zfsboot\" \ -O1 \ - -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 \ -DBOOT2 \ -DSIOPRT=${BOOT_COMCONSOLE_PORT} \ -DSIOFMT=${B2SIOFMT} \ @@ -78,7 +77,7 @@ SRCS= zfsboot.c -.if ${MACHINE_ARCH} == "amd64" +.if ${MACHINE_CPUARCH} == "amd64" beforedepend zfsboot.o: machine CLEANFILES+= machine machine: @@ -86,3 +85,7 @@ .endif .include + +# XXX: clang integrated-as doesn't grok .codeNN directives yet +CFLAGS.zfsldr.S= ${CLANG_NO_IAS} +CFLAGS+= ${CFLAGS.${.IMPSRC:T}} -- You are receiving this mail because: You are the assignee for the bug.