From 6fcebf1302b43e7a610d1d2fa89f41e693249aa5 Mon Sep 17 00:00:00 2001 From: "Gustavo A. R. Silva" Date: Fri, 25 Jan 2019 12:39:03 -0600 Subject: x86/kernel: Mark expected switch-case fall-throughs In preparation to enable -Wimplicit-fallthrough by default, mark switch-case statements where fall-through is intentional, explicitly in order to fix a couple of -Wimplicit-fallthrough warnings. Warning level 3 was used: -Wimplicit-fallthrough=3. [ bp: Massasge and trim commit message. ] Signed-off-by: Gustavo A. R. Silva Signed-off-by: Borislav Petkov Cc: "Eric W. Biederman" Cc: "H. Peter Anvin" Cc: Andrew Morton Cc: Baoquan He Cc: Christophe Leroy Cc: Daniel Thompson Cc: David Wang Cc: Douglas Anderson Cc: Frederic Weisbecker Cc: Ingo Molnar Cc: Jan Beulich Cc: Kees Cook Cc: Masami Hiramatsu Cc: Mike Rapoport Cc: Nicolai Stange Cc: Oleg Nesterov Cc: Pu Wen Cc: Suravee Suthikulpanit Cc: Thomas Gleixner Cc: Will Deacon Cc: x86-ml Link: https://lkml.kernel.org/r/20190125183903.GA4712@embeddedor --- arch/x86/kernel/uprobes.c | 1 + 1 file changed, 1 insertion(+) (limited to 'arch/x86/kernel/uprobes.c') diff --git a/arch/x86/kernel/uprobes.c b/arch/x86/kernel/uprobes.c index 843feb94a950..ccf03416e434 100644 --- a/arch/x86/kernel/uprobes.c +++ b/arch/x86/kernel/uprobes.c @@ -745,6 +745,7 @@ static int branch_setup_xol_ops(struct arch_uprobe *auprobe, struct insn *insn) * OPCODE1() of the "short" jmp which checks the same condition. */ opc1 = OPCODE2(insn) - 0x10; + /* fall through */ default: if (!is_cond_jmp_opcode(opc1)) return -ENOSYS; -- cgit v1.2.3