From 3924b0c2475a56d000c0c5cae2ca1660a97b489b Mon Sep 17 00:00:00 2001 From: Philip Guenther Date: Sun, 20 Mar 2016 02:32:41 +0000 Subject: Rearrange C runtime bits: now that ld.so exports environ and __progname, move their definitions and initialization in static links to libc.a Make crt0 always invoke a new func _csu_finish() in libc to process the auxv and to either register the ld.so cleanup function (in dynamic links) or initialize environ and __progname and do MC_DISABLE_KBIND (in static links). In libc, get pagesize from auxv; cache that between getpagesize() and sysconf(_SC_PAGESIZE) ok mpi@ "good time" deraadt@ --- lib/csu/m88k/md_init.h | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'lib/csu/m88k') diff --git a/lib/csu/m88k/md_init.h b/lib/csu/m88k/md_init.h index a1d13552da7..0724b5c6669 100644 --- a/lib/csu/m88k/md_init.h +++ b/lib/csu/m88k/md_init.h @@ -1,4 +1,4 @@ -/* $OpenBSD: md_init.h,v 1.3 2015/09/01 05:40:06 guenther Exp $ */ +/* $OpenBSD: md_init.h,v 1.4 2016/03/20 02:32:39 guenther Exp $ */ /* * Copyright (c) 2012 Miodrag Vallat. @@ -64,12 +64,3 @@ " addu %r4, %r4, 4 \n" \ " /* envp = argv + argc + 1 */ \n" \ " .previous"); - -#include -#define MD_DISABLE_KBIND \ - do { \ - register long syscall_num __asm("r13") = SYS_kbind; \ - register void *arg1 __asm("r2") = NULL; \ - __asm volatile("tb0 0, %%r0, 450; or %%r0, %%r0, %%r0" \ - : "+r" (arg1) : "r" (syscall_num) : "r3", "cc"); \ - } while (0) -- cgit v1.2.3