Project

General

Profile

Bug #9415

bnxe: this statement may fall through

Added by Toomas Soome over 1 year ago. Updated about 1 year ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
driver - device drivers
Start date:
2018-03-28
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

issue found by gcc 7 build:

    ../../common/io/bnxe/577xx/common/bnxe_clc.c:7024:6: error: this statement may fall through [-Werror=implicit-fallthrough=]
       if (!vars->link_up)
          ^
    ../../common/io/bnxe/577xx/common/bnxe_clc.c:7026:2: note: here
      case ELINK_LED_MODE_ON:
      ^~~~
    ../../common/io/bnxe/577xx/common/bnxe_clc.c: In function 'elink_phy_def_cfg':
    ../../common/io/bnxe/577xx/common/bnxe_clc.c:13311:19: error: this statement may fall through [-Werror=implicit-fallthrough=]
       phy->req_duplex = DUPLEX_HALF;
    ../../common/io/bnxe/577xx/common/bnxe_clc.c:13312:2: note: here
      case PORT_FEATURE_LINK_SPEED_10M_FULL:
      ^~~~
    ../../common/io/bnxe/577xx/common/bnxe_clc.c:13316:19: error: this statement may fall through [-Werror=implicit-fallthrough=]
       phy->req_duplex = DUPLEX_HALF;
    ../../common/io/bnxe/577xx/common/bnxe_clc.c:13317:2: note: here
      case PORT_FEATURE_LINK_SPEED_100M_FULL:
      ^~~~

    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_hw_init_reset.c: In function 'lm_chip_init':
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_hw_init_reset.c:4615:12: error: this statement may fall through [-Werror=implicit-fallthrough=]
             if (LM_STATUS_SUCCESS != lm_status)
                ^
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_hw_init_reset.c:4619:5: note: here
         case LM_LOADER_RESPONSE_LOAD_COMMON:
         ^~~~
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_hw_init_reset.c:4637:9: error: this statement may fall through [-Werror=implicit-fallthrough=]
             lm_init_intmem_common(pdev);
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_hw_init_reset.c:4647:5: note: here
         case LM_LOADER_RESPONSE_LOAD_PORT:
         ^~~~
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_hw_init_reset.c:4673:9: error: this statement may fall through [-Werror=implicit-fallthrough=]
             lm_init_intmem_port(pdev);
             ^~~~~~~~~~~~~~~~~~~~~~~~~
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_hw_init_reset.c:4676:5: note: here
         case LM_LOADER_RESPONSE_LOAD_FUNCTION:
         ^~~~

    In file included from ../../common/io/bnxe/577xx/drivers/common/lm/include/lm5710.h:76:0,
                     from ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_resc.c:37:
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_resc.c: In function 'lm_clear_chain_sb_cons_idx':
    ../../common/io/bnxe/577xx/drivers/common/include/debug.h:321:12: error: this statement may fall through [-Werror=implicit-fallthrough=]
             if (_c)                                                               \
                ^
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_resc.c:112:9: note: in expansion of macro 'DbgBreakIfAll'
             DbgBreakIfAll(rd_val_32 != 0);
             ^
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_resc.c:114:5: note: here
         case STATUS_BLOCK_NORMAL_TYPE:
         ^~~~

    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_devinfo.c: In function 'lm_get_shmem_mf_mac_info':
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_devinfo.c:2341:60: error: this statement may fall through [-Werror=implicit-fallthrough=]
                 if ( CHIP_IS_E1x(pdev) || IS_SD_UFP_MODE(pdev) || IS_SD_BD_MODE(pdev))
    ../../common/io/bnxe/577xx/drivers/common/lm/device/lm_devinfo.c:2349:5: note: here
         case MULTI_FUNCTION_SI:
         ^~~~

    ../../common/io/bnxe/577xx/drivers/common/ecore/ecore_sp_verbs.c: In function 'ecore_mcast_validate_e2':
    ../../common/io/bnxe/577xx/drivers/common/ecore/ecore_sp_verbs.c:3391:3: error: this statement may fall through [-Werror=implicit-fallthrough=]
       o->set_registry_size(o, 0);
       ^~~~~~~~~~~~~~~~~~~~~~~~~~
    ../../common/io/bnxe/577xx/drivers/common/ecore/ecore_sp_verbs.c:3395:2: note: here
      case ECORE_MCAST_CMD_RESTORE:
      ^~~~
    ../../common/io/bnxe/577xx/drivers/common/ecore/ecore_sp_verbs.c: In function 'ecore_mcast_validate_e1':
    ../../common/io/bnxe/577xx/drivers/common/ecore/ecore_sp_verbs.c:3697:3: error: this statement may fall through [-Werror=implicit-fallthrough=]
       o->set_registry_size(o, 0);
       ^~~~~~~~~~~~~~~~~~~~~~~~~~
    ../../common/io/bnxe/577xx/drivers/common/ecore/ecore_sp_verbs.c:3701:2: note: here
      case ECORE_MCAST_CMD_RESTORE:
      ^~~~

    ../../common/io/bnxe/577xx/drivers/common/lm/l5/lm_l5.c: In function 'lm_sc_service_eq_intr':
    ../../common/io/bnxe/577xx/drivers/common/lm/l5/lm_l5.c:1717:13: error: this statement may fall through [-Werror=implicit-fallthrough=]
                 lm_sc_handle_tcp_event(pdev, cid, kcqe->op_code);
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    ../../common/io/bnxe/577xx/drivers/common/lm/l5/lm_l5.c:1719:9: note: here
             default:
             ^~~~~~~

    cc1: all warnings being treated as errors

History

#1

Updated by Electric Monk about 1 year ago

  • % Done changed from 90 to 100
  • Status changed from In Progress to Closed

git commit 6680ee99638d23c9c2561c782eb1df2176e04698

commit  6680ee99638d23c9c2561c782eb1df2176e04698
Author: Toomas Soome <tsoome@me.com>
Date:   2018-07-09T14:55:54.000Z

    9415 bnxe: this statement may fall through
    Reviewed by: Andrew Stormont <andyjstormont@gmail.com>
    Reviewed by: Yuri Pankov <yuripv@yuripv.net>
    Approved by: Robert Mustacchi <rm@joyent.com>

Also available in: Atom PDF