From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2680745A25 for ; Wed, 25 Sep 2024 09:55:12 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 1F930402A7; Wed, 25 Sep 2024 09:55:12 +0200 (CEST) Received: from dpdk.org (dpdk.org [92.243.24.197]) by mails.dpdk.org (Postfix) with ESMTP id 071184025D for ; Wed, 25 Sep 2024 09:55:11 +0200 (CEST) Received: by dpdk.org (Postfix, from userid 65534) id E7CEB121D9E; Wed, 25 Sep 2024 09:55:10 +0200 (CEST) Subject: |WARNING| pw144428 [PATCH] net/r8169: add support for hw initialization In-Reply-To: <20240925075421.38142-1-howard_wang@realsil.com.cn> References: <20240925075421.38142-1-howard_wang@realsil.com.cn> To: test-report@dpdk.org From: checkpatch@dpdk.org Cc: Howard Wang Message-Id: <20240925075510.E7CEB121D9E@dpdk.org> Date: Wed, 25 Sep 2024 09:55:10 +0200 (CEST) X-BeenThere: test-report@dpdk.org X-Mailman-Version: 2.1.29 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 Test-Label: checkpatch Test-Status: WARNING http://dpdk.org/patch/144428 _coding style issues_ WARNING:COMMIT_MESSAGE: Missing commit description - Add an appropriate one ERROR:CODE_INDENT: code indent should use tabs where possible #151: FILE: drivers/net/r8169/r8169_base.h:563: + ADVERTISE_100_HALF | ADVERTISE_100_FULL | ADVERTISE_1000_FULL | \$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #151: FILE: drivers/net/r8169/r8169_base.h:563: + ADVERTISE_100_HALF | ADVERTISE_100_FULL | ADVERTISE_1000_FULL | \$ ERROR:CODE_INDENT: code indent should use tabs where possible #152: FILE: drivers/net/r8169/r8169_base.h:564: + ADVERTISE_2500_FULL | ADVERTISE_5000_FULL)$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #152: FILE: drivers/net/r8169/r8169_base.h:564: + ADVERTISE_2500_FULL | ADVERTISE_5000_FULL)$ WARNING:TYPO_SPELLING: 'stdio' may be misspelled - perhaps 'studio'? #170: FILE: drivers/net/r8169/r8169_dash.c:6: +#include WARNING:CONSTANT_COMPARISON: Comparisons should place the constant on the right side of the test #217: FILE: drivers/net/r8169/r8169_dash.c:53: + if (FALSE == HW_DASH_SUPPORT_GET_FIRMWARE_VERSION(hw)) CHECK:BOOL_COMPARISON: Using comparison to FALSE is error prone #217: FILE: drivers/net/r8169/r8169_dash.c:53: + if (FALSE == HW_DASH_SUPPORT_GET_FIRMWARE_VERSION(hw)) CHECK:CAMELCASE: Avoid CamelCase: #229: FILE: drivers/net/r8169/r8169_dash.c:65: + if (!hw->AllowAccessDashOcp) CHECK:CAMELCASE: Avoid CamelCase: #274: FILE: drivers/net/r8169/r8169_dash.h:17: +#define HW_DASH_SUPPORT_DASH(_M) ((_M)->HwSuppDashVer > 0) CHECK:MACRO_ARG_REUSE: Macro argument reuse '_M' - possible side-effects? #280: FILE: drivers/net/r8169/r8169_dash.h:23: +#define HW_DASH_SUPPORT_GET_FIRMWARE_VERSION(_M) (HW_DASH_SUPPORT_TYPE_2(_M) || \ + HW_DASH_SUPPORT_TYPE_3(_M) || \ + HW_DASH_SUPPORT_TYPE_4(_M)) ERROR:CODE_INDENT: code indent should use tabs where possible #281: FILE: drivers/net/r8169/r8169_dash.h:24: + HW_DASH_SUPPORT_TYPE_3(_M) || \$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #281: FILE: drivers/net/r8169/r8169_dash.h:24: + HW_DASH_SUPPORT_TYPE_3(_M) || \$ ERROR:CODE_INDENT: code indent should use tabs where possible #282: FILE: drivers/net/r8169/r8169_dash.h:25: + HW_DASH_SUPPORT_TYPE_4(_M))$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #282: FILE: drivers/net/r8169/r8169_dash.h:25: + HW_DASH_SUPPORT_TYPE_4(_M))$ ERROR:C99_COMMENTS: do not use C99 // comments #317: FILE: drivers/net/r8169/r8169_ethdev.c:138: + //struct rte_pci_device *pci_dev = RTE_ETH_DEV_TO_PCI(dev); ERROR:C99_COMMENTS: do not use C99 // comments #318: FILE: drivers/net/r8169/r8169_ethdev.c:139: + //struct rte_intr_handle *intr_handle = pci_dev->intr_handle; ERROR:C99_COMMENTS: do not use C99 // comments #326: FILE: drivers/net/r8169/r8169_ethdev.c:147: + //if (HW_DASH_SUPPORT_DASH(hw)) ERROR:C99_COMMENTS: do not use C99 // comments #327: FILE: drivers/net/r8169/r8169_ethdev.c:148: + // rtl_driver_stop(hw); ERROR:C99_COMMENTS: do not use C99 // comments #342: FILE: drivers/net/r8169/r8169_ethdev.c:162: + //struct rte_intr_handle *intr_handle = pci_dev->intr_handle; ERROR:CODE_INDENT: code indent should use tabs where possible #369: FILE: drivers/net/r8169/r8169_ethdev.c:193: +^I^I "%02x:%02x:%02x:%02x:%02x:%02x",$ ERROR:CODE_INDENT: code indent should use tabs where possible #370: FILE: drivers/net/r8169/r8169_ethdev.c:194: +^I^I perm_addr->addr_bytes[0],$ ERROR:CODE_INDENT: code indent should use tabs where possible #371: FILE: drivers/net/r8169/r8169_ethdev.c:195: +^I^I perm_addr->addr_bytes[1],$ ERROR:CODE_INDENT: code indent should use tabs where possible #372: FILE: drivers/net/r8169/r8169_ethdev.c:196: +^I^I perm_addr->addr_bytes[2],$ ERROR:CODE_INDENT: code indent should use tabs where possible #373: FILE: drivers/net/r8169/r8169_ethdev.c:197: +^I^I perm_addr->addr_bytes[3],$ ERROR:CODE_INDENT: code indent should use tabs where possible #374: FILE: drivers/net/r8169/r8169_ethdev.c:198: +^I^I perm_addr->addr_bytes[4],$ ERROR:CODE_INDENT: code indent should use tabs where possible #375: FILE: drivers/net/r8169/r8169_ethdev.c:199: +^I^I perm_addr->addr_bytes[5]);$ CHECK:CAMELCASE: Avoid CamelCase: #418: FILE: drivers/net/r8169/r8169_ethdev.h:42: + u8 HwIcVerUnknown; CHECK:CAMELCASE: Avoid CamelCase: #439: FILE: drivers/net/r8169/r8169_ethdev.h:69: + u8 HwSuppNowIsOobVer; CHECK:CAMELCASE: Avoid CamelCase: #445: FILE: drivers/net/r8169/r8169_ethdev.h:74: + u8 HwSuppTxNoCloseVer; CHECK:CAMELCASE: Avoid CamelCase: #446: FILE: drivers/net/r8169/r8169_ethdev.h:75: + u8 EnableTxNoClose; CHECK:CAMELCASE: Avoid CamelCase: #449: FILE: drivers/net/r8169/r8169_ethdev.h:78: + u32 MaxTxDescPtrMask; ERROR:CODE_INDENT: code indent should use tabs where possible #510: FILE: drivers/net/r8169/r8169_hw.c:954: + enum rtl_fc_mode fc)$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #510: FILE: drivers/net/r8169/r8169_hw.c:954: + enum rtl_fc_mode fc)$ CHECK:CAMELCASE: Avoid CamelCase: #523: FILE: drivers/net/r8169/r8169_hw.c:967: + speed = RTE_MIN(speed, hw->HwSuppMaxPhyLinkSpeed); ERROR:CODE_INDENT: code indent should use tabs where possible #535: FILE: drivers/net/r8169/r8169_hw.c:979: +^I^I ADVERTISE_100_HALF | ADVERTISE_100_FULL |$ ERROR:CODE_INDENT: code indent should use tabs where possible #536: FILE: drivers/net/r8169/r8169_hw.c:980: +^I^I ADVERTISE_1000_HALF | ADVERTISE_1000_FULL);$ CHECK:CAMELCASE: Avoid CamelCase: #576: FILE: drivers/net/r8169/r8169_hw.c:1020: + hw->HwSuppOcpChannelVer = 2; CHECK:CAMELCASE: Avoid CamelCase: #632: FILE: drivers/net/r8169/r8169_hw.c:1076: + hw->HwSuppCheckPhyDisableModeVer = 3; CHECK:CAMELCASE: Avoid CamelCase: #738: FILE: drivers/net/r8169/r8169_hw.c:1182: + hw->NotWrRamCodeToMicroP = TRUE; CHECK:CAMELCASE: Avoid CamelCase: #739: FILE: drivers/net/r8169/r8169_hw.c:1183: + hw->NotWrMcuPatchCode = TRUE; CHECK:CAMELCASE: Avoid CamelCase: #745: FILE: drivers/net/r8169/r8169_hw.c:1189: + hw->HwSuppMacMcuVer = 2; CHECK:CAMELCASE: Avoid CamelCase: #752: FILE: drivers/net/r8169/r8169_hw.c:1196: + hw->MacMcuPageSize = RTL_MAC_MCU_PAGE_SIZE; CHECK:CAMELCASE: Avoid CamelCase: #761: FILE: drivers/net/r8169/r8169_hw.c:1205: + hw->RequirePhyMdiSwapPatch = TRUE; CHECK:CAMELCASE: Avoid CamelCase: #769: FILE: drivers/net/r8169/r8169_hw.c:1213: + hw->HwSuppIntMitiVer = 3; CHECK:CAMELCASE: Avoid CamelCase: #814: FILE: drivers/net/r8169/r8169_hw.c:1258: + RTL_W8(hw, MCUCmd_reg, RTL_R8(hw, MCUCmd_reg) & ~Now_is_oob); CHECK:CAMELCASE: Avoid CamelCase: #814: FILE: drivers/net/r8169/r8169_hw.c:1258: + RTL_W8(hw, MCUCmd_reg, RTL_R8(hw, MCUCmd_reg) & ~Now_is_oob); CHECK:USLEEP_RANGE: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.rst #823: FILE: drivers/net/r8169/r8169_hw.c:1267: + udelay(100); ERROR:C99_COMMENTS: do not use C99 // comments #836: FILE: drivers/net/r8169/r8169_hw.c:1280: + //if (HW_DASH_SUPPORT_DASH(hw)) { ERROR:C99_COMMENTS: do not use C99 // comments #837: FILE: drivers/net/r8169/r8169_hw.c:1281: + // rtl_driver_start(hw); ERROR:C99_COMMENTS: do not use C99 // comments #838: FILE: drivers/net/r8169/r8169_hw.c:1282: + // rtl_dash2_disable_txrx(hw); ERROR:C99_COMMENTS: do not use C99 // comments #839: FILE: drivers/net/r8169/r8169_hw.c:1283: + //} CHECK:CAMELCASE: Avoid CamelCase: #930: FILE: drivers/net/r8169/r8169_hw.c:1374: + val32 = RTL_R32(hw, TxConfig); CHECK:BRACES: braces {} should be used on all arms of this statement #936: FILE: drivers/net/r8169/r8169_hw.c:1380: + if (ic_version_id == 0x00000000) [...] + else if (ic_version_id == 0x100000) [...] + else { [...] CHECK:BRACES: Unbalanced braces around else statement #942: FILE: drivers/net/r8169/r8169_hw.c:1386: + else { CHECK:BRACES: braces {} should be used on all arms of this statement #950: FILE: drivers/net/r8169/r8169_hw.c:1394: + if (ic_version_id == 0x00000000) [...] + else if (ic_version_id == 0x100000) [...] + else { [...] CHECK:BRACES: Unbalanced braces around else statement #956: FILE: drivers/net/r8169/r8169_hw.c:1400: + else { CHECK:BRACES: braces {} should be used on all arms of this statement #964: FILE: drivers/net/r8169/r8169_hw.c:1408: + if (ic_version_id == 0x00000000) [...] + else if (ic_version_id == 0x100000) [...] + else { [...] CHECK:BRACES: Unbalanced braces around else statement #968: FILE: drivers/net/r8169/r8169_hw.c:1412: + else { CHECK:BRACES: braces {} should be used on all arms of this statement #976: FILE: drivers/net/r8169/r8169_hw.c:1420: + if (ic_version_id == 0x00000000) [...] + else if (ic_version_id == 0x100000) [...] + else { [...] CHECK:BRACES: Unbalanced braces around else statement #980: FILE: drivers/net/r8169/r8169_hw.c:1424: + else { CHECK:BRACES: braces {} should be used on all arms of this statement #988: FILE: drivers/net/r8169/r8169_hw.c:1432: + if (ic_version_id == 0x00000000) [...] + else if (ic_version_id == 0x100000) [...] + else if (ic_version_id == 0x200000) [...] + else { [...] CHECK:BRACES: Unbalanced braces around else statement #994: FILE: drivers/net/r8169/r8169_hw.c:1438: + else { ERROR:CODE_INDENT: code indent should use tabs where possible #1044: FILE: drivers/net/r8169/r8169_hw.c:1488: +^I ((uint32_t)addr[2] << 16) | ((uint32_t)addr[3] << 24));$ total: 24 errors, 8 warnings, 32 checks, 1032 lines checked