From 018624dd5b1692b88f7b2e85652ea7b898043b6d Mon Sep 17 00:00:00 2001 From: Kimplul Date: Tue, 24 May 2022 23:28:37 +0300 Subject: make process loading more generic --- include/arch/proc.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 include/arch/proc.h (limited to 'include/arch/proc.h') diff --git a/include/arch/proc.h b/include/arch/proc.h new file mode 100644 index 0000000..1dcb0af --- /dev/null +++ b/include/arch/proc.h @@ -0,0 +1,20 @@ +#ifndef APOS_ARCH_PROC_H +#define APOS_ARCH_PROC_H + +/** + * @file proc.h + * Arch-specific process related stuff. + */ + +#if defined(riscv64) +#include "../../arch/riscv64/include/proc.h" +#elif defined(riscv32) +#include "../../arch/riscv32/include/proc.h" +#endif + +stat_t set_return(vm_t r); +/*TODO: should this be in arch/tcb.h or something? */ +stat_t prepare_thread(struct tcb *t); +stat_t run_init(struct tcb *t, void *fdt); + +#endif /* APOS_ARCH_PROC_H */ -- cgit v1.3