Skip to contentSkip to conversation

arm64: Mark call_smc_arch_workaround_1 as __maybe_unused

PATCH Applied Nathan Chancellor 2 participants 2 messages Mar 10, 2020 – Mar 11, 2020 arm64

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 arm64: Mark call_smc_arch_workaround_1 as __maybe_unused

When building allnoconfig:

arch/arm64/kernel/cpu_errata.c:174:13: warning: unused function 'call_smc_arch_workaround_1' [-Wunused-function] static void call_smc_arch_workaround_1(void)

            ^

1 warning generated.

Follow arch/arm and mark this function as __maybe_unused.

Fixes 4db61fef16a1 ("arm64: kvm: Modernize __smccc_workaround_1_smc_start annotations")
---
 arch/arm64/kernel/cpu_errata.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/kernel/cpu_errata.c +1 -1
index 6a2ca339741c..df56d2295d16 100644
@@ -171,7 +171,7 @@ static void install_bp_hardening_cb(bp_hardening_cb_t fn,
 
 #include <linux/arm-smccc.h>
 
-static void call_smc_arch_workaround_1(void)
+static void __maybe_unused call_smc_arch_workaround_1(void)
 {
 	arm_smccc_1_1_smc(ARM_SMCCC_ARCH_WORKAROUND_1, NULL);
 }
Signature · 1 line
2.26.0.rc1
maintainer Applied
#1 lore raw
Quoted 5 lines · Nathan Chancellor

When building allnoconfig:

arch/arm64/kernel/cpu_errata.c:174:13: warning: unused function 'call_smc_arch_workaround_1' [-Wunused-function] static void call_smc_arch_workaround_1(void)

Quoted 7 lines
            ^

1 warning generated.

Follow arch/arm and mark this function as __maybe_unused.

Fixes 4db61fef16a1 ("arm64: kvm: Modernize __smccc_workaround_1_smc_start annotations")

Applied. Thanks.

Signature · 1 line
Catalin