Skip to content

Commit

Permalink
net: netrom: nr_route: mark expected switch fall-throughs
Browse files Browse the repository at this point in the history
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Signed-off-by: Gustavo A. R. Silva <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
  • Loading branch information
GustavoARSilva authored and davem330 committed Nov 1, 2017
1 parent 4c31606 commit 31f74f0
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions net/netrom/nr_route.c
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,7 @@ static int __must_check nr_add_node(ax25_address *nr, const char *mnemonic,
case 3:
re_sort_routes(nr_node, 0, 1);
re_sort_routes(nr_node, 1, 2);
/* fall through */
case 2:
re_sort_routes(nr_node, 0, 1);
case 1:
Expand Down Expand Up @@ -357,6 +358,7 @@ static int nr_del_node(ax25_address *callsign, ax25_address *neighbour, struct n
switch (i) {
case 0:
nr_node->routes[0] = nr_node->routes[1];
/* fall through */
case 1:
nr_node->routes[1] = nr_node->routes[2];
case 2:
Expand Down Expand Up @@ -526,6 +528,7 @@ void nr_rt_device_down(struct net_device *dev)
switch (i) {
case 0:
t->routes[0] = t->routes[1];
/* fall through */
case 1:
t->routes[1] = t->routes[2];
case 2:
Expand Down

0 comments on commit 31f74f0

Please sign in to comment.