arm64: insn: move AARCH64_INSN_SIZE into <asm/insn.h>
authorMark Rutland <mark.rutland@arm.com>
Wed, 9 Jun 2021 10:23:01 +0000 (11:23 +0100)
committerWill Deacon <will@kernel.org>
Fri, 11 Jun 2021 10:19:27 +0000 (11:19 +0100)
For histroical reasons, we define AARCH64_INSN_SIZE in
<asm/alternative-macros.h>, but it would make more sense to do so in
<asm/insn.h>. Let's move it into <asm/insn.h>, and add the necessary
include directives for this.

Signed-off-by: Mark Rutland <mark.rutland@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20210609102301.17332-3-mark.rutland@arm.com
Signed-off-by: Will Deacon <will@kernel.org>
arch/arm64/include/asm/alternative-macros.h
arch/arm64/include/asm/insn.h
arch/arm64/include/asm/kvm_asm.h
arch/arm64/kernel/cpufeature.c
arch/arm64/kernel/patching.c
arch/arm64/kernel/traps.c
arch/arm64/net/bpf_jit_comp.c

index 8a078fc662ac5df176785caa5f04746b55f50063..703fbf310b792d3d34792aea206991ceb972006f 100644 (file)
@@ -3,12 +3,10 @@
 #define __ASM_ALTERNATIVE_MACROS_H
 
 #include <asm/cpucaps.h>
+#include <asm/insn.h>
 
 #define ARM64_CB_PATCH ARM64_NCAPS
 
-/* A64 instructions are always 32 bits. */
-#define        AARCH64_INSN_SIZE               4
-
 #ifndef __ASSEMBLY__
 
 #include <linux/stringify.h>
index a6f3f45fc46f016eb3282984c4306146036429d5..1430b4973039a8d5f3e54c054ea1d381f9f3d53a 100644 (file)
@@ -12,6 +12,9 @@
 
 #include <asm/alternative.h>
 
+/* A64 instructions are always 32 bits. */
+#define        AARCH64_INSN_SIZE               4
+
 #ifndef __ASSEMBLY__
 /*
  * ARM Architecture Reference Manual for ARMv8 Profile-A, Issue A.a
index cf8df032b9c30e4285df23ec4c8078c8f465857e..894edda8cc85aa01efa281677432b0d137efd8cd 100644 (file)
@@ -8,6 +8,7 @@
 #define __ARM_KVM_ASM_H__
 
 #include <asm/hyp_image.h>
+#include <asm/insn.h>
 #include <asm/virt.h>
 
 #define ARM_EXIT_WITH_SERROR_BIT  31
index efed2830d141f213f207f05ac601aa1ac15e8850..16d35cfffcea8f1ff01c536a044c543d4800ce43 100644 (file)
@@ -76,6 +76,7 @@
 #include <asm/cpufeature.h>
 #include <asm/cpu_ops.h>
 #include <asm/fpsimd.h>
+#include <asm/insn.h>
 #include <asm/kvm_host.h>
 #include <asm/mmu_context.h>
 #include <asm/mte.h>
index 7aa55b33c8c7512bf4fc33476eebe29ce1fb1545..9a6edb9c48c7ddf3be3d3c3d9a64ae22d844c20a 100644 (file)
@@ -8,6 +8,7 @@
 
 #include <asm/cacheflush.h>
 #include <asm/fixmap.h>
+#include <asm/insn.h>
 #include <asm/kprobes.h>
 #include <asm/patching.h>
 #include <asm/sections.h>
index 48ff6fb888e0c839e2fbadefec725a9baff295d5..8f66072fa5cb2c3ee72e39a2b634fb0671432af4 100644 (file)
@@ -36,6 +36,7 @@
 #include <asm/esr.h>
 #include <asm/exception.h>
 #include <asm/extable.h>
+#include <asm/insn.h>
 #include <asm/kprobes.h>
 #include <asm/patching.h>
 #include <asm/traps.h>
index f7b194878a99a0931ef43250ad5bb1b04498517b..dd5000da18b8929148ef9889cbe3bf8c48a8e8fa 100644 (file)
@@ -16,6 +16,7 @@
 #include <asm/byteorder.h>
 #include <asm/cacheflush.h>
 #include <asm/debug-monitors.h>
+#include <asm/insn.h>
 #include <asm/set_memory.h>
 
 #include "bpf_jit.h"