OpenCores
URL https://opencores.org/ocsvn/c0or1k/c0or1k/trunk

Subversion Repositories c0or1k

[/] [c0or1k/] [trunk/] [conts/] [posix/] [libposix/] [include/] [posix/] [bits/] [kernel_sigaction.h] - Blame information for rev 2

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 2 drasko
#ifndef _BITS_SIGACTION_STRUCT_H
2
#define _BITS_SIGACTION_STRUCT_H
3
 
4
/* This file provides whatever this particular arch's kernel thinks
5
 * the sigaction struct should look like... */
6
 
7
#undef NO_OLD_SIGACTION
8
 
9
#if defined(__mips__)
10
#undef HAVE_SA_RESTORER
11
/* This is the sigaction structure from the Linux 2.1.24 kernel.  */
12
#include <sgidefs.h>
13
struct old_kernel_sigaction {
14
    __sighandler_t  k_sa_handler;
15
    unsigned int    sa_flags;
16
    unsigned long   sa_mask;
17
};
18
#define _KERNEL_NSIG           128
19
#define _KERNEL_NSIG_BPW       32
20
#define _KERNEL_NSIG_WORDS     (_KERNEL_NSIG / _KERNEL_NSIG_BPW)
21
 
22
typedef struct {
23
    unsigned long sig[_KERNEL_NSIG_WORDS];
24
} kernel_sigset_t;
25
 
26
/* This is the sigaction structure from the Linux 2.1.68 kernel.  */
27
struct kernel_sigaction {
28
    unsigned int    sa_flags;
29
    __sighandler_t  k_sa_handler;
30
    kernel_sigset_t sa_mask;
31
    void            (*sa_restorer)(void);
32
    int             s_resv[1]; /* reserved */
33
};
34
#elif defined(__ia64__)
35
#define NO_OLD_SIGACTION
36
#undef HAVE_SA_RESTORER
37
struct kernel_sigaction {
38
        __sighandler_t k_sa_handler;
39
        unsigned long sa_flags;
40
        sigset_t sa_mask;
41
};
42
#else
43
#define HAVE_SA_RESTORER
44
/* This is the sigaction structure from the Linux 2.1.20 kernel.  */
45
struct old_kernel_sigaction {
46
    __sighandler_t k_sa_handler;
47
    unsigned long sa_mask;
48
    unsigned long sa_flags;
49
    void (*sa_restorer) (void);
50
};
51
/* This is the sigaction structure from the Linux 2.1.68 kernel.  */
52
struct kernel_sigaction {
53
    __sighandler_t k_sa_handler;
54
    unsigned long sa_flags;
55
    void (*sa_restorer) (void);
56
    sigset_t sa_mask;
57
};
58
#endif
59
 
60
#ifndef NO_OLD_SIGACTION
61
extern int __syscall_sigaction (int, const struct old_kernel_sigaction *__unbounded,
62
        struct old_kernel_sigaction *__unbounded) attribute_hidden;
63
#endif
64
 
65
extern int __syscall_rt_sigaction (int, const struct kernel_sigaction *__unbounded,
66
        struct kernel_sigaction *__unbounded, size_t) attribute_hidden;
67
 
68
#endif /* _BITS_SIGACTION_STRUCT_H */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.