coding guidelines: comply with MISRA Rule 20.9

- avoid to use undefined macros in #if expressions

Signed-off-by: Hess Nathan <nhess@baumer.com>
This commit is contained in:
Hess Nathan 2024-04-29 11:24:20 +02:00 committed by Alberto Escolar
commit cbd9b37ef5
2 changed files with 2 additions and 2 deletions

View file

@ -65,7 +65,7 @@ FUNC_NORETURN void z_prep_c(void *arg)
#endif
#endif
#if CONFIG_X86_STACK_PROTECTION
#ifdef CONFIG_X86_STACK_PROTECTION
unsigned int num_cpus = arch_num_cpus();
for (int i = 0; i < num_cpus; i++) {

View file

@ -1355,7 +1355,7 @@ void z_x86_mmu_init(void)
#endif
}
#if CONFIG_X86_STACK_PROTECTION
#ifdef CONFIG_X86_STACK_PROTECTION
__pinned_func
void z_x86_set_stack_guard(k_thread_stack_t *stack)
{