Commit 72742c8626a9a25dd707a4c76583cd9c9faa5942

Authored by pbrook
1 parent adb47967

ARM boot fix (Jason Wessel).


git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2323 c046a42c-6fe2-441c-8c8c-71466251a162
Showing 1 changed file with 2 additions and 2 deletions
hw/arm_boot.c
... ... @@ -80,12 +80,12 @@ void arm_load_kernel(CPUState *env, int ram_size, const char *kernel_filename,
80 80 }
81 81  
82 82 kernel_size = load_elf(kernel_filename, 0, &entry);
83   - if (kernel_size) {
  83 + if (kernel_size >= 0) {
84 84 /* An ELF image. Jump to the entry point. */
85 85 env->regs[15] = entry & 0xfffffffe;
86 86 env->thumb = entry & 1;
87 87 } else {
88   - /* Raw binary image. Assume it is a Limux zImage. */
  88 + /* Raw binary image. Assume it is a Linux zImage. */
89 89 kernel_size = load_image(kernel_filename,
90 90 phys_ram_base + KERNEL_LOAD_ADDR);
91 91 if (kernel_size < 0) {
... ...