]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
vt: annotate implicit fall throughs
authorMathieu Malaterre <malat@debian.org>
Mon, 14 Jan 2019 20:41:13 +0000 (21:41 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 18 Jan 2019 12:48:52 +0000 (13:48 +0100)
There is a plan to build the kernel with -Wimplicit-fallthrough and
these places in the code produced warnings (W=1). Fix them up.

This commit remove the following warning:

  drivers/tty/vt/vt.c:2112:6: warning: this statement may fall through [-Wimplicit-fallthrough=]
  drivers/tty/vt/vt.c:2237:6: warning: this statement may fall through [-Wimplicit-fallthrough=]

Signed-off-by: Mathieu Malaterre <malat@debian.org>
Acked-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/vt/vt.c

index 7cfa1996331644205a14c742dfca83514a769baa..ec55336abf95ebaa27548cec279620c9f82a20d3 100644 (file)
@@ -2111,6 +2111,7 @@ static void do_con_trol(struct tty_struct *tty, struct vc_data *vc, int c)
                lf(vc);
                if (!is_kbd(vc, lnm))
                        return;
+               /* fall through */
        case 13:
                cr(vc);
                return;
@@ -2236,6 +2237,7 @@ static void do_con_trol(struct tty_struct *tty, struct vc_data *vc, int c)
                vc->vc_ques = (c == '?');
                if (vc->vc_ques)
                        return;
+               /* fall through */
        case ESgetpars:
                if (c == ';' && vc->vc_npar < NPAR - 1) {
                        vc->vc_npar++;