summaryrefslogtreecommitdiff
path: root/arch/arm64/kernel
diff options
context:
space:
mode:
authorWill Deacon <will@kernel.org>2019-07-29 11:39:45 +0100
committerWill Deacon <will@kernel.org>2019-07-29 11:59:15 +0100
commit75a382f1c9e5092db10ad1e2111633d61b65e578 (patch)
treece72838d550a43350ccdf05e93c2521d2f17929f /arch/arm64/kernel
parent0d7fd70f26039bd4b33444ca47f0e69ce3ae0354 (diff)
arm64: hw_breakpoint: Fix warnings about implicit fallthrough
Now that -Wimplicit-fallthrough is passed to GCC by default, the kernel build has suddenly got noisy. Annotate the two fall-through cases in our hw_breakpoint implementation, since they are both intentional. Reported-by: Anders Roxell <anders.roxell@linaro.org> Signed-off-by: Will Deacon <will@kernel.org>
Diffstat (limited to 'arch/arm64/kernel')
-rw-r--r--arch/arm64/kernel/hw_breakpoint.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm64/kernel/hw_breakpoint.c b/arch/arm64/kernel/hw_breakpoint.c
index 67b3bae50b92..38ee1514cd9c 100644
--- a/arch/arm64/kernel/hw_breakpoint.c
+++ b/arch/arm64/kernel/hw_breakpoint.c
@@ -540,10 +540,14 @@ int hw_breakpoint_arch_parse(struct perf_event *bp,
/* Allow halfword watchpoints and breakpoints. */
if (hw->ctrl.len == ARM_BREAKPOINT_LEN_2)
break;
+
+ /* Fallthrough */
case 3:
/* Allow single byte watchpoint. */
if (hw->ctrl.len == ARM_BREAKPOINT_LEN_1)
break;
+
+ /* Fallthrough */
default:
return -EINVAL;
}