Refactor the last clauses so that a violation of
MISRA C Rule 16.2 is resolved (A switch label shall only be used
when the most closely-enclosing compound statement is the body of
a switch statement). The switch clause ending with the
pseudo keyword "fallthrough" is an allowed exception to Rule 16.3.
No functional change.
Suggested-by: Jan Beulich <jbeulich@suse.com>
Signed-off-by: Nicola Vetrini <nicola.vetrini@bugseng.com>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
case APIC_EOI:
case APIC_ESR:
- if ( val )
- {
+ if ( !val )
+ break;
+ fallthrough;
default:
return X86EMUL_EXCEPTION;
- }
}
vlapic_reg_write(v, array_index_nospec(offset, PAGE_SIZE), val);