diff options
Diffstat (limited to 'nuttx/include')
-rw-r--r-- | nuttx/include/nuttx/compiler.h | 8 | ||||
-rw-r--r-- | nuttx/include/signal.h | 10 | ||||
-rw-r--r-- | nuttx/include/sys/types.h | 1 |
3 files changed, 13 insertions, 6 deletions
diff --git a/nuttx/include/nuttx/compiler.h b/nuttx/include/nuttx/compiler.h index 1916d8b9c..6f4e68baf 100644 --- a/nuttx/include/nuttx/compiler.h +++ b/nuttx/include/nuttx/compiler.h @@ -50,11 +50,19 @@ # define weak_function __attribute__ ((weak)) # define weak_const_function __attribute__ ((weak, __const__)) # define noreturn_function __attribute__ ((noreturn)) +# define reentrant_function +#elif defined(__SDCC__) +# define weak_alias(name, aliasname) +# define weak_function +# define weak_const_function +# define noreturn_function +# define reentrant_function __reentrant #else # define weak_alias(name, aliasname) # define weak_function # define weak_const_function # define noreturn_function +# define reentrant_function #endif /************************************************************ diff --git a/nuttx/include/signal.h b/nuttx/include/signal.h index 621a6d5f3..4ec153b51 100644 --- a/nuttx/include/signal.h +++ b/nuttx/include/signal.h @@ -118,14 +118,12 @@ typedef struct siginfo /* The following structure defines the action to take for given signal */ -typedef void saHandType(int signo); -typedef void saVxHandType(int signo, siginfo_t *info, void *context); struct sigaction { union { - saHandType *_sa_handler; - saVxHandType *_sa_sigaction; + void (*_sa_handler)(int); + void (*_sa_sigaction)(int, siginfo_t *, void *); } sa_u; sigset_t sa_mask; int sa_flags; @@ -166,10 +164,10 @@ EXTERN int sigtimedwait(const sigset_t *set, struct siginfo *value, const struct timespec *timeout); #ifdef CONFIG_CAN_PASS_STRUCTS -EXTERN int sigqueue(int tid, int signo, +EXTERN int sigqueue(int pid, int signo, const union sigval value); #else -EXTERN int sigqueue(int tid, int signo, void *sival_ptr); +EXTERN int sigqueue(int pid, int signo, void *sival_ptr); #endif #undef EXTERN diff --git a/nuttx/include/sys/types.h b/nuttx/include/sys/types.h index 82f7046d2..37b206ee1 100644 --- a/nuttx/include/sys/types.h +++ b/nuttx/include/sys/types.h @@ -42,6 +42,7 @@ #include <nuttx/config.h> #include <arch/types.h> +#include <nuttx/compiler.h> /************************************************************ * Definitions |