[OpenBIOS] PReP PowerPC "emulation"
Mark Cave-Ayland
mark.cave-ayland at siriusit.co.uk
Wed Sep 15 11:06:44 CEST 2010
Andreas Färber wrote:
> qemu-system-ppc64 w/ either stock QEMU OpenBIOS or r862 with OSX host
> and ppc MMU patches:
>
> C>> annot manage 'OHCI USB controller' PCI device type 'usb':
> >> 106b 3f (c 3 10)
>
> >> =============================================================
> >> OpenBIOS 1.0 [Aug 17 2010 14:41]
> >> Configuration device id QEMU version 1 machine id 3
> >> CPUs: 1
> >> Memory: 128M
> >> UUID: 00000000-0000-0000-0000-000000000000
> >> CPU type PowerPC,970FX
> Welcome to OpenBIOS v1.0 built on Aug 17 2010 14:41
>
> 0 > load cd:,\ppc\chrp\bootfile.exe ok
> 0 > go No valid state has been set by load or init-program
> ok
> 0 > boot cd:,\ppc\chrp\bootfile.exe No valid state has been set by load
> or init-program
> ok
> 0 > dir cd:,\ppc\chrp
> 2048 2007-07-03 17:39:44 .\
> 2048 2007-07-03 17:32:05 ..\
> 12487680 2007-07-03 17:39:24 bootfile.exe
> ok
> 0 >
>
>
>> Also, what format is the AIX bootloader - is it an ELF executable?
>
> $ file /Volumes/CDROM/ppc/chrp/bootfile.exe
> /Volumes/CDROM/ppc/chrp/bootfile.exe: ELF 32-bit MSB executable, PowerPC
> or cisco 4500, version 1 (SYSV), statically linked, corrupted section
> header size
>
> Andreas
Right. So in the case that you see the message "No valid state has been
set by load or init-program", this means that either the load failed or
init-program failed to detect a valid ELF header for the current
architecture.
First thing to check is that the executable is being loaded from disk, e.g.
load cd:,\ppc\chrp\bootfile.exe
then dump the first 200 bytes of memory to make sure an ELF header is
present (i.e. the load from disk was successful):
load-base 200 dump
If the ELF header is present then it must be init-program which is
failing. If the ELF header is not present, you'll need to take a look in
either libopenbios/load.c and/or libopenbios/elf_load.c at elf_load()
and elf_init_program().
The one thing that I did notice is that you are attempting to launch a
PPC32 ELF file under a PPC64 Qemu, so perhaps it is the checks in
is_elf() which are failing? Try taking a look at the relevant constants
in include/arch/ppc/elf.h.
HTH,
Mark.
--
Mark Cave-Ayland - Senior Technical Architect
PostgreSQL - PostGIS
Sirius Corporation plc - control through freedom
http://www.siriusit.co.uk
t: +44 870 608 0063
Sirius Labs: http://www.siriusit.co.uk/labs
More information about the OpenBIOS
mailing list