From e353ac0cfd5d155c01253ee17c2bf23f888cb7de Mon Sep 17 00:00:00 2001 From: Andrew Turner Date: Fri, 3 May 2024 17:07:29 +0100 Subject: [PATCH] am64: Allow cpu.h to be included from assembly Reviewed by: jhibbits, kevans Sponsored by: Arm Ltd Differential Revision: https://reviews.freebsd.org/D45081 --- sys/arm64/include/cpu.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sys/arm64/include/cpu.h b/sys/arm64/include/cpu.h index 8f5a9e3dbd3c..91ed3634c6d8 100644 --- a/sys/arm64/include/cpu.h +++ b/sys/arm64/include/cpu.h @@ -42,8 +42,10 @@ #ifndef _MACHINE_CPU_H_ #define _MACHINE_CPU_H_ +#if !defined(__ASSEMBLER__) #include #include +#endif #include #define TRAPF_PC(tfp) ((tfp)->tf_elr) @@ -198,6 +200,7 @@ #define CPU_MATCH_ERRATA_CAVIUM_THUNDERX_1_1 0 #endif +#if !defined(__ASSEMBLER__) extern char btext[]; extern char etext[]; @@ -268,6 +271,7 @@ ADDRESS_TRANSLATE_FUNC(s1e0w) ADDRESS_TRANSLATE_FUNC(s1e1r) ADDRESS_TRANSLATE_FUNC(s1e1w) +#endif /* !__ASSEMBLER__ */ #endif #endif /* !_MACHINE_CPU_H_ */