search for: mbh_len

Displaying 3 results from an estimated 3 matches for "mbh_len".

Did you mean: bv_len
2009 Oct 12
1
com32/mboot/map.c question
Hello, I get the following message while loading my multiboot kernel with mboot.c32: "Invalid Multiboot image: neither ELF header nor a.out kludge found". I checked the code and came across this (com32/mboot/map.c line 130) : if (i + mbh_len < len) mbh_len = 0; /* Invalid... */ else break; /* Found something... */ } Shouldn't it be "if (i + mbh_len >= len)" ? With this change my kernel is being loaded properly. Best regards, KlausT
2015 Oct 10
3
[PATCH] Extend Multiboot1 with support for ELF64 file format
...No valid ELF64 header found */ + /* Is this a Solaris kernel? */ if (!set.solaris && eh && kernel_is_solaris(eh)) opt.solaris = true; @@ -263,6 +279,112 @@ return NULL; } sh[i].sh_addr = addr; + } + } + } else if (eh64 && !(opt.aout && mbh_len && + (mbh->flags & MULTIBOOT_AOUT_KLUDGE))) { + /* Load 64-bit ELF */ + regs.eip = eh64->e_entry; /* Can be overridden further down... */ + + ph64 = (Elf64_Phdr *) (cptr + eh64->e_phoff); + + for (i = 0; i < eh64->e_phnum; i++) { + if (ph64->p_type == PT_...
2015 Oct 10
2
[PATCH 2/2] com32/mboot/map.c: removed trailing spaces
...diff --git a/com32/mboot/map.c b/com32/mboot/map.c index 2e8641f..1992f14 100644 --- a/com32/mboot/map.c +++ b/com32/mboot/map.c @@ -281,7 +281,7 @@ struct multiboot_header *map_image(void *ptr, size_t len) sh[i].sh_addr = addr; } } - } else if (eh64 && !(opt.aout && mbh_len && + } else if (eh64 && !(opt.aout && mbh_len && (mbh->flags & MULTIBOOT_AOUT_KLUDGE))) { /* Load 64-bit ELF */ regs.eip = eh64->e_entry; /* Can be overridden further down... */ @@ -378,7 +378,7 @@ struct multiboot_header *map_image(void...