-/* $OpenBSD: locore.s,v 1.53 2023/12/06 06:15:33 miod Exp $ */
+/* $OpenBSD: locore.s,v 1.54 2023/12/10 16:56:01 deraadt Exp $ */
/* $NetBSD: locore.s,v 1.94 2001/04/26 03:10:44 ross Exp $ */
/*-
ldq a0, 0(sp) /* get the sigcontext pointer */
lda sp, 16(sp)
ldiq v0, SYS_sigreturn /* and call sigreturn() with it. */
+ .globl sigcodecall
+sigcodecall:
call_pal PAL_OSF1_callsys
.globl sigcoderet
sigcoderet:
-/* $OpenBSD: locore.S,v 1.141 2023/10/24 13:20:09 claudio Exp $ */
+/* $OpenBSD: locore.S,v 1.142 2023/12/10 16:56:01 deraadt Exp $ */
/* $NetBSD: locore.S,v 1.13 2004/03/25 18:33:17 drochner Exp $ */
/*
movq %rsp,%rdi
pushq %rdi /* fake return address */
movq $SYS_sigreturn,%rax
+ .globl sigcodecall
+sigcodecall:
syscall
.globl sigcoderet
sigcoderet:
-/* $OpenBSD: sigcode.S,v 1.12 2022/12/08 01:25:44 guenther Exp $ */
+/* $OpenBSD: sigcode.S,v 1.13 2023/12/10 16:56:01 deraadt Exp $ */
/* $NetBSD: sigcode.S,v 1.6 2003/10/05 19:44:58 matt Exp $ */
/*
/* mov r0, sp */
add r0, sp, #SIGF_SC
mov r12, #SYS_sigreturn
+ .globl sigcodecall
+sigcodecall:
swi 0
dsb nsh
isb
-/* $OpenBSD: locore.S,v 1.43 2023/01/26 13:09:18 kettenis Exp $ */
+/* $OpenBSD: locore.S,v 1.44 2023/12/10 16:56:01 deraadt Exp $ */
/*-
* Copyright (c) 2012-2014 Andrew Turner
* All rights reserved.
add x0, x0, #SF_SC
mov x8, #SYS_sigreturn
+ .globl sigcodecall
+sigcodecall:
svc 0
dsb nsh
isb
-/* $OpenBSD: locore.S,v 1.205 2023/10/24 13:20:10 claudio Exp $ */
+/* $OpenBSD: locore.S,v 1.206 2023/12/10 16:56:01 deraadt Exp $ */
/*
* Copyright (c) 1998-2004 Michael Shalayeff
ldil L%SYSCALLGATE, r1
copy r4, arg0
.call
+ .globl sigcodecall
+sigcodecall:
ble 4(sr7, r1)
- ldi SYS_sigreturn, t1
+ ldi SYS_sigreturn, t1
.globl sigcoderet
sigcoderet:
-/* $OpenBSD: locore.s,v 1.202 2023/10/24 13:20:10 claudio Exp $ */
+/* $OpenBSD: locore.s,v 1.203 2023/12/10 16:56:01 deraadt Exp $ */
/* $NetBSD: locore.s,v 1.145 1996/05/03 19:41:19 christos Exp $ */
/*-
pushl %eax
pushl %eax # junk to fake return address
movl $SYS_sigreturn,%eax
+ .globl sigcodecall
+sigcodecall:
int $0x80 # enter kernel with args on stack
.globl sigcoderet
sigcoderet:
-/* $OpenBSD: subr.S,v 1.29 2023/01/31 15:18:54 deraadt Exp $ */
+/* $OpenBSD: subr.S,v 1.30 2023/12/10 16:56:01 deraadt Exp $ */
/*
* Mach Operating System
* Copyright (c) 1993-1992 Carnegie Mellon University
GLOBAL(sigcode) /* r31 points to sigframe */
ld %r2, %r31, 0 /* pick sigcontext* */
or %r13, %r0, SYS_sigreturn
+GLOBAL(sigcodecall)
GLOBAL(sigcoderet)
tb0 0, %r0, 450 /* syscall trap, calling sigreturn */
NOP | failure return
-/* $OpenBSD: locore.S,v 1.62 2023/10/24 13:20:10 claudio Exp $ */
+/* $OpenBSD: locore.S,v 1.63 2023/12/10 16:56:01 deraadt Exp $ */
/* $NetBSD: locore.S,v 1.2 1996/10/16 19:33:09 ws Exp $ */
/*
lfd %f13,104(%r6)
addi %r3,%r1,((16+FPSIG_SIZEOF+15)&~0xf)+SF_SC /* compute &sf_sc */
li %r0,SYS_sigreturn
+ .globl sigcodecall
+sigcodecall:
sc /* sigreturn(scp) */
.globl sigcoderet
sigcoderet:
-/* $OpenBSD: lcore_access.S,v 1.34 2023/01/31 15:18:55 deraadt Exp $ */
+/* $OpenBSD: lcore_access.S,v 1.35 2023/12/10 16:56:01 deraadt Exp $ */
/*
* Copyright (c) 2001-2003 Opsycon AB (www.opsycon.se / www.opsycon.com)
sigcode:
PTR_ADDU a0, sp, 4*REGSZ # address of sigcontext
LI v0, SYS_sigreturn # sigreturn(scp)
+ .globl sigcodecall
+sigcodecall:
syscall
.globl sigcoderet
sigcoderet:
-/* $OpenBSD: locore.S,v 1.46 2023/10/24 13:20:10 claudio Exp $ */
+/* $OpenBSD: locore.S,v 1.47 2023/12/10 16:56:01 deraadt Exp $ */
/*
* Copyright (c) 2020 Mark Kettenis <kettenis@openbsd.org>
.rodata
.globl sigcode
- .globl sigcoderet
sigcode:
addi %r1, %r1, -32
mtctr %r12
bctrl
addi %r3, %r1, 32+SF_SC
li %r0, SYS_sigreturn
+ .globl sigcodecall
+sigcodecall:
sc
+ .globl sigcoderet
sigcoderet:
li %r0, SYS_exit
sc
-/* $OpenBSD: locore.S,v 1.15 2022/12/02 12:27:08 jca Exp $ */
+/* $OpenBSD: locore.S,v 1.16 2023/12/10 16:56:02 deraadt Exp $ */
/*-
* Copyright (c) 2015-2018 Ruslan Bukin <br@bsdpad.com>
mv a0, sp
addi a0, a0, SF_SC
li t0, SYS_sigreturn
+ .globl sigcodecall
+sigcodecall:
ecall
-
.globl sigcoderet
sigcoderet:
/* sigreturn failed, exit */
-/* $OpenBSD: locore_subr.S,v 1.17 2023/10/24 13:20:10 claudio Exp $ */
+/* $OpenBSD: locore_subr.S,v 1.18 2023/12/10 16:56:02 deraadt Exp $ */
/* $NetBSD: locore_subr.S,v 1.28 2006/01/23 22:52:09 uwe Exp $ */
/*
NENTRY(sigcode)
mov r15, r4 /* get pointer to sigcontext */
mov.l .L_SYS_sigreturn, r0
+ .globl sigcodecall
+sigcodecall:
trapa #0x80 /* and call sigreturn() */
.globl sigcoderet
sigcoderet:
-/* $OpenBSD: locore.s,v 1.202 2023/10/24 13:20:11 claudio Exp $ */
+/* $OpenBSD: locore.s,v 1.203 2023/12/10 16:56:02 deraadt Exp $ */
/* $NetBSD: locore.s,v 1.137 2001/08/13 06:10:10 jdolecek Exp $ */
/*
! andn %o0, 0x0f, %o0
.globl sigcoderet
sigcoderet:
+ .globl sigcodecall
+sigcodecall:
t ST_SYSCALL ! sigreturn(scp)
! sigreturn does not return unless it fails
mov SYS_exit, %g1 ! exit(errno)