Received: from eggs.gnu.org ([2001:4830:134:3::10]:55724) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VqUB1-0007bD-Kz for qemu-devel@nongnu.org; Tue, 10 Dec 2013 15:45:13 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VqUAv-00030S-GH for qemu-devel@nongnu.org; Tue, 10 Dec 2013 15:45:07 -0500 Message-ID: <52A77CE1.3060906@ilande.co.uk> Date: Tue, 10 Dec 2013 20:43:13 +0000 From: Mark Cave-Ayland MIME-Version: 1.0 References: <52A72413.9090901@ilande.co.uk> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] PPC: Regression booting NetBSD List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: "qemu-ppc@nongnu.org" , qemu-devel On 10/12/13 14:40, Peter Maydell wrote: > On 10 December 2013 14:24, Mark Cave-Ayland > wrote: >> I've been running my OpenBIOS test suite on a recent git (commit a1d22a) and >> have encountered a QEMU process segfault in 2 out of 3 of my NetBSD 5.0.2 >> boot attempts. Does anyone have an idea what could be causing this? Other >> OSs don't seem to be affected. >> >> >> build@kentang:~/rel-qemu-git/bin$ ./qemu-system-ppc -cdrom >> /home/build/src/qemu/image/ppc/macppccd-5.0.2.iso -boot d -bios >> /home/build/src/openbios/openbios-git/openbios-devel/obj-ppc/openbios-qemu.elf.nostrip >> qemu: fatal: Trying to execute code outside RAM or ROM at 0x0a64696c >> >> NIP 0a64696c LR 0a64696d CTR 00000000 XER 00000000 >> MSR 00009030 HID0 00000000 HF 00000000 idx 1 > > [etc] > > This isn't a QEMU process segfault -- it's just that the guest > has attempted to jump to a memory location which is neither > RAM nor ROM (you can see the guest NIP is the same address > the message prints). This is probably because something has > gone wrong some distance further back in guest execution; > identifying exactly what that was might require some tedious > debugging :-) Well after some fiddling today, it seems that subtle changes in the memory layout between different revisions of OpenBIOS cause NetBSD to crash with the default 128M of RAM provided by QEMU. With 256M specified on the command line then everything works as before. My guess is that in the case where QEMU doesn't crash, we're just lucky in that whatever memory corruption is occurring doesn't manage to trigger the assertion in the emulator. ATB, Mark.