summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGustavo A. R. Silva <gustavoars@kernel.org>2021-07-12 18:03:35 +0200
committerGustavo A. R. Silva <gustavoars@kernel.org>2021-07-12 18:03:35 +0200
commit1adee589cd6da2ead7f1b5dd82419eac59a2e2b0 (patch)
tree0620256561182c23b82f599431226e5ad33db5cd
parentdrm/i915: Fix fall-through warning for Clang (diff)
downloadlinux-1adee589cd6da2ead7f1b5dd82419eac59a2e2b0.tar.xz
linux-1adee589cd6da2ead7f1b5dd82419eac59a2e2b0.zip
kernel: debug: Fix unreachable code in gdb_serial_stub()
Fix the following warning: kernel/debug/gdbstub.c:1049:4: warning: fallthrough annotation in unreachable code [-Wimplicit-fallthrough] fallthrough; ^ include/linux/compiler_attributes.h:210:41: note: expanded from macro 'fallthrough' # define fallthrough __attribute__((__fallthrough__) by placing the fallthrough; statement inside ifdeffery. Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
-rw-r--r--kernel/debug/gdbstub.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/debug/gdbstub.c b/kernel/debug/gdbstub.c
index 8372897402f4..b6f28fad4307 100644
--- a/kernel/debug/gdbstub.c
+++ b/kernel/debug/gdbstub.c
@@ -1045,8 +1045,8 @@ int gdb_serial_stub(struct kgdb_state *ks)
gdb_cmd_detachkill(ks);
return DBG_PASS_EVENT;
}
-#endif
fallthrough;
+#endif
case 'C': /* Exception passing */
tmp = gdb_cmd_exception_pass(ks);
if (tmp > 0)