Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
adam.huang
Arm Trusted Firmware
Commits
01c44ddd
Commit
01c44ddd
authored
Aug 02, 2019
by
Alexei Fedorov
Committed by
TrustedFirmware Code Review
Aug 02, 2019
Browse files
Merge "Replace __ASSEMBLY__ with compiler-builtin __ASSEMBLER__" into integration
parents
f61469e5
d5dfdeb6
Changes
90
Hide whitespace changes
Inline
Side-by-side
include/lib/bakery_lock.h
View file @
01c44ddd
...
@@ -11,7 +11,7 @@
...
@@ -11,7 +11,7 @@
#define BAKERY_LOCK_MAX_CPUS PLATFORM_CORE_COUNT
#define BAKERY_LOCK_MAX_CPUS PLATFORM_CORE_COUNT
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <cdefs.h>
#include <cdefs.h>
#include <stdbool.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdint.h>
...
@@ -101,5 +101,5 @@ void bakery_lock_release(bakery_lock_t *bakery);
...
@@ -101,5 +101,5 @@ void bakery_lock_release(bakery_lock_t *bakery);
#define DECLARE_BAKERY_LOCK(_name) extern bakery_lock_t _name
#define DECLARE_BAKERY_LOCK(_name) extern bakery_lock_t _name
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* BAKERY_LOCK_H */
#endif
/* BAKERY_LOCK_H */
include/lib/cpus/aarch32/cortex_a9.h
View file @
01c44ddd
...
@@ -25,7 +25,7 @@
...
@@ -25,7 +25,7 @@
******************************************************************************/
******************************************************************************/
#define PCR p15, 0, c15, c0, 0
#define PCR p15, 0, c15, c0, 0
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <arch_helpers.h>
#include <arch_helpers.h>
DEFINE_COPROCR_RW_FUNCS
(
pcr
,
PCR
)
DEFINE_COPROCR_RW_FUNCS
(
pcr
,
PCR
)
#endif
#endif
...
...
include/lib/cpus/aarch64/cortex_a75.h
View file @
01c44ddd
...
@@ -41,7 +41,7 @@
...
@@ -41,7 +41,7 @@
#define CORTEX_A75_AMU_GROUP0_MASK U(0x7)
#define CORTEX_A75_AMU_GROUP0_MASK U(0x7)
#define CORTEX_A75_AMU_GROUP1_MASK (U(0) << 3)
#define CORTEX_A75_AMU_GROUP1_MASK (U(0) << 3)
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <stdint.h>
#include <stdint.h>
uint64_t
cortex_a75_amu_cnt_read
(
int
idx
);
uint64_t
cortex_a75_amu_cnt_read
(
int
idx
);
...
@@ -50,6 +50,6 @@ unsigned int cortex_a75_amu_read_cpuamcntenset_el0(void);
...
@@ -50,6 +50,6 @@ unsigned int cortex_a75_amu_read_cpuamcntenset_el0(void);
unsigned
int
cortex_a75_amu_read_cpuamcntenclr_el0
(
void
);
unsigned
int
cortex_a75_amu_read_cpuamcntenclr_el0
(
void
);
void
cortex_a75_amu_write_cpuamcntenset_el0
(
unsigned
int
mask
);
void
cortex_a75_amu_write_cpuamcntenset_el0
(
unsigned
int
mask
);
void
cortex_a75_amu_write_cpuamcntenclr_el0
(
unsigned
int
mask
);
void
cortex_a75_amu_write_cpuamcntenclr_el0
(
unsigned
int
mask
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* CORTEX_A75_H */
#endif
/* CORTEX_A75_H */
include/lib/cpus/aarch64/cpuamu.h
View file @
01c44ddd
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
#define CPUAMEVTYPER3_EL0 S3_3_C15_C10_3
#define CPUAMEVTYPER3_EL0 S3_3_C15_C10_3
#define CPUAMEVTYPER4_EL0 S3_3_C15_C10_4
#define CPUAMEVTYPER4_EL0 S3_3_C15_C10_4
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <stdint.h>
#include <stdint.h>
uint64_t
cpuamu_cnt_read
(
unsigned
int
idx
);
uint64_t
cpuamu_cnt_read
(
unsigned
int
idx
);
...
@@ -43,6 +43,6 @@ int midr_match(unsigned int cpu_midr);
...
@@ -43,6 +43,6 @@ int midr_match(unsigned int cpu_midr);
void
cpuamu_context_save
(
unsigned
int
nr_counters
);
void
cpuamu_context_save
(
unsigned
int
nr_counters
);
void
cpuamu_context_restore
(
unsigned
int
nr_counters
);
void
cpuamu_context_restore
(
unsigned
int
nr_counters
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* CPUAMU_H */
#endif
/* CPUAMU_H */
include/lib/cpus/aarch64/denver.h
View file @
01c44ddd
...
@@ -34,11 +34,11 @@
...
@@ -34,11 +34,11 @@
#define DENVER_CPU_PMSTATE_C7 U(0x7)
#define DENVER_CPU_PMSTATE_C7 U(0x7)
#define DENVER_CPU_PMSTATE_MASK U(0xF)
#define DENVER_CPU_PMSTATE_MASK U(0xF)
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
/* Disable Dynamic Code Optimisation */
/* Disable Dynamic Code Optimisation */
void
denver_disable_dco
(
void
);
void
denver_disable_dco
(
void
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* DENVER_H */
#endif
/* DENVER_H */
include/lib/cpus/errata_report.h
View file @
01c44ddd
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
#ifndef ERRATA_REPORT_H
#ifndef ERRATA_REPORT_H
#define ERRATA_REPORT_H
#define ERRATA_REPORT_H
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <arch.h>
#include <arch.h>
#include <arch_helpers.h>
#include <arch_helpers.h>
...
@@ -23,7 +23,7 @@ static inline void print_errata_status(void) {}
...
@@ -23,7 +23,7 @@ static inline void print_errata_status(void) {}
void
errata_print_msg
(
unsigned
int
status
,
const
char
*
cpu
,
const
char
*
id
);
void
errata_print_msg
(
unsigned
int
status
,
const
char
*
cpu
,
const
char
*
id
);
int
errata_needs_reporting
(
spinlock_t
*
lock
,
uint32_t
*
reported
);
int
errata_needs_reporting
(
spinlock_t
*
lock
,
uint32_t
*
reported
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
/* Errata status */
/* Errata status */
#define ERRATA_NOT_APPLIES 0
#define ERRATA_NOT_APPLIES 0
...
...
include/lib/el3_runtime/aarch32/context.h
View file @
01c44ddd
...
@@ -24,7 +24,7 @@
...
@@ -24,7 +24,7 @@
#define CTX_NS_SCTLR U(0x1C)
#define CTX_NS_SCTLR U(0x1C)
#define CTX_REGS_END U(0x20)
#define CTX_REGS_END U(0x20)
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <stdint.h>
#include <stdint.h>
...
@@ -65,6 +65,6 @@ typedef struct cpu_context {
...
@@ -65,6 +65,6 @@ typedef struct cpu_context {
CASSERT
(
CTX_REGS_OFFSET
==
__builtin_offsetof
(
cpu_context_t
,
regs_ctx
),
\
CASSERT
(
CTX_REGS_OFFSET
==
__builtin_offsetof
(
cpu_context_t
,
regs_ctx
),
\
assert_core_context_regs_offset_mismatch
);
assert_core_context_regs_offset_mismatch
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* CONTEXT_H */
#endif
/* CONTEXT_H */
include/lib/el3_runtime/aarch64/context.h
View file @
01c44ddd
...
@@ -207,7 +207,7 @@
...
@@ -207,7 +207,7 @@
#define CTX_PAUTH_REGS_END U(0)
#define CTX_PAUTH_REGS_END U(0)
#endif
/* CTX_INCLUDE_PAUTH_REGS */
#endif
/* CTX_INCLUDE_PAUTH_REGS */
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <stdint.h>
#include <stdint.h>
...
@@ -384,6 +384,6 @@ void fpregs_context_save(fp_regs_t *regs);
...
@@ -384,6 +384,6 @@ void fpregs_context_save(fp_regs_t *regs);
void
fpregs_context_restore
(
fp_regs_t
*
regs
);
void
fpregs_context_restore
(
fp_regs_t
*
regs
);
#endif
#endif
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* CONTEXT_H */
#endif
/* CONTEXT_H */
include/lib/el3_runtime/cpu_data.h
View file @
01c44ddd
...
@@ -49,7 +49,7 @@
...
@@ -49,7 +49,7 @@
#define CPU_DATA_PMF_TS0_IDX 0
#define CPU_DATA_PMF_TS0_IDX 0
#endif
#endif
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <arch_helpers.h>
#include <arch_helpers.h>
#include <lib/cassert.h>
#include <lib/cassert.h>
...
@@ -161,5 +161,5 @@ void init_cpu_ops(void);
...
@@ -161,5 +161,5 @@ void init_cpu_ops(void);
sizeof(((cpu_data_t *)0)->_m))
sizeof(((cpu_data_t *)0)->_m))
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* CPU_DATA_H */
#endif
/* CPU_DATA_H */
include/lib/extensions/ras.h
View file @
01c44ddd
...
@@ -68,7 +68,7 @@
...
@@ -68,7 +68,7 @@
.num_intrs = ARRAY_SIZE(_array), \
.num_intrs = ARRAY_SIZE(_array), \
}
}
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <assert.h>
#include <assert.h>
...
@@ -196,6 +196,6 @@ int ras_ea_handler(unsigned int ea_reason, uint64_t syndrome, void *cookie,
...
@@ -196,6 +196,6 @@ int ras_ea_handler(unsigned int ea_reason, uint64_t syndrome, void *cookie,
void
*
handle
,
uint64_t
flags
);
void
*
handle
,
uint64_t
flags
);
void
ras_init
(
void
);
void
ras_init
(
void
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* RAS_H */
#endif
/* RAS_H */
include/lib/extensions/ras_arch.h
View file @
01c44ddd
...
@@ -178,7 +178,7 @@
...
@@ -178,7 +178,7 @@
/* I/DFSC code for synchronous external abort */
/* I/DFSC code for synchronous external abort */
#define SYNC_EA_FSC 0x10
#define SYNC_EA_FSC 0x10
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <arch.h>
#include <arch.h>
#include <arch_helpers.h>
#include <arch_helpers.h>
...
@@ -256,6 +256,6 @@ static inline void ser_sys_select_record(unsigned int idx)
...
@@ -256,6 +256,6 @@ static inline void ser_sys_select_record(unsigned int idx)
/* Library functions to probe Standard Error Record */
/* Library functions to probe Standard Error Record */
int
ser_probe_memmap
(
uintptr_t
base
,
unsigned
int
size_num_k
,
int
*
probe_data
);
int
ser_probe_memmap
(
uintptr_t
base
,
unsigned
int
size_num_k
,
int
*
probe_data
);
int
ser_probe_sysreg
(
unsigned
int
idx_start
,
unsigned
int
num_idx
,
int
*
probe_data
);
int
ser_probe_sysreg
(
unsigned
int
idx_start
,
unsigned
int
num_idx
,
int
*
probe_data
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* RAS_ARCH_H */
#endif
/* RAS_ARCH_H */
include/lib/libc/aarch64/setjmp_.h
View file @
01c44ddd
...
@@ -18,13 +18,13 @@
...
@@ -18,13 +18,13 @@
#define JMP_SIZE (JMP_CTX_END >> 3)
#define JMP_SIZE (JMP_CTX_END >> 3)
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <cdefs.h>
#include <cdefs.h>
/* Jump buffer hosting x18 - x30 and sp_el0 registers */
/* Jump buffer hosting x18 - x30 and sp_el0 registers */
typedef
uint64_t
jmp_buf
[
JMP_SIZE
]
__aligned
(
16
);
typedef
uint64_t
jmp_buf
[
JMP_SIZE
]
__aligned
(
16
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* SETJMP__H */
#endif
/* SETJMP__H */
include/lib/libc/setjmp.h
View file @
01c44ddd
...
@@ -9,12 +9,12 @@
...
@@ -9,12 +9,12 @@
#include <setjmp_.h>
#include <setjmp_.h>
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <cdefs.h>
#include <cdefs.h>
int
setjmp
(
jmp_buf
env
);
int
setjmp
(
jmp_buf
env
);
__dead2
void
longjmp
(
jmp_buf
env
,
int
val
);
__dead2
void
longjmp
(
jmp_buf
env
,
int
val
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* SETJMP_H */
#endif
/* SETJMP_H */
include/lib/libfdt/fdt.h
View file @
01c44ddd
...
@@ -52,7 +52,7 @@
...
@@ -52,7 +52,7 @@
* EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
* EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
*/
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
struct
fdt_header
{
struct
fdt_header
{
fdt32_t
magic
;
/* magic word FDT_MAGIC */
fdt32_t
magic
;
/* magic word FDT_MAGIC */
...
@@ -90,7 +90,7 @@ struct fdt_property {
...
@@ -90,7 +90,7 @@ struct fdt_property {
char
data
[
0
];
char
data
[
0
];
};
};
#endif
/* !__ASSEMBL
Y
*/
#endif
/* !__ASSEMBL
ER__
*/
#define FDT_MAGIC 0xd00dfeed
/* 4: version, 4: total size */
#define FDT_MAGIC 0xd00dfeed
/* 4: version, 4: total size */
#define FDT_TAGSIZE sizeof(fdt32_t)
#define FDT_TAGSIZE sizeof(fdt32_t)
...
...
include/lib/psci/psci.h
View file @
01c44ddd
...
@@ -166,7 +166,7 @@
...
@@ -166,7 +166,7 @@
#define PSCI_RESET2_TYPE_ARCH (U(0) << PSCI_RESET2_TYPE_VENDOR_SHIFT)
#define PSCI_RESET2_TYPE_ARCH (U(0) << PSCI_RESET2_TYPE_VENDOR_SHIFT)
#define PSCI_RESET2_SYSTEM_WARM_RESET (PSCI_RESET2_TYPE_ARCH | U(0))
#define PSCI_RESET2_SYSTEM_WARM_RESET (PSCI_RESET2_TYPE_ARCH | U(0))
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <stdint.h>
#include <stdint.h>
...
@@ -348,6 +348,6 @@ int psci_features(unsigned int psci_fid);
...
@@ -348,6 +348,6 @@ int psci_features(unsigned int psci_fid);
void
__dead2
psci_power_down_wfi
(
void
);
void
__dead2
psci_power_down_wfi
(
void
);
void
psci_arch_setup
(
void
);
void
psci_arch_setup
(
void
);
#endif
/*__ASSEMBL
Y
__*/
#endif
/*__ASSEMBL
ER
__*/
#endif
/* PSCI_H */
#endif
/* PSCI_H */
include/lib/psci/psci_lib.h
View file @
01c44ddd
...
@@ -9,7 +9,7 @@
...
@@ -9,7 +9,7 @@
#include <common/ep_info.h>
#include <common/ep_info.h>
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <cdefs.h>
#include <cdefs.h>
#include <stdint.h>
#include <stdint.h>
...
@@ -89,6 +89,6 @@ void psci_warmboot_entrypoint(void);
...
@@ -89,6 +89,6 @@ void psci_warmboot_entrypoint(void);
void
psci_register_spd_pm_hook
(
const
spd_pm_ops_t
*
pm
);
void
psci_register_spd_pm_hook
(
const
spd_pm_ops_t
*
pm
);
void
psci_prepare_next_non_secure_ctx
(
void
psci_prepare_next_non_secure_ctx
(
entry_point_info_t
*
next_image_info
);
entry_point_info_t
*
next_image_info
);
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* PSCI_LIB_H */
#endif
/* PSCI_LIB_H */
include/lib/runtime_instr.h
View file @
01c44ddd
...
@@ -17,9 +17,9 @@
...
@@ -17,9 +17,9 @@
#define RT_INSTR_EXIT_CFLUSH U(5)
#define RT_INSTR_EXIT_CFLUSH U(5)
#define RT_INSTR_TOTAL_IDS U(6)
#define RT_INSTR_TOTAL_IDS U(6)
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
PMF_DECLARE_CAPTURE_TIMESTAMP
(
rt_instr_svc
)
PMF_DECLARE_CAPTURE_TIMESTAMP
(
rt_instr_svc
)
PMF_DECLARE_GET_TIMESTAMP
(
rt_instr_svc
)
PMF_DECLARE_GET_TIMESTAMP
(
rt_instr_svc
)
#endif
/* __ASSEMBL
Y
__ */
#endif
/* __ASSEMBL
ER
__ */
#endif
/* RUNTIME_INSTR_H */
#endif
/* RUNTIME_INSTR_H */
include/lib/smccc.h
View file @
01c44ddd
...
@@ -87,7 +87,7 @@
...
@@ -87,7 +87,7 @@
#define SMC_FROM_SECURE (U(0) << 0)
#define SMC_FROM_SECURE (U(0) << 0)
#define SMC_FROM_NON_SECURE (U(1) << 0)
#define SMC_FROM_NON_SECURE (U(1) << 0)
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <stdint.h>
#include <stdint.h>
...
@@ -155,5 +155,5 @@ static inline uint32_t smc_uuid_word(uint8_t b0, uint8_t b1, uint8_t b2, uint8_t
...
@@ -155,5 +155,5 @@ static inline uint32_t smc_uuid_word(uint8_t b0, uint8_t b1, uint8_t b2, uint8_t
smc_uuid_word((_uuid).node[2], (_uuid).node[3], \
smc_uuid_word((_uuid).node[2], (_uuid).node[3], \
(_uuid).node[4], (_uuid).node[5]))
(_uuid).node[4], (_uuid).node[5]))
#endif
/*__ASSEMBL
Y
__*/
#endif
/*__ASSEMBL
ER
__*/
#endif
/* SMCCC_H */
#endif
/* SMCCC_H */
include/lib/spinlock.h
View file @
01c44ddd
...
@@ -7,7 +7,7 @@
...
@@ -7,7 +7,7 @@
#ifndef SPINLOCK_H
#ifndef SPINLOCK_H
#define SPINLOCK_H
#define SPINLOCK_H
#ifndef __ASSEMBL
Y
__
#ifndef __ASSEMBL
ER
__
#include <stdint.h>
#include <stdint.h>
...
...
include/lib/utils.h
View file @
01c44ddd
...
@@ -11,7 +11,7 @@
...
@@ -11,7 +11,7 @@
* C code should be put in this part of the header to avoid breaking ASM files
* C code should be put in this part of the header to avoid breaking ASM files
* or linker scripts including it.
* or linker scripts including it.
*/
*/
#if !(defined(__LINKER__) || defined(__ASSEMBL
Y
__))
#if !(defined(__LINKER__) || defined(__ASSEMBL
ER
__))
#include <stddef.h>
#include <stddef.h>
#include <stdint.h>
#include <stdint.h>
...
@@ -91,6 +91,6 @@ static inline u_register_t load_addr_## _name(void) \
...
@@ -91,6 +91,6 @@ static inline u_register_t load_addr_## _name(void) \
/* Helper to invoke the function defined by DEFINE_LOAD_SYM_ADDR() */
/* Helper to invoke the function defined by DEFINE_LOAD_SYM_ADDR() */
#define LOAD_ADDR_OF(_name) (typeof(_name) *) load_addr_## _name()
#define LOAD_ADDR_OF(_name) (typeof(_name) *) load_addr_## _name()
#endif
/* !(defined(__LINKER__) || defined(__ASSEMBL
Y
__)) */
#endif
/* !(defined(__LINKER__) || defined(__ASSEMBL
ER
__)) */
#endif
/* UTILS_H */
#endif
/* UTILS_H */
Prev
1
2
3
4
5
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment