diff options
author | obrien <obrien@FreeBSD.org> | 2000-09-06 18:26:29 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2000-09-06 18:26:29 +0000 |
commit | 007386c316e52563bf632587c6713b8ca8891e2c (patch) | |
tree | 3d0ccbd566cce100440e13938bc748e92aa4dcee /sys | |
parent | 748554442d0ac4467fdac2ce9d42006588fd4481 (diff) | |
download | FreeBSD-src-007386c316e52563bf632587c6713b8ca8891e2c.zip FreeBSD-src-007386c316e52563bf632587c6713b8ca8891e2c.tar.gz |
Add the AlphaLinux locore support.
Submitted by: gallatin
Diffstat (limited to 'sys')
-rw-r--r-- | sys/alpha/linux/linux_locore.s | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/sys/alpha/linux/linux_locore.s b/sys/alpha/linux/linux_locore.s new file mode 100644 index 0000000..af37a2a --- /dev/null +++ b/sys/alpha/linux/linux_locore.s @@ -0,0 +1,50 @@ +/* $FreeBSD$ */ + +#include <machine/asm.h> +#include <alpha/linux/linux_syscall.h> + + +/* + * Signal "trampoline" code. Invoked from RTE setup by sendsig(). + * + * On entry, stack & registers look like: + * + * a0 signal number + * a1 pointer to siginfo_t + * a2 pointer to signal context frame (scp) + * a3 address of handler + * sp+0 saved hardware state + * . + * . + * scp+0 beginning of signal context frame + */ + +/* + * System call glue. + */ +#define LINUX_SYSCALLNUM(name) \ + ___CONCAT(LINUX_SYS_,name) + +#define LINUX_CALLSYS_NOERROR(name) \ + ldiq v0, LINUX_SYSCALLNUM(name); \ + call_pal PAL_OSF1_callsys + + + +NESTED(linux_sigcode,0,0,ra,0,0) + lda sp, -16(sp) /* save the sigcontext pointer */ + stq a2, 0(sp) + jsr ra, (t12) /* call the signal handler (t12==pv) */ + ldq a0, 0(sp) /* get the sigcontext pointer */ + lda sp, 16(sp) + /* and call sigreturn() with it. */ + LINUX_CALLSYS_NOERROR(osf1_sigreturn) + mov v0, a0 /* if that failed, get error code */ + LINUX_CALLSYS_NOERROR(exit) /* and call exit() with it. */ +XNESTED(linux_esigcode,0) + END(linux_sigcode) + + .data + EXPORT(linux_szsigcode) + .quad linux_esigcode-linux_sigcode + .text |