* [PATCH] net: wan: sdla: Mark expected switch fall-through
@ 2019-07-29 20:01 Gustavo A. R. Silva
2019-07-29 21:09 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Gustavo A. R. Silva @ 2019-07-29 20:01 UTC (permalink / raw)
To: David S. Miller; +Cc: netdev, linux-kernel, Gustavo A. R. Silva, Kees Cook
Mark switch cases where we are expecting to fall through.
This patch fixes the following warning (Building: i386):
drivers/net/wan/sdla.c: In function ‘sdla_errors’:
drivers/net/wan/sdla.c:414:7: warning: this statement may fall through [-Wimplicit-fallthrough=]
if (cmd == SDLA_INFORMATION_WRITE)
^
drivers/net/wan/sdla.c:417:3: note: here
default:
^~~~~~~
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
---
drivers/net/wan/sdla.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/wan/sdla.c b/drivers/net/wan/sdla.c
index a9ac3f37b904..e2e679a01b65 100644
--- a/drivers/net/wan/sdla.c
+++ b/drivers/net/wan/sdla.c
@@ -413,6 +413,7 @@ static void sdla_errors(struct net_device *dev, int cmd, int dlci, int ret, int
case SDLA_RET_NO_BUFS:
if (cmd == SDLA_INFORMATION_WRITE)
break;
+ /* Else, fall through */
default:
netdev_dbg(dev, "Cmd 0x%02X generated return code 0x%02X\n",
--
2.22.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] net: wan: sdla: Mark expected switch fall-through
2019-07-29 20:01 [PATCH] net: wan: sdla: Mark expected switch fall-through Gustavo A. R. Silva
@ 2019-07-29 21:09 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2019-07-29 21:09 UTC (permalink / raw)
To: gustavo; +Cc: netdev, linux-kernel, keescook
From: "Gustavo A. R. Silva" <gustavo@embeddedor.com>
Date: Mon, 29 Jul 2019 15:01:39 -0500
> Mark switch cases where we are expecting to fall through.
>
> This patch fixes the following warning (Building: i386):
>
> drivers/net/wan/sdla.c: In function ‘sdla_errors’:
> drivers/net/wan/sdla.c:414:7: warning: this statement may fall through [-Wimplicit-fallthrough=]
> if (cmd == SDLA_INFORMATION_WRITE)
> ^
> drivers/net/wan/sdla.c:417:3: note: here
> default:
> ^~~~~~~
>
> Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Applied.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-07-29 21:09 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-29 20:01 [PATCH] net: wan: sdla: Mark expected switch fall-through Gustavo A. R. Silva
2019-07-29 21:09 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).