diff options
author | Warner Losh <imp@FreeBSD.org> | 2021-08-03 17:17:17 -0600 |
---|---|---|
committer | Warner Losh <imp@bsdimp.com> | 2021-09-10 14:13:06 -0600 |
commit | e2a74729181c51a0c9dff03bb7a99fc267bec996 (patch) | |
tree | 27c763a4ccfde547b31c508a45e6baaabce84ac9 /bsd-user/main.c | |
parent | 01a298a57ed3cd1fefbe70c691d74247c8f84906 (diff) |
bsd-user: start to move target CPU functions to target_arch*
Move the CPU functions into target_arch_cpu.c that are unique to each
CPU. These are defined in target_arch.h.
Signed-off-by: Stacey Son <sson@FreeBSD.org>
Signed-off-by: Warner Losh <imp@bsdimp.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'bsd-user/main.c')
-rw-r--r-- | bsd-user/main.c | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/bsd-user/main.c b/bsd-user/main.c index d7c8a3e348..f7c75df64d 100644 --- a/bsd-user/main.c +++ b/bsd-user/main.c @@ -72,13 +72,6 @@ void gemu_log(const char *fmt, ...) va_end(ap); } -#if defined(TARGET_I386) -int cpu_get_pic_interrupt(CPUX86State *env) -{ - return -1; -} -#endif - void fork_start(void) { } @@ -94,11 +87,6 @@ void fork_end(int child) /***********************************************************/ /* CPUX86 core interface */ -uint64_t cpu_get_tsc(CPUX86State *env) -{ - return cpu_get_host_ticks(); -} - static void write_dt(void *ptr, unsigned long addr, unsigned long limit, int flags) { @@ -570,29 +558,6 @@ int main(int argc, char **argv) */ guest_base = HOST_PAGE_ALIGN(guest_base); - /* - * Read in mmap_min_addr kernel parameter. This value is used - * When loading the ELF image to determine whether guest_base - * is needed. - * - * When user has explicitly set the quest base, we skip this - * test. - */ - if (!have_guest_base) { - FILE *fp; - - fp = fopen("/proc/sys/vm/mmap_min_addr", "r"); - if (fp != NULL) { - unsigned long tmp; - if (fscanf(fp, "%lu", &tmp) == 1) { - mmap_min_addr = tmp; - qemu_log_mask(CPU_LOG_PAGE, "host mmap_min_addr=0x%lx\n", - mmap_min_addr); - } - fclose(fp); - } - } - if (loader_exec(filename, argv + optind, target_environ, regs, info, &bprm) != 0) { printf("Error loading %s\n", filename); |