From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:47764) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TZr2M-0006kk-Jk for qemu-devel@nongnu.org; Sat, 17 Nov 2012 17:38:57 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TZr2J-0008PN-Hh for qemu-devel@nongnu.org; Sat, 17 Nov 2012 17:38:54 -0500 Received: from mail-oa0-f45.google.com ([209.85.219.45]:53016) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TZr2J-0008PF-Cq for qemu-devel@nongnu.org; Sat, 17 Nov 2012 17:38:51 -0500 Received: by mail-oa0-f45.google.com with SMTP id i18so3583987oag.4 for ; Sat, 17 Nov 2012 14:38:50 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <20121117220902.GB5632@frosties> References: <20121117175025.GA12627@frosties> <20121117220902.GB5632@frosties> Date: Sun, 18 Nov 2012 01:38:50 +0300 Message-ID: From: Max Filippov Content-Type: text/plain; charset=ISO-8859-1 Subject: Re: [Qemu-devel] Can't switch to 64bit mode at boot, how to debug? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Goswin von Brederlow Cc: qemu-devel@nongnu.org On Sun, Nov 18, 2012 at 2:09 AM, Goswin von Brederlow wrote: > On Sat, Nov 17, 2012 at 10:58:17PM +0300, Max Filippov wrote: >> On Sat, Nov 17, 2012 at 9:50 PM, Goswin von Brederlow wrote: [...] >> (gdb) b *0x100000 >> Breakpoint 1 at 0x100000 >> (gdb) c >> Continuing. > > That works, but only for addresses BEFORE where it crashes. What works, but > in no way helps (see below), it setting the breakpoint before the last > instruction and then "stepi". > > Only way that would help would be entering the monitor mode on such an error. Ok, I think I can cook a patch for that, but how are you going to use it? The issue is not reproducible with mainline qemu, neither current nor v1.1.0 [...] >> Looks like PAE support is broken. > > Yeah, any memory read just returns all zeroes. That threw me too. I had > to debug this by adding "mov $0x101000,%ebx" type instructions and then > check the contents of ebx on crash. I wagely remember this always being > broken. > > My assumption would be that I'm setting up the gdt, paging, the page tables > and such and the debug mode already tries to use them while the cpu is > still in the original mode. So the two don't agree on what is where. There's a bug related to PAE in the debug interface, I've posted a patch that should fix that: https://lists.gnu.org/archive/html/qemu-devel/2012-11/msg01635.html -- Thanks. -- Max