diff options
author | royger <royger@FreeBSD.org> | 2015-01-17 08:09:07 +0000 |
---|---|---|
committer | royger <royger@FreeBSD.org> | 2015-01-17 08:09:07 +0000 |
commit | fa28f09bfa9f78bcc18ebab87f8c647efe5241f5 (patch) | |
tree | f0c469ce032ef4652316b8db5aa9fc4369d0e38f | |
parent | 8a3014856982027d81011ccd46c7d767a4514a4e (diff) | |
download | FreeBSD-src-fa28f09bfa9f78bcc18ebab87f8c647efe5241f5.zip FreeBSD-src-fa28f09bfa9f78bcc18ebab87f8c647efe5241f5.tar.gz |
loader: use correct types for parse_modmetadata
Use the proper types in parse_modmetadata for the p_start and p_end
parameters. This was causing problems in the ARM 32bit loader.
Sponsored by: Citrix Systems R&D
Reported and Tested by: ian
-rw-r--r-- | sys/boot/common/load_elf.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/boot/common/load_elf.c b/sys/boot/common/load_elf.c index 6860815..4c801e9 100644 --- a/sys/boot/common/load_elf.c +++ b/sys/boot/common/load_elf.c @@ -77,7 +77,7 @@ static int __elfN(lookup_symbol)(struct preloaded_file *mp, elf_file_t ef, const static int __elfN(reloc_ptr)(struct preloaded_file *mp, elf_file_t ef, Elf_Addr p, void *val, size_t len); static int __elfN(parse_modmetadata)(struct preloaded_file *mp, elf_file_t ef, - u_int64_t p_start, u_int64_t p_end); + Elf_Addr p_start, Elf_Addr p_end); static symaddr_fn __elfN(symaddr); static char *fake_modname(const char *name); @@ -300,7 +300,7 @@ __elfN(loadimage)(struct preloaded_file *fp, elf_file_t ef, u_int64_t off) Elf_Size size; u_int fpcopy; Elf_Sym sym; - u_int64_t p_start, p_end; + Elf_Addr p_start, p_end; dp = NULL; shdr = NULL; @@ -712,7 +712,7 @@ __elfN(load_modmetadata)(struct preloaded_file *fp, u_int64_t dest) Elf_Shdr *sh_data[2]; char *shstrtab = NULL; size_t size; - u_int64_t p_start, p_end; + Elf_Addr p_start, p_end; bzero(&ef, sizeof(struct elf_file)); ef.fd = -1; @@ -820,7 +820,7 @@ out: int __elfN(parse_modmetadata)(struct preloaded_file *fp, elf_file_t ef, - u_int64_t p_start, u_int64_t p_end) + Elf_Addr p_start, Elf_Addr p_end) { struct mod_metadata md; #if (defined(__i386__) || defined(__powerpc__)) && __ELF_WORD_SIZE == 64 |