From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id DD861A04BB for ; Tue, 6 Oct 2020 11:44:06 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id D79F429AC; Tue, 6 Oct 2020 11:44:05 +0200 (CEST) Received: by dpdk.org (Postfix, from userid 1017) id 5DB671E35; Tue, 6 Oct 2020 11:44:05 +0200 (CEST) In-Reply-To: <20201005120910.189343-44-jiawenwu@trustnetic.com> References: <20201005120910.189343-44-jiawenwu@trustnetic.com> To: test-report@dpdk.org Cc: Jiawen Wu Message-Id: <20201006094405.5DB671E35@dpdk.org> Date: Tue, 6 Oct 2020 11:44:05 +0200 (CEST) From: checkpatch@dpdk.org Subject: [dpdk-test-report] |WARNING| pw79661 [PATCH v2 43/56] net/txgbe: add DCB support X-BeenThere: test-report@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: automatic DPDK test reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: test-report-bounces@dpdk.org Sender: "test-report" Test-Label: checkpatch Test-Status: WARNING http://dpdk.org/patch/79661 _coding style issues_ WARNING:BLOCK_COMMENT_STYLE: Block comments use a trailing */ on a separate line #384: FILE: drivers/net/txgbe/base/txgbe_dcb.h:28: + * If 8 traffic classes can be configured, the value is 0x80. */ WARNING:BLOCK_COMMENT_STYLE: Block comments use a trailing */ on a separate line #403: FILE: drivers/net/txgbe/base/txgbe_dcb.h:47: + * in 64B granularity.*/ WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_hw *' should also have an identifier name #450: FILE: drivers/net/txgbe/base/txgbe_dcb.h:94: +s32 txgbe_dcb_calculate_tc_credits_cee(struct txgbe_hw *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #450: FILE: drivers/net/txgbe/base/txgbe_dcb.h:94: +s32 txgbe_dcb_calculate_tc_credits_cee(struct txgbe_hw *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u32' should also have an identifier name #450: FILE: drivers/net/txgbe/base/txgbe_dcb.h:94: +s32 txgbe_dcb_calculate_tc_credits_cee(struct txgbe_hw *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8' should also have an identifier name #450: FILE: drivers/net/txgbe/base/txgbe_dcb.h:94: +s32 txgbe_dcb_calculate_tc_credits_cee(struct txgbe_hw *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_hw *' should also have an identifier name #454: FILE: drivers/net/txgbe/base/txgbe_dcb.h:98: +s32 txgbe_dcb_config_pfc(struct txgbe_hw *, u8, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8' should also have an identifier name #454: FILE: drivers/net/txgbe/base/txgbe_dcb.h:98: +s32 txgbe_dcb_config_pfc(struct txgbe_hw *, u8, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #454: FILE: drivers/net/txgbe/base/txgbe_dcb.h:98: +s32 txgbe_dcb_config_pfc(struct txgbe_hw *, u8, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #457: FILE: drivers/net/txgbe/base/txgbe_dcb.h:101: +void txgbe_dcb_unpack_pfc_cee(struct txgbe_dcb_config *, u8 *, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #457: FILE: drivers/net/txgbe/base/txgbe_dcb.h:101: +void txgbe_dcb_unpack_pfc_cee(struct txgbe_dcb_config *, u8 *, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #457: FILE: drivers/net/txgbe/base/txgbe_dcb.h:101: +void txgbe_dcb_unpack_pfc_cee(struct txgbe_dcb_config *, u8 *, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #458: FILE: drivers/net/txgbe/base/txgbe_dcb.h:102: +void txgbe_dcb_unpack_refill_cee(struct txgbe_dcb_config *, int, u16 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'int' should also have an identifier name #458: FILE: drivers/net/txgbe/base/txgbe_dcb.h:102: +void txgbe_dcb_unpack_refill_cee(struct txgbe_dcb_config *, int, u16 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u16 *' should also have an identifier name #458: FILE: drivers/net/txgbe/base/txgbe_dcb.h:102: +void txgbe_dcb_unpack_refill_cee(struct txgbe_dcb_config *, int, u16 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #459: FILE: drivers/net/txgbe/base/txgbe_dcb.h:103: +void txgbe_dcb_unpack_max_cee(struct txgbe_dcb_config *, u16 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u16 *' should also have an identifier name #459: FILE: drivers/net/txgbe/base/txgbe_dcb.h:103: +void txgbe_dcb_unpack_max_cee(struct txgbe_dcb_config *, u16 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #460: FILE: drivers/net/txgbe/base/txgbe_dcb.h:104: +void txgbe_dcb_unpack_bwgid_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'int' should also have an identifier name #460: FILE: drivers/net/txgbe/base/txgbe_dcb.h:104: +void txgbe_dcb_unpack_bwgid_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #460: FILE: drivers/net/txgbe/base/txgbe_dcb.h:104: +void txgbe_dcb_unpack_bwgid_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #461: FILE: drivers/net/txgbe/base/txgbe_dcb.h:105: +void txgbe_dcb_unpack_tsa_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'int' should also have an identifier name #461: FILE: drivers/net/txgbe/base/txgbe_dcb.h:105: +void txgbe_dcb_unpack_tsa_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #461: FILE: drivers/net/txgbe/base/txgbe_dcb.h:105: +void txgbe_dcb_unpack_tsa_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #462: FILE: drivers/net/txgbe/base/txgbe_dcb.h:106: +void txgbe_dcb_unpack_map_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'int' should also have an identifier name #462: FILE: drivers/net/txgbe/base/txgbe_dcb.h:106: +void txgbe_dcb_unpack_map_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #462: FILE: drivers/net/txgbe/base/txgbe_dcb.h:106: +void txgbe_dcb_unpack_map_cee(struct txgbe_dcb_config *, int, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #463: FILE: drivers/net/txgbe/base/txgbe_dcb.h:107: +u8 txgbe_dcb_get_tc_from_up(struct txgbe_dcb_config *, int, u8); WARNING:FUNCTION_ARGUMENTS: function definition argument 'int' should also have an identifier name #463: FILE: drivers/net/txgbe/base/txgbe_dcb.h:107: +u8 txgbe_dcb_get_tc_from_up(struct txgbe_dcb_config *, int, u8); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8' should also have an identifier name #463: FILE: drivers/net/txgbe/base/txgbe_dcb.h:107: +u8 txgbe_dcb_get_tc_from_up(struct txgbe_dcb_config *, int, u8); WARNING:BRACES: braces {} are not necessary for single statement blocks #563: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.c:90: + for (i = 0; i < 128; i++) { + wr32(hw, TXGBE_QARBTXCRED(i), 0); + } CHECK:BOOL_COMPARISON: Using comparison to false is error prone #678: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.c:205: + if (!((tc_count == 8 && vt_mode == false) || tc_count == 4)) WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_hw *' should also have an identifier name #698: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:9: +s32 txgbe_dcb_config_pfc_raptor(struct txgbe_hw *, u8, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8' should also have an identifier name #698: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:9: +s32 txgbe_dcb_config_pfc_raptor(struct txgbe_hw *, u8, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #698: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:9: +s32 txgbe_dcb_config_pfc_raptor(struct txgbe_hw *, u8, u8 *); WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_hw *' should also have an identifier name #701: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:12: +s32 txgbe_dcb_config_tc_stats_raptor(struct txgbe_hw *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_dcb_config *' should also have an identifier name #701: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:12: +s32 txgbe_dcb_config_tc_stats_raptor(struct txgbe_hw *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_hw *' should also have an identifier name #705: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:16: +s32 txgbe_dcb_config_tx_desc_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u16 *' should also have an identifier name #705: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:16: +s32 txgbe_dcb_config_tx_desc_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u16 *' should also have an identifier name #705: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:16: +s32 txgbe_dcb_config_tx_desc_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #705: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:16: +s32 txgbe_dcb_config_tx_desc_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #705: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:16: +s32 txgbe_dcb_config_tx_desc_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_hw *' should also have an identifier name #707: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:18: +s32 txgbe_dcb_config_tx_data_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u16 *' should also have an identifier name #707: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:18: +s32 txgbe_dcb_config_tx_data_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u16 *' should also have an identifier name #707: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:18: +s32 txgbe_dcb_config_tx_data_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #707: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:18: +s32 txgbe_dcb_config_tx_data_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #707: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:18: +s32 txgbe_dcb_config_tx_data_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #707: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:18: +s32 txgbe_dcb_config_tx_data_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'struct txgbe_hw *' should also have an identifier name #709: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:20: +s32 txgbe_dcb_config_rx_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, u8 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u16 *' should also have an identifier name #709: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:20: +s32 txgbe_dcb_config_rx_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, u8 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u16 *' should also have an identifier name #709: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:20: +s32 txgbe_dcb_config_rx_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, u8 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #709: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:20: +s32 txgbe_dcb_config_rx_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, u8 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #709: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:20: +s32 txgbe_dcb_config_rx_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, u8 *, WARNING:FUNCTION_ARGUMENTS: function definition argument 'u8 *' should also have an identifier name #709: FILE: drivers/net/txgbe/base/txgbe_dcb_hw.h:20: +s32 txgbe_dcb_config_rx_arbiter_raptor(struct txgbe_hw *, u16 *, u16 *, u8 *, WARNING:BRACES: braces {} are not necessary for any arm of this statement #1082: FILE: drivers/net/txgbe/txgbe_rxtx.c:2810: + if (cfg->enable_default_pool) { [...] + } else { [...] WARNING:BRACES: braces {} are not necessary for single statement blocks #1108: FILE: drivers/net/txgbe/txgbe_rxtx.c:2836: + for (i = 0; i < NUM_VFTA_REGISTERS; i++) { + wr32(hw, TXGBE_VLANTBL(i), 0xFFFFFFFF); + } WARNING:BRACES: braces {} are not necessary for any arm of this statement #1153: FILE: drivers/net/txgbe/txgbe_rxtx.c:2881: + if (dcb_config->num_tcs.pg_tcs == 8) { [...] + } else { [...] WARNING:BRACES: braces {} are not necessary for any arm of this statement #1335: FILE: drivers/net/txgbe/txgbe_rxtx.c:3063: + if (dcb_config->vt_mode) { [...] + } else { [...] WARNING:BRACES: braces {} are not necessary for any arm of this statement #1344: FILE: drivers/net/txgbe/txgbe_rxtx.c:3072: + if (dcb_config->vt_mode) [...] + else { [...] CHECK:BRACES: Unbalanced braces around else statement #1346: FILE: drivers/net/txgbe/txgbe_rxtx.c:3074: + else { WARNING:BRACES: braces {} are not necessary for single statement blocks #1373: FILE: drivers/net/txgbe/txgbe_rxtx.c:3101: + for (i = 0; i < NUM_VFTA_REGISTERS; i++) { + wr32(hw, TXGBE_VLANTBL(i), 0xFFFFFFFF); + } CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around 'j < ETH_DCB_NUM_USER_PRIORITIES' #1496: FILE: drivers/net/txgbe/txgbe_rxtx.c:3224: + if ((mask & 0x1) && (j < ETH_DCB_NUM_USER_PRIORITIES)) WARNING:BRACES: braces {} are not necessary for single statement blocks #1533: FILE: drivers/net/txgbe/txgbe_rxtx.c:3261: + for (i = 0; i < nb_tcs; i++) { + wr32(hw, TXGBE_PBRXSIZE(i), rxpbsize); + } WARNING:BRACES: braces {} are not necessary for single statement blocks #1537: FILE: drivers/net/txgbe/txgbe_rxtx.c:3265: + for (; i < ETH_DCB_NUM_USER_PRIORITIES; i++) { + wr32(hw, TXGBE_PBRXSIZE(i), 0); + } CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around dev->data->dev_conf #1593: FILE: drivers/net/txgbe/txgbe_rxtx.c:3321: + struct rte_eth_conf *dev_conf = &(dev->data->dev_conf); CHECK:SPACING: spaces preferred around that '/' (ctx:VxV) #1631: FILE: drivers/net/txgbe/txgbe_rxtx.c:3359: + wr32m(hw, TXGBE_TAGTPID(i/2), ^ CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around dev->data->dev_conf #1649: FILE: drivers/net/txgbe/txgbe_rxtx.c:3377: + struct rte_eth_conf *dev_conf = &(dev->data->dev_conf); CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around 'dev_conf->rxmode.mq_mode != ETH_MQ_RX_VMDQ_DCB' #1654: FILE: drivers/net/txgbe/txgbe_rxtx.c:3382: + if ((dev_conf->rxmode.mq_mode != ETH_MQ_RX_VMDQ_DCB) && + (dev_conf->rxmode.mq_mode != ETH_MQ_RX_DCB) && + (dev_conf->rxmode.mq_mode != ETH_MQ_RX_DCB_RSS)) CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around 'dev_conf->rxmode.mq_mode != ETH_MQ_RX_DCB' #1654: FILE: drivers/net/txgbe/txgbe_rxtx.c:3382: + if ((dev_conf->rxmode.mq_mode != ETH_MQ_RX_VMDQ_DCB) && + (dev_conf->rxmode.mq_mode != ETH_MQ_RX_DCB) && + (dev_conf->rxmode.mq_mode != ETH_MQ_RX_DCB_RSS)) CHECK:UNNECESSARY_PARENTHESES: Unnecessary parentheses around 'dev_conf->rxmode.mq_mode != ETH_MQ_RX_DCB_RSS' #1654: FILE: drivers/net/txgbe/txgbe_rxtx.c:3382: + if ((dev_conf->rxmode.mq_mode != ETH_MQ_RX_VMDQ_DCB) && + (dev_conf->rxmode.mq_mode != ETH_MQ_RX_DCB) && + (dev_conf->rxmode.mq_mode != ETH_MQ_RX_DCB_RSS)) total: 0 errors, 60 warnings, 9 checks, 1533 lines checked