arm64: Switch remaining uses of __ASSEMBLY__ to __ASSEMBLER__

Some arm64 files that were imported from other projects use the
__ASSEMBLY__ macro to test whether a header is included from a C or an
assembly file. This patch switches them to the coreboot standard
__ASSEMBLER__, which has the advantage of being a GCC builtin so that
the including file doesn't have to supply it explicitly.

Change-Id: I1023f72dd13857b14ce060388e97c658e748928f
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://review.coreboot.org/27237
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
This commit is contained in:
Julius Werner 2018-06-25 17:59:13 -07:00
parent 905e1e763e
commit a98b5bf89b
4 changed files with 6 additions and 7 deletions

View File

@ -56,7 +56,7 @@
#define EXC_VID_LOW32_SERR 15 #define EXC_VID_LOW32_SERR 15
#define NUM_EXC_VIDS 16 #define NUM_EXC_VIDS 16
#ifndef __ASSEMBLY__ #ifndef __ASSEMBLER__
#include <stdint.h> #include <stdint.h>
#include <arch/lib_helpers.h> #include <arch/lib_helpers.h>
@ -197,6 +197,6 @@ void exc_dispatch(struct exc_state *exc_state, uint64_t id);
*/ */
void exc_entry(struct exc_state *exc_state, uint64_t id); void exc_entry(struct exc_state *exc_state, uint64_t id);
#endif /* __ASSEMBLY__ */ #endif /* __ASSEMBLER__ */
#endif /* __ARCH_ARM64_TRANSITION_H__ */ #endif /* __ARCH_ARM64_TRANSITION_H__ */

View File

@ -15,7 +15,7 @@
#ifndef __ASM_ARM_BARRIER_H #ifndef __ASM_ARM_BARRIER_H
#define __ASM_ARM_BARRIER_H #define __ASM_ARM_BARRIER_H
#ifndef __ASSEMBLY__ #ifndef __ASSEMBLER__
#define sevl() asm volatile("sevl" : : : "memory") #define sevl() asm volatile("sevl" : : : "memory")
#define sev() asm volatile("sev" : : : "memory") #define sev() asm volatile("sev" : : : "memory")
@ -103,6 +103,6 @@ do { \
!ret; \ !ret; \
}) })
#endif /* __ASSEMBLY__ */ #endif /* __ASSEMBLER__ */
#endif /* __ASM_ARM_BARRIER_H */ #endif /* __ASM_ARM_BARRIER_H */

View File

@ -136,7 +136,7 @@
#define CPACR_TRAP_FP_EL0 (1 << CPACR_FPEN_SHIFT) #define CPACR_TRAP_FP_EL0 (1 << CPACR_FPEN_SHIFT)
#define CPACR_TRAP_FP_DISABLE (3 << CPACR_FPEN_SHIFT) #define CPACR_TRAP_FP_DISABLE (3 << CPACR_FPEN_SHIFT)
#ifdef __ASSEMBLY__ #ifdef __ASSEMBLER__
/* Macro to switch to label based on current el */ /* Macro to switch to label based on current el */
.macro switch_el xreg label1 label2 label3 .macro switch_el xreg label1 label2 label3
@ -585,6 +585,6 @@ void tlbiallis_current(void);
void tlbiallis(uint32_t el); void tlbiallis(uint32_t el);
void tlbivaa_el1(uint64_t va); void tlbivaa_el1(uint64_t va);
#endif // __ASSEMBLY__ #endif /* __ASSEMBLER__ */
#endif /* __ARCH_LIB_HELPERS_H__ */ #endif /* __ARCH_LIB_HELPERS_H__ */

View File

@ -53,7 +53,6 @@
* to be executed. * to be executed.
*/ */
#define __ASSEMBLY__
#include <arch/asm.h> #include <arch/asm.h>
#include <arch/lib_helpers.h> #include <arch/lib_helpers.h>
#include <arch/transition.h> #include <arch/transition.h>