diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2018-03-01 21:00:51 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2018-03-01 21:00:51 +0000 |
commit | be66ad6fb76372853102338627541eb3536c95c0 (patch) | |
tree | d1c1dd98d9ed6f9d345c220313113bb6b1a79ea5 /sys/arch/arm/include | |
parent | c731bd6ba8ce00b75c290914c6267283362f448a (diff) |
AAPCS requires 8-byte alignment for 64-bit types. We missed this when we
did the big EABI switch. Do it now before we get into trouble with using
floating-point and vector instructions that actually require things to be
properly aligned.
This breaks the ABI. In particular, file descriptor passing will be
broken if kernel and userland are not in sync. Upgrading from a snap is
highly recommended.
ok otto@, patrick@, jsg@, phessler@, deraadt@
Diffstat (limited to 'sys/arch/arm/include')
-rw-r--r-- | sys/arch/arm/include/_types.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/arch/arm/include/_types.h b/sys/arch/arm/include/_types.h index b45051f45fd..ac365930446 100644 --- a/sys/arch/arm/include/_types.h +++ b/sys/arch/arm/include/_types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: _types.h,v 1.17 2015/09/26 16:01:00 guenther Exp $ */ +/* $OpenBSD: _types.h,v 1.18 2018/03/01 21:00:50 kettenis Exp $ */ /*- * Copyright (c) 1990, 1993 @@ -51,7 +51,7 @@ typedef struct label_t { * This does not reflect the optimal alignment, just the possibility * (within reasonable limits). */ -#define _ALIGNBYTES (sizeof(int) - 1) +#define _ALIGNBYTES (sizeof(double) - 1) #define _STACKALIGNBYTES 7 #define _ALIGN(p) (((unsigned long)(p) + _ALIGNBYTES) & ~_ALIGNBYTES) #define _ALIGNED_POINTER(p,t) ((((unsigned long)(p)) & (sizeof(t) - 1)) == 0) |