qed: qed_dev: Mark expected switch fall-throughs
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Tue, 7 Aug 2018 23:25:57 +0000 (18:25 -0500)
committerDavid S. Miller <davem@davemloft.net>
Wed, 8 Aug 2018 00:54:20 +0000 (17:54 -0700)
In preparation to enabling -Wimplicit-fallthrough, mark switch cases
where we are expecting to fall through.

Notice that in this particular case, I replaced the code comments with
a proper "fall through" annotation, which is what GCC is expecting
to find.

Addresses-Coverity-ID: 114809 ("Missing break in switch")
Addresses-Coverity-ID: 114810 ("Missing break in switch")
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qed/qed_dev.c

index d1ae11a..016ca8a 100644 (file)
@@ -1789,14 +1789,14 @@ int qed_hw_init(struct qed_dev *cdev, struct qed_hw_init_params *p_params)
                                                p_hwfn->hw_info.hw_mode);
                        if (rc)
                                break;
-               /* Fall into */
+               /* Fall through */
                case FW_MSG_CODE_DRV_LOAD_PORT:
                        rc = qed_hw_init_port(p_hwfn, p_hwfn->p_main_ptt,
                                              p_hwfn->hw_info.hw_mode);
                        if (rc)
                                break;
 
-               /* Fall into */
+               /* Fall through */
                case FW_MSG_CODE_DRV_LOAD_FUNCTION:
                        rc = qed_hw_init_pf(p_hwfn, p_hwfn->p_main_ptt,
                                            p_params->p_tunn,