summaryrefslogtreecommitdiffstats
path: root/sys/arm/include
diff options
context:
space:
mode:
authorian <ian@FreeBSD.org>2015-02-13 00:49:47 +0000
committerian <ian@FreeBSD.org>2015-02-13 00:49:47 +0000
commit9165bfa9f7a589040206c4416aee52fbe345b552 (patch)
tree8a4caeb03a675e17f6ee1a762a6160e0ae0baa0e /sys/arm/include
parent04e6c1eb4c21ad8fe8bbe5c0fbc054d35264ddce (diff)
downloadFreeBSD-src-9165bfa9f7a589040206c4416aee52fbe345b552.zip
FreeBSD-src-9165bfa9f7a589040206c4416aee52fbe345b552.tar.gz
MFC r276525, r276596:
Put in a workaround for bug 196407 (arm modules cause crashes & panics). (Don't allow movw/movt insn in modules.) Fix alignment directives in arm asm code after clang 3.5 import.
Diffstat (limited to 'sys/arm/include')
-rw-r--r--sys/arm/include/asm.h6
-rw-r--r--sys/arm/include/profile.h2
2 files changed, 4 insertions, 4 deletions
diff --git a/sys/arm/include/asm.h b/sys/arm/include/asm.h
index a182863..53453d9 100644
--- a/sys/arm/include/asm.h
+++ b/sys/arm/include/asm.h
@@ -46,7 +46,7 @@
#define _ASM_LABEL(x) x
#ifndef _ALIGN_TEXT
-# define _ALIGN_TEXT .align 0
+# define _ALIGN_TEXT .align 2
#endif
#if defined(__ARM_EABI__) && !defined(_STANDALONE)
@@ -129,11 +129,11 @@
pclabel: add got, got, pc
#ifdef __thumb__
#define GOT_INITSYM(gotsym,pclabel) \
- .align 0; \
+ .align 2; \
gotsym: .word _C_LABEL(_GLOBAL_OFFSET_TABLE_) - (pclabel+4)
#else
#define GOT_INITSYM(gotsym,pclabel) \
- .align 0; \
+ .align 2; \
gotsym: .word _C_LABEL(_GLOBAL_OFFSET_TABLE_) - (pclabel+8)
#endif
diff --git a/sys/arm/include/profile.h b/sys/arm/include/profile.h
index 0c5a767..c465ba6 100644
--- a/sys/arm/include/profile.h
+++ b/sys/arm/include/profile.h
@@ -60,7 +60,7 @@ typedef u_long fptrdiff_t;
#define MCOUNT \
__asm__(".text"); \
- __asm__(".align 0"); \
+ __asm__(".align 2"); \
__asm__(".type __mcount ,%function"); \
__asm__(".global __mcount"); \
__asm__("__mcount:"); \
OpenPOWER on IntegriCloud