aboutsummaryrefslogtreecommitdiff
path: root/src/elf.c
diff options
context:
space:
mode:
authorKimplul <kimi.h.kuparinen@gmail.com>2024-07-06 23:37:11 +0300
committerKimplul <kimi.h.kuparinen@gmail.com>2024-07-06 23:37:11 +0300
commit3fedbb6e1f849c5e0a4033d68201d60c2fc48121 (patch)
treebd219cef69a19938ecf453c3c3bb76fc13bd31a9 /src/elf.c
parent3528f88fc36df6964c0efed784ae223cfe93544e (diff)
downloadkmi-3fedbb6e1f849c5e0a4033d68201d60c2fc48121.tar.gz
kmi-3fedbb6e1f849c5e0a4033d68201d60c2fc48121.zip
core bringup + various warnings
+ dbg_fdt() is apparently broken, possibly due to UB or something, but it causes some issues with optimizations enabled. Remove it temporarily
Diffstat (limited to 'src/elf.c')
-rw-r--r--src/elf.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/elf.c b/src/elf.c
index a38f3c2..9add641 100644
--- a/src/elf.c
+++ b/src/elf.c
@@ -69,6 +69,8 @@ static void __map_exec(struct tcb *t, vm_t bin, uint8_t ei_c, vm_t phstart,
if (!start)
return; /* out of memory or something */
+ info("mapped ELF section to %x\n", start);
+
uint8_t elf_flags = program_header_prop(ei_c, runner, p_flags);
uint8_t uvflags = __elf_to_uvflags(elf_flags);
@@ -108,6 +110,7 @@ static vm_t __map_dyn(struct tcb *t, vm_t bin, uint8_t ei_c, vm_t phstart,
/** \todo this path should only be taken when no PT_INTERP is defined, as
* making sure ld is loaded should be done in userspace. Maybe a bit
* hacky, I know.*/
+ return 0;
}
/**