From owner-freebsd-current@FreeBSD.ORG Mon Nov 28 22:21:09 2011 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A94851065670 for ; Mon, 28 Nov 2011 22:21:09 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from cyrus.watson.org (cyrus.watson.org [65.122.17.42]) by mx1.freebsd.org (Postfix) with ESMTP id 7F0848FC19 for ; Mon, 28 Nov 2011 22:21:09 +0000 (UTC) Received: from bigwig.baldwin.cx (bigwig.baldwin.cx [96.47.65.170]) by cyrus.watson.org (Postfix) with ESMTPSA id 19EFE46B0D; Mon, 28 Nov 2011 17:21:09 -0500 (EST) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 930B7B93A; Mon, 28 Nov 2011 17:21:08 -0500 (EST) From: John Baldwin To: John Nielsen Date: Mon, 28 Nov 2011 17:20:43 -0500 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p8; KDE/4.5.5; amd64; ; ) References: <848DEEC1-570F-43F8-B432-A34F81014CD0@jnielsen.net> <201111221026.23015.jhb@freebsd.org> <929879BF-521C-43A1-8D63-DF2B04B6D013@jnielsen.net> In-Reply-To: <929879BF-521C-43A1-8D63-DF2B04B6D013@jnielsen.net> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201111281720.44003.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Mon, 28 Nov 2011 17:21:08 -0500 (EST) Cc: "freebsd-current@freebsd.org" Subject: Re: loader crash / BTX halted on 9.0-RC2 DVD with AMD pseudo-RAID X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 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, 28 Nov 2011 22:21:09 -0000 On Tuesday, November 22, 2011 10:07:52 pm John Nielsen wrote: > On Nov 22, 2011, at 10:26 AM, John Baldwin wrote: > > > On Monday, November 21, 2011 1:45:36 pm John Nielsen wrote: > >> This weekend I downloaded the Freebsd 9.0 RC2 amd64 ISO image and burned it > > to a DVD. I have a computer that currently runs Windows 7 but I plan to > > install FreeBSD on it in the near future so I booted it up from the DVD to > > check the hardware/driver status. Much to my dismay, the boot loader crashed > > right away (register dump followed by "BTX halted") and the computer > > immediately rebooted. I took a video with my phone so I could capture the > > crash message, screenshot here: > >> > >> http://picpaste.com/pics/BTXcrash.1321899682.jpg > >> > >> I then tried tweaking a few BIOS settings and found that turning off the > > built-in pseudo-RAID allowed the DVD to boot normally. I changed the SATA type > > from "RAID" to "AHCI". Fortunately I plan to use the controller in AHCI mode > > for the FreeBSD installation so this won't end up being a problem for me, but > > I still thought it was worth reporting. > > > > Hmmm, so this is odd. It died with an Invalid TSS exception on the iret > > instruction at the end of the return-from-real-mode trampoline in BTX. > > Looking at the dump I noticed that PSL_NT is set in %eflags, so for some > > reason the iret was trying to do a nested task return. We shouldn't let > > that flag leak out of any real mode code. Try this patch perhaps: > > Thanks for looking! > > I put gptboot on a USB stick and tried it with and without the patch. > Identical behavior in both cases to booting from the DVD (only faster)--BTX > dump and an instant reboot. I didn't do a screen capture yet but will be > happy to tomorrow if it will help. A screen capture would be useful. It may be that I did not fix the right copy of the flags. -- John Baldwin