pass dyn instead of dynv to loader

This commit is contained in:
flysand7 2023-08-04 04:17:41 +11:00
parent 5b2d0c0c9d
commit 14c36e203e
2 changed files with 3 additions and 3 deletions

View File

@ -119,7 +119,7 @@ static void _dbg_printf(char *fmt, ...) {
va_end(args);
}
extern void loader_entry(u64 *sp, Elf64_Dyn *dynv, u64 *aux);
extern void loader_entry(u64 *sp, u64 *dyn, u64 *aux);
void _dlstart_reloc_c(u64 *sp, Elf64_Dyn *dynv) {
_dbg_print_string("Entered dynamic loader\n");
@ -266,7 +266,7 @@ void _dlstart_reloc_c(u64 *sp, Elf64_Dyn *dynv) {
}
_dbg_printf("Self-relocation finished. Entering the loader\n");
loader_entry(sp, dynv, aux);
loader_entry(sp, dyn, aux);
_syscall_exit(0);
}

View File

@ -3,7 +3,7 @@
#include <bin/elf.h>
#include "syscall.c"
void loader_entry(u64 *sp, Elf64_Dyn *dynv, u64 *aux) {
void loader_entry(u64 *sp, u64 *dynv, u64 *aux) {
char str[] = "Hello world??\n";
_syscall_write(STDOUT_FILENO, str, sizeof str);
_syscall_exit(0);