ANDROID: arm64: kaslr: fixup Falkor workaround for 4.9

android-4.9 port of upstream commit
"arm64: kaslr: Put kernel vectors address in separate data page"
failed to fixup code that does not omcpile when CONFIG_RANDOMIZE_BASE=y.

Port fixup for earlier kernels from to
  - replace ARM64_WORKAROUND_QCOM_FALKOR_E1003 alternative with
     compile-time CONFIG_ARCH_MSM8996 check]

Change-Id: Idc4bb255db830029093ea0d948a9e5066e2c13f8
Signed-off-by: Greg Hackmann <>
Signed-off-by: Todd Poynor <>
diff --git a/arch/arm64/kernel/entry.S b/arch/arm64/kernel/entry.S
index c1ff0999..3448a62 100644
--- a/arch/arm64/kernel/entry.S
+++ b/arch/arm64/kernel/entry.S
@@ -954,7 +954,9 @@
 	tramp_map_kernel	x30
 	adr	x30, tramp_vectors + PAGE_SIZE
-alternative_insn isb, nop, ARM64_WORKAROUND_QCOM_FALKOR_E1003
+#ifndef CONFIG_ARCH_MSM8996
+	isb
 	ldr	x30, [x30]
 	ldr	x30, =vectors