summaryrefslogtreecommitdiffstats
path: root/scripts/sortextable.c
diff options
context:
space:
mode:
authorArd Biesheuvel <ard.biesheuvel@linaro.org>2016-01-01 15:02:12 +0100
committerCatalin Marinas <catalin.marinas@arm.com>2016-02-24 14:57:26 +0000
commit6c94f27ac847ff8ef15b3da5b200574923bd6287 (patch)
treee7a5384289c44b3d10a0ffb92dd7fb912998cfa6 /scripts/sortextable.c
parenta272858a3c1ecd4a935ba23c66668f81214bd110 (diff)
downloadlinux-6c94f27ac847ff8ef15b3da5b200574923bd6287.tar.gz
linux-6c94f27ac847ff8ef15b3da5b200574923bd6287.tar.bz2
linux-6c94f27ac847ff8ef15b3da5b200574923bd6287.zip
arm64: switch to relative exception tables
Instead of using absolute addresses for both the exception location and the fixup, use offsets relative to the exception table entry values. Not only does this cut the size of the exception table in half, it is also a prerequisite for KASLR, since absolute exception table entries are subject to dynamic relocation, which is incompatible with the sorting of the exception table that occurs at build time. This patch also introduces the _ASM_EXTABLE preprocessor macro (which exists on x86 as well) and its _asm_extable assembly counterpart, as shorthands to emit exception table entries. Acked-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org> Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Diffstat (limited to 'scripts/sortextable.c')
-rw-r--r--scripts/sortextable.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/sortextable.c b/scripts/sortextable.c
index ecefa0a634f8..19d83647846c 100644
--- a/scripts/sortextable.c
+++ b/scripts/sortextable.c
@@ -282,12 +282,12 @@ do_file(char const *const fname)
case EM_386:
case EM_X86_64:
case EM_S390:
+ case EM_AARCH64:
custom_sort = sort_relative_table;
break;
case EM_ARCOMPACT:
case EM_ARCV2:
case EM_ARM:
- case EM_AARCH64:
case EM_MICROBLAZE:
case EM_MIPS:
case EM_XTENSA: