• Gustavo A. R. Silva's avatar
    watchdog: machzwd: Mark expected switch fall-through · 0843bdc1
    Gustavo A. R. Silva authored
    In preparation to enabling -Wimplicit-fallthrough, mark switch
    cases where we are expecting to fall through.
    
    This patch fixes the following warnings:
    
    drivers/watchdog/machzwd.c: In function ‘zf_set_timer’:
    ./arch/x86/include/asm/io.h:355:14: warning: this statement may fall through [-Wimplicit-fallthrough=]
     #define outw outw
    drivers/watchdog/machzwd.c:80:53: note: in expansion of macro ‘outw’
     #define zf_writew(port, data)  { outb(port, INDEX); outw(data, DATA_W); }
                                                         ^~~~
    drivers/watchdog/machzwd.c:179:3: note: in expansion of macro ‘zf_writew’
       zf_writew(COUNTER_1, new);
       ^~~~~~~~~
    drivers/watchdog/machzwd.c:180:2: note: here
      case WD2:
      ^~~~
    
    Warning level 3 was used: -Wimplicit-fallthrough=3
    
    This patch is part of the ongoing efforts to enable
    -Wimplicit-fallthrough.
    Signed-off-by: default avatarGustavo A. R. Silva <gustavo@embeddedor.com>
    Reviewed-by: default avatarGuenter Roeck <linux@roeck-us.net>
    Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
    Signed-off-by: default avatarWim Van Sebroeck <wim@linux-watchdog.org>
    0843bdc1
machzwd.c 9.85 KB