So after much difficulty, I successfully cross-compiled a basic linux kernel for powerpc to test some big endian code. As I'm on a relatively weak machine and have to compile a relatively large code-base, I did not want an entire distribution, which is why I just compiled the raw kernel.

When I run qemu as qemu-system-ppc -kernel arch/powerpc/boot/zImage -serial stdio all I see is the "Welcome to OpenBIOS v1.1" screen. Checking stdout shows:

>> =============================================================
>> OpenBIOS 1.1 [Jul 19 2016 06:34]
>> Configuration device id QEMU version 1 machine id 2
>> CPUs: 1
>> Memory: 128M
>> UUID: 00000000-0000-0000-0000-000000000000
>> CPU type PowerPC,750
milliseconds isn't unique.
>> [ppc] Kernel already loaded (0x01000000 + 0x00186dfc) (initrd 0x00000000 + 0x00000000)
>> [ppc] Kernel command line: 

and nothing else. My suspicion is that I need to somehow create an initial ram disk. However I don't know how to do this in a cross-compiled way?

Note: I also tried adding -append "root=/dev/ram/ initrd=/bin/bash" to see if that would work, to no avail.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.