Comment 2 for bug 619302

Revision history for this message
Nigel Jones (dev-nigelj) wrote :

I've done a bit of digging here:

I encounter the issue in both Lucid and Maverick.

gdb on the generated core, w/ a 'bt' shows:

<snip>
#2 0x000000000046f2c5 in oom_check (size=<value optimised out>)
    at qemu-malloc.c:30
#3 qemu_malloc (size=<value optimised out>) at qemu-malloc.c:59
#4 0x000000000044a616 in load_linux (fw_cfg=0x275e060,
    kernel_filename=<value optimised out>,
    initrd_filename=0x7fff8a0e45d5 "baabaablacksheep",
    kernel_cmdline=<value optimised out>, max_ram_size=<value optimised out>)
    at /build/buildd/qemu-kvm-0.12.3+noroms/hw/pc.c:876
<snip>

hw/pc.c:876 is an attempt to allocate memory for the size of the initrd, the function that calculates the size of the initrd returns '-1' if the file doesn't exist.

Upstream have patched it though to check for an initrd size of -1 and I'm in the process of grabbing the particular change and getting as a diff that could be applied.