kernel load fix (Ralf Baechle)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1467 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
bc9ed47b12
commit
de12d6369b
@ -257,8 +257,9 @@ void mips_r4k_init (int ram_size, int vga_ram_size, int boot_device,
|
|||||||
if (linux_boot) {
|
if (linux_boot) {
|
||||||
kernel_base = KERNEL_LOAD_ADDR;
|
kernel_base = KERNEL_LOAD_ADDR;
|
||||||
/* now we can load the kernel */
|
/* now we can load the kernel */
|
||||||
kernel_size = load_image(kernel_filename, phys_ram_base + kernel_base);
|
kernel_size = load_image(kernel_filename,
|
||||||
if (kernel_size < 0) {
|
phys_ram_base + (kernel_base - 0x80000000));
|
||||||
|
if (kernel_size == (target_ulong) -1) {
|
||||||
fprintf(stderr, "qemu: could not load kernel '%s'\n",
|
fprintf(stderr, "qemu: could not load kernel '%s'\n",
|
||||||
kernel_filename);
|
kernel_filename);
|
||||||
exit(1);
|
exit(1);
|
||||||
@ -268,7 +269,7 @@ void mips_r4k_init (int ram_size, int vga_ram_size, int boot_device,
|
|||||||
initrd_base = INITRD_LOAD_ADDR;
|
initrd_base = INITRD_LOAD_ADDR;
|
||||||
initrd_size = load_image(initrd_filename,
|
initrd_size = load_image(initrd_filename,
|
||||||
phys_ram_base + initrd_base);
|
phys_ram_base + initrd_base);
|
||||||
if (initrd_size < 0) {
|
if (initrd_size == (target_ulong) -1) {
|
||||||
fprintf(stderr, "qemu: could not load initial ram disk '%s'\n",
|
fprintf(stderr, "qemu: could not load initial ram disk '%s'\n",
|
||||||
initrd_filename);
|
initrd_filename);
|
||||||
exit(1);
|
exit(1);
|
||||||
|
Loading…
Reference in New Issue
Block a user