Home | History | Annotate | Line # | Download | only in i386
linux_signal.h revision 1.5
      1  1.5  mycroft /* 	$NetBSD: linux_signal.h,v 1.5 1998/09/11 12:50:09 mycroft Exp $	*/
      2  1.1     fvdl 
      3  1.1     fvdl /*
      4  1.1     fvdl  * Copyright (c) 1995 Frank van der Linden
      5  1.1     fvdl  * All rights reserved.
      6  1.1     fvdl  *
      7  1.1     fvdl  * Redistribution and use in source and binary forms, with or without
      8  1.1     fvdl  * modification, are permitted provided that the following conditions
      9  1.1     fvdl  * are met:
     10  1.1     fvdl  * 1. Redistributions of source code must retain the above copyright
     11  1.1     fvdl  *    notice, this list of conditions and the following disclaimer.
     12  1.1     fvdl  * 2. Redistributions in binary form must reproduce the above copyright
     13  1.1     fvdl  *    notice, this list of conditions and the following disclaimer in the
     14  1.1     fvdl  *    documentation and/or other materials provided with the distribution.
     15  1.1     fvdl  * 3. All advertising materials mentioning features or use of this software
     16  1.1     fvdl  *    must display the following acknowledgement:
     17  1.1     fvdl  *      This product includes software developed for the NetBSD Project
     18  1.1     fvdl  *      by Frank van der Linden
     19  1.1     fvdl  * 4. The name of the author may not be used to endorse or promote products
     20  1.1     fvdl  *    derived from this software without specific prior written permission
     21  1.1     fvdl  *
     22  1.1     fvdl  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
     23  1.1     fvdl  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
     24  1.1     fvdl  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
     25  1.1     fvdl  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
     26  1.1     fvdl  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
     27  1.1     fvdl  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
     28  1.1     fvdl  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
     29  1.1     fvdl  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
     30  1.1     fvdl  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
     31  1.1     fvdl  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     32  1.1     fvdl  */
     33  1.1     fvdl 
     34  1.1     fvdl #ifndef _LINUX_SIGNAL_H
     35  1.1     fvdl #define _LINUX_SIGNAL_H
     36  1.1     fvdl 
     37  1.2  mycroft #define LINUX_SIGHUP	 1
     38  1.2  mycroft #define LINUX_SIGINT	 2
     39  1.2  mycroft #define LINUX_SIGQUIT	 3
     40  1.2  mycroft #define LINUX_SIGILL	 4
     41  1.2  mycroft #define LINUX_SIGTRAP	 5
     42  1.2  mycroft #define LINUX_SIGABRT	 6
     43  1.2  mycroft #define LINUX_SIGIOT	 6
     44  1.2  mycroft #define LINUX_SIGBUS	 7
     45  1.2  mycroft #define LINUX_SIGFPE	 8
     46  1.2  mycroft #define LINUX_SIGKILL	 9
     47  1.2  mycroft #define LINUX_SIGUSR1	10
     48  1.2  mycroft #define LINUX_SIGSEGV	11
     49  1.2  mycroft #define LINUX_SIGUSR2	12
     50  1.2  mycroft #define LINUX_SIGPIPE	13
     51  1.2  mycroft #define LINUX_SIGALRM	14
     52  1.2  mycroft #define LINUX_SIGTERM	15
     53  1.2  mycroft #define LINUX_SIGSTKFLT	16
     54  1.2  mycroft #define LINUX_SIGCHLD	17
     55  1.2  mycroft #define LINUX_SIGCONT	18
     56  1.2  mycroft #define LINUX_SIGSTOP	19
     57  1.2  mycroft #define LINUX_SIGTSTP	20
     58  1.2  mycroft #define LINUX_SIGTTIN	21
     59  1.2  mycroft #define LINUX_SIGTTOU	22
     60  1.2  mycroft #define LINUX_SIGURG	23
     61  1.2  mycroft #define LINUX_SIGXCPU	24
     62  1.2  mycroft #define LINUX_SIGXFSZ	25
     63  1.2  mycroft #define LINUX_SIGVTALRM	26
     64  1.2  mycroft #define LINUX_SIGPROF	27
     65  1.2  mycroft #define LINUX_SIGWINCH	28
     66  1.2  mycroft #define LINUX_SIGIO	29
     67  1.2  mycroft #define LINUX_SIGPWR	30
     68  1.5  mycroft #define LINUX_SIGUNUSED	31
     69  1.2  mycroft #define LINUX_NSIG	32
     70  1.1     fvdl 
     71  1.2  mycroft #define LINUX_SIG_BLOCK		0
     72  1.2  mycroft #define LINUX_SIG_UNBLOCK	1
     73  1.2  mycroft #define LINUX_SIG_SETMASK	2
     74  1.1     fvdl 
     75  1.2  mycroft typedef u_long	linux_sigset_t;
     76  1.2  mycroft typedef void	(*linux_handler_t) __P((int));
     77  1.2  mycroft 
     78  1.2  mycroft struct linux_sigaction {
     79  1.2  mycroft 	linux_handler_t	sa_handler;
     80  1.2  mycroft 	linux_sigset_t	sa_mask;
     81  1.2  mycroft 	u_long		sa_flags;
     82  1.2  mycroft 	void		(*sa_restorer) __P((void));
     83  1.2  mycroft };
     84  1.2  mycroft 
     85  1.2  mycroft /* sa_flags */
     86  1.1     fvdl #define LINUX_SA_NOCLDSTOP	0x00000001
     87  1.1     fvdl #define LINUX_SA_ONSTACK	0x08000000
     88  1.1     fvdl #define LINUX_SA_RESTART	0x10000000
     89  1.1     fvdl #define LINUX_SA_INTERRUPT	0x20000000
     90  1.1     fvdl #define LINUX_SA_NOMASK		0x40000000
     91  1.1     fvdl #define LINUX_SA_ONESHOT	0x80000000
     92  1.5  mycroft #define	LINUX_SA_ALLBITS	0xf8000001
     93  1.3  mycroft 
     94  1.5  mycroft extern int native_to_linux_sig[];
     95  1.5  mycroft extern int linux_to_native_sig[];
     96  1.5  mycroft void linux_to_native_sigset __P((const linux_sigset_t *, sigset_t *));
     97  1.5  mycroft void native_to_linux_sigset __P((const sigset_t *, linux_sigset_t *));
     98  1.1     fvdl 
     99  1.1     fvdl #endif /* !_LINUX_SIGNAL_H */
    100