Skip to content

Commit

Permalink
net: smc_close: mark expected switch fall-through
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.

Notice that in this particular case I placed the "fall through" comment
on its own line, which is what GCC is expecting to find.

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 Oct 24, 2017
1 parent e3cf397 commit 7f6b437
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion net/smc/smc_close.c
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,8 @@ static void smc_close_passive_work(struct work_struct *work)
case SMC_PEERCLOSEWAIT1:
if (rxflags->peer_done_writing)
sk->sk_state = SMC_PEERCLOSEWAIT2;
/* fall through to check for closing */
/* fall through */
/* to check for closing */
case SMC_PEERCLOSEWAIT2:
case SMC_PEERFINCLOSEWAIT:
if (!smc_cdc_rxed_any_close(&smc->conn))
Expand Down

0 comments on commit 7f6b437

Please sign in to comment.