From e477b1145f89ab8e04a77a84850c1f4b5f39068f Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Wed, 14 Oct 2020 22:11:53 +0000 Subject: use symbolic SYS_exit rather than 1, and skip using the 0x400 %g2 syscall method ok kettenis --- lib/csu/sparc64/md_init.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/csu/sparc64/md_init.h b/lib/csu/sparc64/md_init.h index 9c99a699f42..a8dc3e6e857 100644 --- a/lib/csu/sparc64/md_init.h +++ b/lib/csu/sparc64/md_init.h @@ -1,4 +1,4 @@ -/* $OpenBSD: md_init.h,v 1.7 2017/08/11 20:13:31 guenther Exp $ */ +/* $OpenBSD: md_init.h,v 1.8 2020/10/14 22:11:52 deraadt Exp $ */ /*- * Copyright (c) 2001 Ross Harvey @@ -73,7 +73,6 @@ " mov %g1, %o1 \n" \ " .previous") - #define MD_RCRT0_START \ __asm__( \ ".text \n" \ @@ -103,8 +102,7 @@ " \n" \ " .global _dl_exit \n" \ "_dl_exit: \n" \ - " mov 0x401, %g1 \n" \ - " add %o7, 8, %g2 \n" \ + " mov " STR(SYS_exit) ", %g1 \n" \ " t 0 \n" \ " retl \n" \ " sub %g0, %o0, %o0 \n" \ -- cgit v1.2.3