From 3acd1dbcd39388bdac3a05172edc51a97191fe5d Mon Sep 17 00:00:00 2001 From: Olivier Houchard Date: Sun, 27 Oct 2013 22:15:50 +0000 Subject: [PATCH] Make sure the PCB is aligned on 8 bytes, we may use ldrd/strd to access it, which may have strong alignment requirements. --- sys/arm/include/pcb.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/arm/include/pcb.h b/sys/arm/include/pcb.h index 8a762aa6789..8d98f2efa0e 100644 --- a/sys/arm/include/pcb.h +++ b/sys/arm/include/pcb.h @@ -81,7 +81,11 @@ struct pcb { struct pcb_arm32 un_32; struct vfp_state pcb_vfpstate; /* VP/NEON state */ u_int pcb_vfpcpu; /* VP/NEON last cpu */ -}; +} __aligned(8); /* + * We need the PCB to be aligned on 8 bytes, as we may + * access it using ldrd/strd, and some CPUs require it + * to by aligned on 8 bytes. + */ /* * No additional data for core dumps.