summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2018-06-22 15:18:51 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2018-06-22 15:18:51 +0000
commit1cc668a6e4e90a6df9827274ac8ad872d12a53f8 (patch)
tree58efacb6db291e36d71dacd3955224459727075d /sys/arch
parent9cd939fb7466279e8657a832e36c8d007b3ac403 (diff)
Save and restore the relevant FPU state on armv7.
ok deraadt@
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/arm/include/setjmp.h62
1 files changed, 27 insertions, 35 deletions
diff --git a/sys/arch/arm/include/setjmp.h b/sys/arch/arm/include/setjmp.h
index a24c3fb1094..02d332c8aa7 100644
--- a/sys/arch/arm/include/setjmp.h
+++ b/sys/arch/arm/include/setjmp.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: setjmp.h,v 1.4 2016/08/07 02:02:57 guenther Exp $ */
+/* $OpenBSD: setjmp.h,v 1.5 2018/06/22 15:18:50 kettenis Exp $ */
/* $NetBSD: setjmp.h,v 1.2 2001/08/25 14:45:59 bjh21 Exp $ */
/*
@@ -11,26 +11,23 @@
* Description of the setjmp buffer
*
* word 0 magic number (dependant on creator)
- * 1 - 3 f4 fp register 4
- * 4 - 6 f5 fp register 5
- * 7 - 9 f6 fp register 6
- * 10 - 12 f7 fp register 7
- * 13 fpsr fp status register
- * 14 r13 register 13 (sp) XOR cookie0
- * 15 r14 register 14 (lr) XOR cookie1
- * 16 r4 register 4
- * 17 r5 register 5
- * 18 r6 register 6
- * 19 r7 register 7
- * 20 r8 register 8
- * 21 r9 register 9
- * 22 r10 register 10 (sl)
- * 23 r11 register 11 (fp)
- * 24 unused unused
- * 25 signal mask (dependant on magic)
- * 26 (con't)
- * 27 (con't)
- * 28 (con't)
+ * 1 fpscr fpscr
+ * 2 - 17 d8 - d15 vfp registers
+ * 18 r13 register 13 (sp) XOR cookie0
+ * 19 r14 register 14 (lr) XOR cookie1
+ * 20 r4 register 4
+ * 21 r5 register 5
+ * 22 r6 register 6
+ * 23 r7 register 7
+ * 24 r8 register 8
+ * 25 r9 register 9
+ * 26 r10 register 10 (sl)
+ * 27 r11 register 11 (fp)
+ * 28 unused unused
+ * 29 signal mask (dependant on magic)
+ * 30 (con't)
+ * 31 (con't)
+ * 32 (con't)
*
* The magic number number identifies the jmp_buf and
* how the buffer was created as well as providing
@@ -56,20 +53,15 @@
/* Valid for all jmp_buf's */
#define _JB_MAGIC 0
-#define _JB_REG_F4 1
-#define _JB_REG_F5 4
-#define _JB_REG_F6 7
-#define _JB_REG_F7 10
-#define _JB_REG_FPSR 13
-#define _JB_REG_R4 16
-#define _JB_REG_R5 17
-#define _JB_REG_R6 18
-#define _JB_REG_R7 19
-#define _JB_REG_R8 20
-#define _JB_REG_R9 21
-#define _JB_REG_R10 22
-#define _JB_REG_R11 23
+#define _JB_REG_R4 20
+#define _JB_REG_R5 21
+#define _JB_REG_R6 22
+#define _JB_REG_R7 23
+#define _JB_REG_R8 24
+#define _JB_REG_R9 25
+#define _JB_REG_R10 26
+#define _JB_REG_R11 27
/* Only valid with the _JB_MAGIC_SETJMP magic */
-#define _JB_SIGMASK 25
+#define _JB_SIGMASK 29