From: Gustavo A. R. Silva Date: Sun, 5 Aug 2018 04:18:25 +0000 (-0500) Subject: kdb: kdb_keyboard: mark expected switch fall-throughs X-Git-Tag: Ubuntu-5.4-5.4.0-11.14~4116^2~1 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=01cb37351bafc1b44b962842926210115e231f0a;p=mirror_ubuntu-focal-kernel.git kdb: kdb_keyboard: mark expected switch fall-throughs In preparation to enabling -Wimplicit-fallthrough, mark switch cases where we are expecting to fall through. Notice that in this particular case, I replaced the code comments with a proper "fall through" annotation, which is what GCC is expecting to find. Signed-off-by: Gustavo A. R. Silva Reviewed-by: Daniel Thompson Signed-off-by: Daniel Thompson --- diff --git a/kernel/debug/kdb/kdb_keyboard.c b/kernel/debug/kdb/kdb_keyboard.c index 118527aa60ea..750497b0003a 100644 --- a/kernel/debug/kdb/kdb_keyboard.c +++ b/kernel/debug/kdb/kdb_keyboard.c @@ -173,11 +173,11 @@ int kdb_get_kbd_char(void) case KT_LATIN: if (isprint(keychar)) break; /* printable characters */ - /* drop through */ + /* fall through */ case KT_SPEC: if (keychar == K_ENTER) break; - /* drop through */ + /* fall through */ default: return -1; /* ignore unprintables */ }