diff options
Diffstat (limited to 'tftf')
15 files changed, 46 insertions, 46 deletions
diff --git a/tftf/framework/main.c b/tftf/framework/main.c index 2523a9784..2350b9622 100644 --- a/tftf/framework/main.c +++ b/tftf/framework/main.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018-2019, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -517,7 +517,7 @@ void __dead2 tftf_cold_boot_main(void) NOTICE("%s\n", build_message); NOTICE("%s\n\n", version_string); -#ifndef AARCH32 +#ifdef __aarch64__ NOTICE("Running at NS-EL%u\n", IS_IN_EL(1) ? 1 : 2); #else NOTICE("Running in AArch32 HYP mode\n"); diff --git a/tftf/tests/extensions/mte/test_mte.c b/tftf/tests/extensions/mte/test_mte.c index 13da667d2..7dbb9ef7f 100644 --- a/tftf/tests/extensions/mte/test_mte.c +++ b/tftf/tests/extensions/mte/test_mte.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019, Arm Limited. All rights reserved. + * Copyright (c) 2019-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -12,7 +12,7 @@ test_result_t test_mte_instructions(void) { SKIP_TEST_IF_AARCH32(); -#ifdef AARCH64 +#ifdef __aarch64__ SKIP_TEST_IF_MTE_SUPPORT_LESS_THAN(MTE_IMPLEMENTED_EL0); /* irg */ @@ -24,13 +24,13 @@ test_result_t test_mte_instructions(void) __asm__ volatile (".inst 0xD1800129"); return TEST_RESULT_SUCCESS; -#endif /* AARCH64 */ +#endif /* __aarch64__ */ } test_result_t test_mte_leakage(void) { SKIP_TEST_IF_AARCH32(); -#ifdef AARCH64 +#ifdef __aarch64__ smc_args tsp_svc_params; int gcr_el1; @@ -53,5 +53,5 @@ test_result_t test_mte_leakage(void) } return TEST_RESULT_SUCCESS; -#endif /* AARCH64 */ +#endif /* __aarch64__ */ } diff --git a/tftf/tests/extensions/sve/sve_operations.S b/tftf/tests/extensions/sve/sve_operations.S index 9440b1367..e528b2bfe 100644 --- a/tftf/tests/extensions/sve/sve_operations.S +++ b/tftf/tests/extensions/sve/sve_operations.S @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019, Arm Limited. All rights reserved. + * Copyright (c) 2019-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -8,7 +8,7 @@ #include "./test_sve.h" -#ifdef AARCH64 +#ifdef __aarch64__ #if __GNUC__ > 8 || (__GNUC__ == 8 && __GNUC_MINOR__ > 0) /* @@ -36,4 +36,4 @@ func sve_subtract_arrays endfunc sve_subtract_arrays #endif /* __GNUC__ > 8 || (__GNUC__ == 8 && __GNUC_MINOR__ > 0) */ -#endif /* AARCH64 */ +#endif /* __aarch64__ */ diff --git a/tftf/tests/misc_tests/inject_serror.S b/tftf/tests/misc_tests/inject_serror.S index 0d7dbf2d7..008503f1f 100644 --- a/tftf/tests/misc_tests/inject_serror.S +++ b/tftf/tests/misc_tests/inject_serror.S @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -9,7 +9,7 @@ #include <sdei.h> -#ifdef AARCH64 +#ifdef __aarch64__ .globl inject_serror .globl inject_uncontainable .globl serror_sdei_event_handler diff --git a/tftf/tests/misc_tests/test_pmu_leakage.c b/tftf/tests/misc_tests/test_pmu_leakage.c index da289992f..36b3138ba 100644 --- a/tftf/tests/misc_tests/test_pmu_leakage.c +++ b/tftf/tests/misc_tests/test_pmu_leakage.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019, Arm Limited. All rights reserved. + * Copyright (c) 2019-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -75,7 +75,7 @@ struct pmu_event_info { unsigned long long avg; }; -#ifdef AARCH64 +#ifdef __aarch64__ #define V8_2_DEBUG_ARCH_SUPPORTED ID_AA64DFR0_V8_2_DEBUG_ARCH_SUPPORTED #else #define V8_2_DEBUG_ARCH_SUPPORTED DBGDIDR_V8_2_DEBUG_ARCH_SUPPORTED diff --git a/tftf/tests/misc_tests/test_single_fault.c b/tftf/tests/misc_tests/test_single_fault.c index e6522118e..f55d8de8d 100644 --- a/tftf/tests/misc_tests/test_single_fault.c +++ b/tftf/tests/misc_tests/test_single_fault.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -9,7 +9,7 @@ #include <sdei.h> #include <tftf_lib.h> -#ifndef AARCH32 +#ifdef __aarch64__ uint64_t serror_received; diff --git a/tftf/tests/misc_tests/test_uncontainable.c b/tftf/tests/misc_tests/test_uncontainable.c index 79c903114..231e5e8cf 100644 --- a/tftf/tests/misc_tests/test_uncontainable.c +++ b/tftf/tests/misc_tests/test_uncontainable.c @@ -1,12 +1,12 @@ /* - * Copyright (c) 2018, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ #include <tftf_lib.h> -#ifndef AARCH32 +#ifdef __aarch64__ extern void inject_uncontainable(void); diff --git a/tftf/tests/runtime_services/arm_arch_svc/smccc_arch_workaround_1.c b/tftf/tests/runtime_services/arm_arch_svc/smccc_arch_workaround_1.c index 90a43f33b..e88f183f0 100644 --- a/tftf/tests/runtime_services/arm_arch_svc/smccc_arch_workaround_1.c +++ b/tftf/tests/runtime_services/arm_arch_svc/smccc_arch_workaround_1.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -14,7 +14,7 @@ #include <string.h> #include <tftf_lib.h> -#ifdef AARCH64 +#ifdef __aarch64__ #define CORTEX_A57_MIDR 0x410FD070 #define CORTEX_A72_MIDR 0x410FD080 #define CORTEX_A73_MIDR 0x410FD090 diff --git a/tftf/tests/runtime_services/arm_arch_svc/smccc_arch_workaround_2.c b/tftf/tests/runtime_services/arm_arch_svc/smccc_arch_workaround_2.c index cf36e4f80..1557e4f9a 100644 --- a/tftf/tests/runtime_services/arm_arch_svc/smccc_arch_workaround_2.c +++ b/tftf/tests/runtime_services/arm_arch_svc/smccc_arch_workaround_2.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019, Arm Limited. All rights reserved. + * Copyright (c) 2019-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -14,7 +14,7 @@ #include <string.h> #include <tftf_lib.h> -#ifdef AARCH64 +#ifdef __aarch64__ #define NOT_REQUIRED_DONOT_INVOKE -2 #define NOT_SUPPORTED -1 #define IS_REQUIRED 0 @@ -159,4 +159,4 @@ test_result_t test_smccc_arch_workaround_2(void) INFO("%s skipped on AArch32\n", __func__); return TEST_RESULT_SKIPPED; } -#endif /* AARCH64 */ +#endif /* __aarch64__ */ diff --git a/tftf/tests/runtime_services/generic/generic_smc.c b/tftf/tests/runtime_services/generic/generic_smc.c index dc0b10230..6d057a6a8 100644 --- a/tftf/tests/runtime_services/generic/generic_smc.c +++ b/tftf/tests/runtime_services/generic/generic_smc.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018-2019, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -236,7 +236,7 @@ test_result_t smc64_yielding(void) return TEST_RESULT_SUCCESS; } -#ifdef AARCH32 +#ifndef __aarch64__ static test_result_t smc64_fast_caller32(void) { /* Valid Fast SMC32 using all 4 return values. */ @@ -295,12 +295,12 @@ static test_result_t smc64_fast_caller64(void) return TEST_RESULT_SUCCESS; } -#endif /* AARCH32 */ +#endif /* !__aarch64__ */ /* Exercise SMC64 calling convention with fast SMC calls. */ test_result_t smc64_fast(void) { -#ifdef AARCH32 +#ifndef __aarch64__ return smc64_fast_caller32(); #else return smc64_fast_caller64(); diff --git a/tftf/tests/runtime_services/sip_service/test_exec_state_switch.c b/tftf/tests/runtime_services/sip_service/test_exec_state_switch.c index 713c8196e..9b272ba5c 100644 --- a/tftf/tests/runtime_services/sip_service/test_exec_state_switch.c +++ b/tftf/tests/runtime_services/sip_service/test_exec_state_switch.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -65,7 +65,7 @@ extern int do_state_switch(void *); */ test_result_t test_exec_state_switch_reset_before(void) { -#ifdef AARCH64 +#ifdef __aarch64__ int version; smc_args sip_version_smc = { ARM_SIP_SVC_VERSION }; smc_args reset = { SMC_PSCI_SYSTEM_RESET }; @@ -126,7 +126,7 @@ test_result_t test_exec_state_switch_reset_before(void) */ test_result_t test_exec_state_switch_invalid_pc(void) { -#ifdef AARCH64 +#ifdef __aarch64__ int ret; smc_args args = { @@ -159,7 +159,7 @@ test_result_t test_exec_state_switch_invalid_pc(void) */ test_result_t test_exec_state_switch_invalid_ctx(void) { -#ifdef AARCH64 +#ifdef __aarch64__ int ret; smc_args args = { @@ -191,7 +191,7 @@ test_result_t test_exec_state_switch_invalid_ctx(void) */ test_result_t test_exec_state_switch_valid(void) { -#ifdef AARCH64 +#ifdef __aarch64__ int ret; smc_args args = { @@ -233,7 +233,7 @@ test_result_t test_exec_state_switch_valid(void) */ static inline test_result_t cpu_ping(void) { -#ifdef AARCH64 +#ifdef __aarch64__ /* Tell the lead CPU that the calling CPU has entered the test */ tftf_send_event(&secondary_booted); @@ -254,7 +254,7 @@ static inline test_result_t cpu_ping(void) */ test_result_t test_exec_state_switch_after_cpu_on(void) { -#ifdef AARCH64 +#ifdef __aarch64__ u_register_t other_mpidr, my_mpidr; int ret; diff --git a/tftf/tests/runtime_services/sip_service/test_exec_state_switch_asm.S b/tftf/tests/runtime_services/sip_service/test_exec_state_switch_asm.S index 577f89f7a..d86575600 100644 --- a/tftf/tests/runtime_services/sip_service/test_exec_state_switch_asm.S +++ b/tftf/tests/runtime_services/sip_service/test_exec_state_switch_asm.S @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -8,7 +8,7 @@ #define COOKIE_SIZE 20 -#ifdef AARCH64 +#ifdef __aarch64__ /* int do_state_switch(void *) */ .globl do_state_switch func do_state_switch @@ -167,7 +167,7 @@ state_switch_a32_entry: .word 0xe1600070 /* smc #0x0 */ .word 0xeafffffe /* b . */ -#else /* !AARCH64 */ +#else /* !__aarch64__ */ /* Not supported on AArch32 yet */ func do_state_switch @@ -175,4 +175,4 @@ func do_state_switch bx lr endfunc do_state_switch -#endif /* AARCH64 */ +#endif /* __aarch64__ */ diff --git a/tftf/tests/runtime_services/standard_service/psci/api_tests/affinity_info/test_psci_affinity_info.c b/tftf/tests/runtime_services/standard_service/psci/api_tests/affinity_info/test_psci_affinity_info.c index cc4ad191c..708ea132f 100644 --- a/tftf/tests/runtime_services/standard_service/psci/api_tests/affinity_info/test_psci_affinity_info.c +++ b/tftf/tests/runtime_services/standard_service/psci/api_tests/affinity_info/test_psci_affinity_info.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018-2019, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -293,7 +293,7 @@ test_result_t test_affinity_info_level2(void) */ test_result_t test_affinity_info_level3(void) { -#ifndef AARCH32 +#ifdef __aarch64__ int expected_values[3]; uint64_t target_mpid; int32_t aff_info; diff --git a/tftf/tests/runtime_services/standard_service/sdei/system_tests/sdei_entrypoint.S b/tftf/tests/runtime_services/standard_service/sdei/system_tests/sdei_entrypoint.S index 27ffa39eb..655bb2480 100644 --- a/tftf/tests/runtime_services/standard_service/sdei/system_tests/sdei_entrypoint.S +++ b/tftf/tests/runtime_services/standard_service/sdei/system_tests/sdei_entrypoint.S @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, Arm Limited. All rights reserved. + * Copyright (c) 2018-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -16,7 +16,7 @@ .local event_handled .comm event_handled, PLATFORM_CORE_COUNT * 4, 8 -#ifdef AARCH64 +#ifdef __aarch64__ func sdei_entrypoint stp xzr, x30, [sp, #-16]! bl sdei_event_handler diff --git a/tftf/tests/xlat_lib_v2/xlat_lib_v2_tests.c b/tftf/tests/xlat_lib_v2/xlat_lib_v2_tests.c index a62bb918a..519ff16b2 100644 --- a/tftf/tests/xlat_lib_v2/xlat_lib_v2_tests.c +++ b/tftf/tests/xlat_lib_v2/xlat_lib_v2_tests.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019, Arm Limited. All rights reserved. + * Copyright (c) 2019-2020, Arm Limited. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -67,7 +67,7 @@ static unsigned long long va2pa(uintptr_t base_va) * Performs stage 1 address translation for the current EL, with * read permissions. */ -#ifdef AARCH32 +#ifndef __aarch64__ if (IS_IN_HYP()) write_ats1hr(base_va); else @@ -497,7 +497,7 @@ test_result_t xlat_lib_v2_basic_test(void) return TEST_RESULT_FAIL; } -#if AARCH64 +#ifdef __aarch64__ unsigned long long memory_base_pa; /* @@ -644,7 +644,7 @@ test_result_t xlat_lib_v2_alignment_test(void) return TEST_RESULT_FAIL; } -#if AARCH64 +#ifdef __aarch64__ /* * 3) Try to allocate at least 1 GB aligned. There is only room for this * in AArch64. |