kprobes/x86: Fix fall-through warnings for Clang
authorGustavo A. R. Silva <gustavoars@kernel.org>
Fri, 20 Nov 2020 18:30:44 +0000 (12:30 -0600)
committerPeter Zijlstra <peterz@infradead.org>
Wed, 9 Dec 2020 16:08:58 +0000 (17:08 +0100)
In preparation to enable -Wimplicit-fallthrough for Clang, fix a warning
by explicitly adding a break statement instead of just letting the code
fall through to the next case.

Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://github.com/KSPP/linux/issues/115
arch/x86/kernel/kprobes/core.c

index 39f7d8c3c064bbf4dcb13f364238784e40e9839a..a65e9e97857f8aa6ec8f6252cc8a99eaa70f7c2b 100644 (file)
@@ -864,6 +864,7 @@ static void resume_execution(struct kprobe *p, struct pt_regs *regs,
                        p->ainsn.boostable = true;
                        goto no_change;
                }
+               break;
        default:
                break;
        }