10016 bnxe: macro expands to multiple statements

Review Request #1302 - Created Nov. 30, 2018 and submitted

Information
Toomas Soome
illumos-gate
10016
b988458...
Reviewers
general
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c: In function 'lm_idle_chk':
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:95:9: error: macro expands to multiple statements [-Werror=multistatement-macros]
         b_test_chip=0; \
         ^~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:141:10: note: in expansion of macro 'IDLE_CHK_CHIP_MASK_CHK'
          IDLE_CHK_CHIP_MASK_CHK(chip_mask); \
          ^~~~~~~~~~~~~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:171:17: note: in expansion of macro 'IDLE_CHK_3'
                 IDLE_CHK_3(chip_mask, offset1, offset2, condition, severity, fail_msg); \
                 ^~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:736:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0xF, PBF_REG_DISABLE_NEW_TASK_PROC_P0, PBF_REG_P0_CREDIT, PBF_REG_P0_INIT_CRD, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: P0 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:170:13: note: some parts of macro expansion are not guarded by this 'if' clause
             if (!val) \
             ^~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:736:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0xF, PBF_REG_DISABLE_NEW_TASK_PROC_P0, PBF_REG_P0_CREDIT, PBF_REG_P0_INIT_CRD, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: P0 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:95:9: error: macro expands to multiple statements [-Werror=multistatement-macros]
         b_test_chip=0; \
         ^~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:141:10: note: in expansion of macro 'IDLE_CHK_CHIP_MASK_CHK'
          IDLE_CHK_CHIP_MASK_CHK(chip_mask); \
          ^~~~~~~~~~~~~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:171:17: note: in expansion of macro 'IDLE_CHK_3'
                 IDLE_CHK_3(chip_mask, offset1, offset2, condition, severity, fail_msg); \
                 ^~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:738:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0xF, PBF_REG_DISABLE_NEW_TASK_PROC_P1, PBF_REG_P1_CREDIT, PBF_REG_P1_INIT_CRD, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: P1 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:170:13: note: some parts of macro expansion are not guarded by this 'if' clause
             if (!val) \
             ^~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:738:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0xF, PBF_REG_DISABLE_NEW_TASK_PROC_P1, PBF_REG_P1_CREDIT, PBF_REG_P1_INIT_CRD, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: P1 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:95:9: error: macro expands to multiple statements [-Werror=multistatement-macros]
         b_test_chip=0; \
         ^~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:141:10: note: in expansion of macro 'IDLE_CHK_CHIP_MASK_CHK'
          IDLE_CHK_CHIP_MASK_CHK(chip_mask); \
          ^~~~~~~~~~~~~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:171:17: note: in expansion of macro 'IDLE_CHK_3'
                 IDLE_CHK_3(chip_mask, offset1, offset2, condition, severity, fail_msg); \
                 ^~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:742:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q0, PBF_REG_CREDIT_Q0, PBF_REG_INIT_CRD_Q0, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q0 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:170:13: note: some parts of macro expansion are not guarded by this 'if' clause
             if (!val) \
             ^~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:742:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q0, PBF_REG_CREDIT_Q0, PBF_REG_INIT_CRD_Q0, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q0 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:95:9: error: macro expands to multiple statements [-Werror=multistatement-macros]
         b_test_chip=0; \
         ^~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:141:10: note: in expansion of macro 'IDLE_CHK_CHIP_MASK_CHK'
          IDLE_CHK_CHIP_MASK_CHK(chip_mask); \
          ^~~~~~~~~~~~~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:171:17: note: in expansion of macro 'IDLE_CHK_3'
                 IDLE_CHK_3(chip_mask, offset1, offset2, condition, severity, fail_msg); \
                 ^~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:744:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q1, PBF_REG_CREDIT_Q1, PBF_REG_INIT_CRD_Q1, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q1 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:170:13: note: some parts of macro expansion are not guarded by this 'if' clause
             if (!val) \
             ^~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:744:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q1, PBF_REG_CREDIT_Q1, PBF_REG_INIT_CRD_Q1, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q1 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:95:9: error: macro expands to multiple statements [-Werror=multistatement-macros]
         b_test_chip=0; \
         ^~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:141:10: note: in expansion of macro 'IDLE_CHK_CHIP_MASK_CHK'
          IDLE_CHK_CHIP_MASK_CHK(chip_mask); \
          ^~~~~~~~~~~~~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:171:17: note: in expansion of macro 'IDLE_CHK_3'
                 IDLE_CHK_3(chip_mask, offset1, offset2, condition, severity, fail_msg); \
                 ^~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:746:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q2, PBF_REG_CREDIT_Q2, PBF_REG_INIT_CRD_Q2, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q2 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:170:13: note: some parts of macro expansion are not guarded by this 'if' clause
             if (!val) \
             ^~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:746:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q2, PBF_REG_CREDIT_Q2, PBF_REG_INIT_CRD_Q2, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q2 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:95:9: error: macro expands to multiple statements [-Werror=multistatement-macros]
         b_test_chip=0; \
         ^~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:141:10: note: in expansion of macro 'IDLE_CHK_CHIP_MASK_CHK'
          IDLE_CHK_CHIP_MASK_CHK(chip_mask); \
          ^~~~~~~~~~~~~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:171:17: note: in expansion of macro 'IDLE_CHK_3'
                 IDLE_CHK_3(chip_mask, offset1, offset2, condition, severity, fail_msg); \
                 ^~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:748:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q3, PBF_REG_CREDIT_Q3, PBF_REG_INIT_CRD_Q3, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q3 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:170:13: note: some parts of macro expansion are not guarded by this 'if' clause
             if (!val) \
             ^~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:748:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q3, PBF_REG_CREDIT_Q3, PBF_REG_INIT_CRD_Q3, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q3 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:95:9: error: macro expands to multiple statements [-Werror=multistatement-macros]
         b_test_chip=0; \
         ^~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:141:10: note: in expansion of macro 'IDLE_CHK_CHIP_MASK_CHK'
          IDLE_CHK_CHIP_MASK_CHK(chip_mask); \
          ^~~~~~~~~~~~~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:171:17: note: in expansion of macro 'IDLE_CHK_3'
                 IDLE_CHK_3(chip_mask, offset1, offset2, condition, severity, fail_msg); \
                 ^~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:750:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q4, PBF_REG_CREDIT_Q4, PBF_REG_INIT_CRD_Q4, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q4 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:170:13: note: some parts of macro expansion are not guarded by this 'if' clause
             if (!val) \
             ^~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:750:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q4, PBF_REG_CREDIT_Q4, PBF_REG_INIT_CRD_Q4, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q4 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:95:9: error: macro expands to multiple statements [-Werror=multistatement-macros]
         b_test_chip=0; \
         ^~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:141:10: note: in expansion of macro 'IDLE_CHK_CHIP_MASK_CHK'
          IDLE_CHK_CHIP_MASK_CHK(chip_mask); \
          ^~~~~~~~~~~~~~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:171:17: note: in expansion of macro 'IDLE_CHK_3'
                 IDLE_CHK_3(chip_mask, offset1, offset2, condition, severity, fail_msg); \
                 ^~~~~~~~~~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:752:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q5, PBF_REG_CREDIT_Q5, PBF_REG_INIT_CRD_Q5, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q5 credit is not equal to init_crd");
     ^~~~~~~~~~
In file included from ../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:53:
../../common/io/bnxe/577xx/drivers/common/lm/device/hw_debug.h:170:13: note: some parts of macro expansion are not guarded by this 'if' clause
             if (!val) \
             ^~
../../common/io/bnxe/577xx/drivers/common/lm/device/bnxe_hw_debug.c:752:5: note: in expansion of macro 'IDLE_CHK_5'
     IDLE_CHK_5(0x10, PBF_REG_DISABLE_NEW_TASK_PROC_Q5, PBF_REG_CREDIT_Q5, PBF_REG_INIT_CRD_Q5, (val1 != val2), IDLE_CHK_ERROR_NO_TRAFFIC, "PBF: Q5 credit is not equal to init_crd");
     ^~~~~~~~~~
cc1: all warnings being treated as errors

  
Robert Mustacchi
C Fraire
Toomas Soome
Review request changed

Status: Closed (submitted)

Loading...