Commit 3aae97c8 authored by Alexandre Courbot's avatar Alexandre Courbot Committed by Arnd Bergmann

ARM: trusted_foundations: fix compile error on non-SMP

The setup_max_cpus variable is only defined if CONFIG_SMP is set. Add
a preprocessor condition to avoid the following compilation error if
CONFIG_SMP is not set:

    arch/arm/include/asm/trusted_foundations.h: In function 'register_trusted_foundations':
    arch/arm/include/asm/trusted_foundations.h:57:2: error: 'setup_max_cpus' undeclared (first use in this function)
Signed-off-by: default avatarAlexandre Courbot <acourbot@nvidia.com>
Reported-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
Acked-by: default avatarStephen Warren <swarren@nvidia.com>
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
parent 756abc8d
......@@ -54,7 +54,9 @@ static inline void register_trusted_foundations(
*/
pr_err("No support for Trusted Foundations, continuing in degraded mode.\n");
pr_err("Secondary processors as well as CPU PM will be disabled.\n");
#if IS_ENABLED(CONFIG_SMP)
setup_max_cpus = 0;
#endif
cpu_idle_poll_ctrl(true);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment