summaryrefslogtreecommitdiff
path: root/arch/sandbox/include/asm/setjmp.h
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sandbox/include/asm/setjmp.h')
-rw-r--r--arch/sandbox/include/asm/setjmp.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/sandbox/include/asm/setjmp.h b/arch/sandbox/include/asm/setjmp.h
index 1fe37c91cc..001c7ea322 100644
--- a/arch/sandbox/include/asm/setjmp.h
+++ b/arch/sandbox/include/asm/setjmp.h
@@ -24,6 +24,11 @@ struct jmp_buf_data {
typedef struct jmp_buf_data jmp_buf[1];
+/*
+ * We have to directly link with the system versions of
+ * setjmp/longjmp, because setjmp must not return as otherwise
+ * the stack may become invalid.
+ */
int setjmp(jmp_buf jmp);
__noreturn void longjmp(jmp_buf jmp, int ret);