__sigtramp2.S revision 1.1 1 1.1 skd /* $NetBSD: __sigtramp2.S,v 1.1 2003/10/07 17:08:07 skd Exp $ */
2 1.1 skd
3 1.1 skd /*
4 1.1 skd * Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
5 1.1 skd * All rights reserved.
6 1.1 skd *
7 1.1 skd * Author: Chris G. Demetriou
8 1.1 skd *
9 1.1 skd * Permission to use, copy, modify and distribute this software and
10 1.1 skd * its documentation is hereby granted, provided that both the copyright
11 1.1 skd * notice and this permission notice appear in all copies of the
12 1.1 skd * software, derivative works or modified versions, and any portions
13 1.1 skd * thereof, and that both notices appear in supporting documentation.
14 1.1 skd *
15 1.1 skd * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
16 1.1 skd * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND
17 1.1 skd * FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
18 1.1 skd *
19 1.1 skd * Carnegie Mellon requests users of this software to return to
20 1.1 skd *
21 1.1 skd * Software Distribution Coordinator or Software.Distribution (at) CS.CMU.EDU
22 1.1 skd * School of Computer Science
23 1.1 skd * Carnegie Mellon University
24 1.1 skd * Pittsburgh PA 15213-3890
25 1.1 skd *
26 1.1 skd * any improvements or extensions that they make and grant Carnegie the
27 1.1 skd * rights to redistribute these changes.
28 1.1 skd */
29 1.1 skd
30 1.1 skd #include "SYS.h"
31 1.1 skd
32 1.1 skd /*
33 1.1 skd * The Alpha signal trampoline is invoked only to return from
34 1.1 skd * the signal; the kernel calls the signal handler directly.
35 1.1 skd *
36 1.1 skd * On entry, the stack looks like:
37 1.1 skd *
38 1.1 skd * ucontext structure [128] == sp + sizeof(siginfo_t)]
39 1.1 skd * sp-> siginfo structure [0]
40 1.1 skd */
41 1.1 skd NESTED_NOPROFILE(__sigtramp_siginfo_2,0,0,ra,0,0)
42 1.1 skd lda a0,(128)(sp) /* get pointer to ucontext */
43 1.1 skd CALLSYS_NOERROR(setcontext) /* and call setcontext() with it */
44 1.1 skd mov v0, a0 /* if that failed, get error code */
45 1.1 skd CALLSYS_NOERROR(exit) /* and call exit() with it */
46 1.1 skd END(__sigtramp_siginfo_2)
47