mirror of
https://github.com/apache/nuttx.git
synced 2026-06-02 01:21:26 +08:00
singal: add stack_t define
stack_t used by sigaltstack, make it compile sucess in sim. Signed-off-by: yangyalei <yangyalei@xiaomi.com> ltp: fix compile errors Signed-off-by: yangyalei <yangyalei@xiaomi.com>
This commit is contained in:
@@ -85,7 +85,7 @@ typedef struct
|
|||||||
#if CONFIG_ARCH_INTERRUPTSTACK > 3
|
#if CONFIG_ARCH_INTERRUPTSTACK > 3
|
||||||
_stack_t interrupt;
|
_stack_t interrupt;
|
||||||
#endif
|
#endif
|
||||||
} stack_t;
|
} crash_stack_t;
|
||||||
|
|
||||||
/* Flags to identify what is in the dump */
|
/* Flags to identify what is in the dump */
|
||||||
|
|
||||||
@@ -106,7 +106,7 @@ typedef struct
|
|||||||
int lineno; /* __LINE__ to up_assert */
|
int lineno; /* __LINE__ to up_assert */
|
||||||
pid_t pid; /* Process ID */
|
pid_t pid; /* Process ID */
|
||||||
uint32_t regs[XCPTCONTEXT_REGS]; /* Interrupt register save area */
|
uint32_t regs[XCPTCONTEXT_REGS]; /* Interrupt register save area */
|
||||||
stack_t stacks; /* Stack info */
|
crash_stack_t stacks; /* Stack info */
|
||||||
#if CONFIG_TASK_NAME_SIZE > 0
|
#if CONFIG_TASK_NAME_SIZE > 0
|
||||||
char name[CONFIG_TASK_NAME_SIZE + 1]; /* Task name (with NULL
|
char name[CONFIG_TASK_NAME_SIZE + 1]; /* Task name (with NULL
|
||||||
* terminator) */
|
* terminator) */
|
||||||
|
|||||||
@@ -220,6 +220,11 @@
|
|||||||
# define SIGEV_THREAD 3 /* A notification function is called */
|
# define SIGEV_THREAD 3 /* A notification function is called */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* sigaltstack stack size */
|
||||||
|
|
||||||
|
#define MINSIGSTKSZ CONFIG_PTHREAD_STACK_MIN /* Smallest signal stack size */
|
||||||
|
#define SIGSTKSZ CONFIG_PTHREAD_STACK_DEFAULT /* Default signal stack size */
|
||||||
|
|
||||||
/* Special values of sa_handler used by sigaction and sigset. They are all
|
/* Special values of sa_handler used by sigaction and sigset. They are all
|
||||||
* treated like NULL for now. This is okay for SIG_DFL and SIG_IGN because
|
* treated like NULL for now. This is okay for SIG_DFL and SIG_IGN because
|
||||||
* in NuttX, the default action for all signals is to ignore them.
|
* in NuttX, the default action for all signals is to ignore them.
|
||||||
@@ -341,6 +346,15 @@ struct sigaction
|
|||||||
#define sa_handler sa_u._sa_handler
|
#define sa_handler sa_u._sa_handler
|
||||||
#define sa_sigaction sa_u._sa_sigaction
|
#define sa_sigaction sa_u._sa_sigaction
|
||||||
|
|
||||||
|
/* Structure describing a signal stack. */
|
||||||
|
|
||||||
|
typedef struct
|
||||||
|
{
|
||||||
|
FAR void *ss_sp;
|
||||||
|
int ss_flags;
|
||||||
|
size_t ss_size;
|
||||||
|
} stack_t;
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* Public Function Prototypes
|
* Public Function Prototypes
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|||||||
Reference in New Issue
Block a user