* |WARNING| pw146127 [PATCH v2 05/18] net/r8169: add support for hw config
[not found] <20241017063200.26101-6-howard_wang@realsil.com.cn>
@ 2024-10-17 6:36 ` checkpatch
0 siblings, 0 replies; only message in thread
From: checkpatch @ 2024-10-17 6:36 UTC (permalink / raw)
To: test-report; +Cc: Howard Wang
Test-Label: checkpatch
Test-Status: WARNING
http://dpdk.org/patch/146127
_coding style issues_
CHECK:CAMELCASE: Avoid CamelCase: <InterFrameGap>
#238: FILE: drivers/net/r8169/r8169_base.h:515:
+#define InterFrameGap 0x03 /* 3 means InterFrameGap = the shortest one */
CHECK:CAMELCASE: Avoid CamelCase: <HwSuppIntMitiVer>
#269: FILE: drivers/net/r8169/r8169_ethdev.h:20:
+ u8 HwSuppIntMitiVer;
CHECK:CAMELCASE: Avoid CamelCase: <EnableTxNoClose>
#272: FILE: drivers/net/r8169/r8169_ethdev.h:23:
+ u8 EnableTxNoClose;
CHECK:CAMELCASE: Avoid CamelCase: <HwSuppDashVer>
#275: FILE: drivers/net/r8169/r8169_ethdev.h:26:
+ u8 HwSuppDashVer;
CHECK:CAMELCASE: Avoid CamelCase: <HwSuppOcpChannelVer>
#277: FILE: drivers/net/r8169/r8169_ethdev.h:28:
+ u8 HwSuppOcpChannelVer;
CHECK:CAMELCASE: Avoid CamelCase: <AllowAccessDashOcp>
#278: FILE: drivers/net/r8169/r8169_ethdev.h:29:
+ u8 AllowAccessDashOcp;
ERROR:CODE_INDENT: code indent should use tabs where possible
#292: FILE: drivers/net/r8169/r8169_hw.c:19:
+ int type, const u32 base_address)$
WARNING:LEADING_SPACE: please, no spaces at the start of a line
#292: FILE: drivers/net/r8169/r8169_hw.c:19:
+ int type, const u32 base_address)$
ERROR:CODE_INDENT: code indent should use tabs where possible
#299: FILE: drivers/net/r8169/r8169_hw.c:26:
+^I (base_address & 0x000FFF);$
CHECK:CAMELCASE: Avoid CamelCase: <ERIAR_Addr_Align>
#305: FILE: drivers/net/r8169/r8169_hw.c:32:
+ val_shift = addr % ERIAR_Addr_Align;
CHECK:CAMELCASE: Avoid CamelCase: <ERIAR_Read>
#308: FILE: drivers/net/r8169/r8169_hw.c:35:
+ eri_cmd = ERIAR_Read | transformed_base_address |
ERROR:CODE_INDENT: code indent should use tabs where possible
#309: FILE: drivers/net/r8169/r8169_hw.c:36:
+^I^I type << ERIAR_Type_shift |$
CHECK:CAMELCASE: Avoid CamelCase: <ERIAR_Type_shift>
#309: FILE: drivers/net/r8169/r8169_hw.c:36:
+ type << ERIAR_Type_shift |
ERROR:CODE_INDENT: code indent should use tabs where possible
#310: FILE: drivers/net/r8169/r8169_hw.c:37:
+^I^I ERIAR_ByteEn << ERIAR_ByteEn_shift |$
CHECK:CAMELCASE: Avoid CamelCase: <ERIAR_ByteEn>
#310: FILE: drivers/net/r8169/r8169_hw.c:37:
+ ERIAR_ByteEn << ERIAR_ByteEn_shift |
CHECK:CAMELCASE: Avoid CamelCase: <ERIAR_ByteEn_shift>
#310: FILE: drivers/net/r8169/r8169_hw.c:37:
+ ERIAR_ByteEn << ERIAR_ByteEn_shift |
ERROR:CODE_INDENT: code indent should use tabs where possible
#311: FILE: drivers/net/r8169/r8169_hw.c:38:
+^I^I (addr & 0x0FFF);$
CHECK:CAMELCASE: Avoid CamelCase: <ERIAR_Flag>
#324: FILE: drivers/net/r8169/r8169_hw.c:51:
+ if (RTL_R32(hw, ERIAR) & ERIAR_Flag)
CHECK:BRACES: braces {} should be used on all arms of this statement
#340: FILE: drivers/net/r8169/r8169_hw.c:67:
+ if (len <= 4 - val_shift)
[...]
+ else {
[...]
CHECK:BRACES: Unbalanced braces around else statement
#342: FILE: drivers/net/r8169/r8169_hw.c:69:
+ else {
ERROR:CODE_INDENT: code indent should use tabs where possible
#356: FILE: drivers/net/r8169/r8169_hw.c:83:
+ int len, u32 value, int type, const u32 base_address)$
WARNING:LEADING_SPACE: please, no spaces at the start of a line
#356: FILE: drivers/net/r8169/r8169_hw.c:83:
+ int len, u32 value, int type, const u32 base_address)$
ERROR:CODE_INDENT: code indent should use tabs where possible
#362: FILE: drivers/net/r8169/r8169_hw.c:89:
+^I (base_address & 0x000FFF);$
ERROR:CODE_INDENT: code indent should use tabs where possible
#381: FILE: drivers/net/r8169/r8169_hw.c:108:
+^I^I base_address) & ~mask;$
CHECK:CAMELCASE: Avoid CamelCase: <ERIAR_Write>
#386: FILE: drivers/net/r8169/r8169_hw.c:113:
+ eri_cmd = ERIAR_Write | transformed_base_address |
ERROR:CODE_INDENT: code indent should use tabs where possible
#387: FILE: drivers/net/r8169/r8169_hw.c:114:
+^I^I type << ERIAR_Type_shift |$
ERROR:CODE_INDENT: code indent should use tabs where possible
#388: FILE: drivers/net/r8169/r8169_hw.c:115:
+^I^I ERIAR_ByteEn << ERIAR_ByteEn_shift |$
ERROR:CODE_INDENT: code indent should use tabs where possible
#389: FILE: drivers/net/r8169/r8169_hw.c:116:
+^I^I (addr & 0x0FFF);$
CHECK:BRACES: braces {} should be used on all arms of this statement
#406: FILE: drivers/net/r8169/r8169_hw.c:133:
+ if (len <= 4 - val_shift)
[...]
+ else {
[...]
CHECK:BRACES: Unbalanced braces around else statement
#408: FILE: drivers/net/r8169/r8169_hw.c:135:
+ else {
ERROR:CODE_INDENT: code indent should use tabs where possible
#422: FILE: drivers/net/r8169/r8169_hw.c:149:
+ const u32 base_address)$
WARNING:LEADING_SPACE: please, no spaces at the start of a line
#422: FILE: drivers/net/r8169/r8169_hw.c:149:
+ const u32 base_address)$
ERROR:CODE_INDENT: code indent should use tabs where possible
#425: FILE: drivers/net/r8169/r8169_hw.c:152:
+^I base_address);$
ERROR:CODE_INDENT: code indent should use tabs where possible
#444: FILE: drivers/net/r8169/r8169_hw.c:171:
+ u32 value, const u32 base_address)$
WARNING:LEADING_SPACE: please, no spaces at the start of a line
#444: FILE: drivers/net/r8169/r8169_hw.c:171:
+ u32 value, const u32 base_address)$
ERROR:CODE_INDENT: code indent should use tabs where possible
#447: FILE: drivers/net/r8169/r8169_hw.c:174:
+^I base_address);$
CHECK:BRACES: Blank lines aren't necessary before a close brace '}'
#505: FILE: drivers/net/r8169/r8169_hw.c:232:
+
+ }
CHECK:CAMELCASE: Avoid CamelCase: <ChipCmd>
#574: FILE: drivers/net/r8169/r8169_hw.c:372:
+ RTL_W8(hw, ChipCmd, RTL_R8(hw, ChipCmd) | StopReq);
CHECK:CAMELCASE: Avoid CamelCase: <StopReq>
#574: FILE: drivers/net/r8169/r8169_hw.c:372:
+ RTL_W8(hw, ChipCmd, RTL_R8(hw, ChipCmd) | StopReq);
CHECK:USLEEP_RANGE: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.rst
#581: FILE: drivers/net/r8169/r8169_hw.c:379:
+ udelay(10);
CHECK:USLEEP_RANGE: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.rst
#588: FILE: drivers/net/r8169/r8169_hw.c:386:
+ udelay(200);
CHECK:CAMELCASE: Avoid CamelCase: <CmdTxEnb>
#592: FILE: drivers/net/r8169/r8169_hw.c:390:
+ RTL_W8(hw, ChipCmd, RTL_R8(hw, ChipCmd) & (CmdTxEnb | CmdRxEnb));
CHECK:CAMELCASE: Avoid CamelCase: <CmdRxEnb>
#592: FILE: drivers/net/r8169/r8169_hw.c:390:
+ RTL_W8(hw, ChipCmd, RTL_R8(hw, ChipCmd) & (CmdTxEnb | CmdRxEnb));
CHECK:USLEEP_RANGE: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.rst
#604: FILE: drivers/net/r8169/r8169_hw.c:402:
+ udelay(50);
CHECK:CAMELCASE: Avoid CamelCase: <MCUCmd_reg>
#605: FILE: drivers/net/r8169/r8169_hw.c:403:
+ if ((RTL_R8(hw, MCUCmd_reg) & (Txfifo_empty | Rxfifo_empty)) ==
CHECK:CAMELCASE: Avoid CamelCase: <Txfifo_empty>
#605: FILE: drivers/net/r8169/r8169_hw.c:403:
+ if ((RTL_R8(hw, MCUCmd_reg) & (Txfifo_empty | Rxfifo_empty)) ==
CHECK:CAMELCASE: Avoid CamelCase: <Rxfifo_empty>
#605: FILE: drivers/net/r8169/r8169_hw.c:403:
+ if ((RTL_R8(hw, MCUCmd_reg) & (Txfifo_empty | Rxfifo_empty)) ==
CHECK:USLEEP_RANGE: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.rst
#618: FILE: drivers/net/r8169/r8169_hw.c:416:
+ udelay(50);
CHECK:CAMELCASE: Avoid CamelCase: <IntrMitigate>
#619: FILE: drivers/net/r8169/r8169_hw.c:417:
+ if ((RTL_R16(hw, IntrMitigate) & (BIT_0 | BIT_1 | BIT_8)) ==
CHECK:CAMELCASE: Avoid CamelCase: <RxConfig>
#630: FILE: drivers/net/r8169/r8169_hw.c:428:
+ RTL_W32(hw, RxConfig, RTL_R32(hw, RxConfig) &
ERROR:CODE_INDENT: code indent should use tabs where possible
#631: FILE: drivers/net/r8169/r8169_hw.c:429:
+^I ~(AcceptErr | AcceptRunt | AcceptBroadcast | AcceptMulticast |$
CHECK:CAMELCASE: Avoid CamelCase: <AcceptErr>
#631: FILE: drivers/net/r8169/r8169_hw.c:429:
+ ~(AcceptErr | AcceptRunt | AcceptBroadcast | AcceptMulticast |
CHECK:CAMELCASE: Avoid CamelCase: <AcceptRunt>
#631: FILE: drivers/net/r8169/r8169_hw.c:429:
+ ~(AcceptErr | AcceptRunt | AcceptBroadcast | AcceptMulticast |
CHECK:CAMELCASE: Avoid CamelCase: <AcceptBroadcast>
#631: FILE: drivers/net/r8169/r8169_hw.c:429:
+ ~(AcceptErr | AcceptRunt | AcceptBroadcast | AcceptMulticast |
CHECK:CAMELCASE: Avoid CamelCase: <AcceptMulticast>
#631: FILE: drivers/net/r8169/r8169_hw.c:429:
+ ~(AcceptErr | AcceptRunt | AcceptBroadcast | AcceptMulticast |
ERROR:CODE_INDENT: code indent should use tabs where possible
#632: FILE: drivers/net/r8169/r8169_hw.c:430:
+^I AcceptMyPhys | AcceptAllPhys));$
CHECK:CAMELCASE: Avoid CamelCase: <AcceptMyPhys>
#632: FILE: drivers/net/r8169/r8169_hw.c:430:
+ AcceptMyPhys | AcceptAllPhys));
CHECK:CAMELCASE: Avoid CamelCase: <AcceptAllPhys>
#632: FILE: drivers/net/r8169/r8169_hw.c:430:
+ AcceptMyPhys | AcceptAllPhys));
CHECK:CAMELCASE: Avoid CamelCase: <CmdReset>
#651: FILE: drivers/net/r8169/r8169_hw.c:449:
+ RTL_W8(hw, ChipCmd, CmdReset);
CHECK:USLEEP_RANGE: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.rst
#655: FILE: drivers/net/r8169/r8169_hw.c:453:
+ udelay(100);
CHECK:CAMELCASE: Avoid CamelCase: <Cfg9346>
#664: FILE: drivers/net/r8169/r8169_hw.c:462:
+ RTL_W8(hw, Cfg9346, RTL_R8(hw, Cfg9346) | Cfg9346_Unlock);
CHECK:CAMELCASE: Avoid CamelCase: <Cfg9346_Unlock>
#664: FILE: drivers/net/r8169/r8169_hw.c:462:
+ RTL_W8(hw, Cfg9346, RTL_R8(hw, Cfg9346) | Cfg9346_Unlock);
CHECK:CAMELCASE: Avoid CamelCase: <Config2>
#690: FILE: drivers/net/r8169/r8169_hw.c:488:
+ RTL_W8(hw, Config2, RTL_R8(hw, Config2) | BIT_7);
CHECK:CAMELCASE: Avoid CamelCase: <Config5>
#691: FILE: drivers/net/r8169/r8169_hw.c:489:
+ RTL_W8(hw, Config5, RTL_R8(hw, Config5) | BIT_0);
ERROR:CODE_INDENT: code indent should use tabs where possible
#768: FILE: drivers/net/r8169/r8169_hw.c:566:
+^I^I^I INT_CFG0_MITIGATION_BYPASS_8125 |$
ERROR:CODE_INDENT: code indent should use tabs where possible
#769: FILE: drivers/net/r8169/r8169_hw.c:567:
+^I^I^I INT_CFG0_RDU_BYPASS_8126));$
CHECK:CAMELCASE: Avoid CamelCase: <RxCfgDMAShift>
#785: FILE: drivers/net/r8169/r8169_hw.c:583:
+ RTL_W32(hw, RxConfig, (RX_DMA_BURST_unlimited << RxCfgDMAShift));
CHECK:CAMELCASE: Avoid CamelCase: <TxConfig>
#810: FILE: drivers/net/r8169/r8169_hw.c:608:
+ RTL_W32(hw, TxConfig, (TX_DMA_BURST_unlimited << TxDMAShift) |
CHECK:CAMELCASE: Avoid CamelCase: <TxDMAShift>
#810: FILE: drivers/net/r8169/r8169_hw.c:608:
+ RTL_W32(hw, TxConfig, (TX_DMA_BURST_unlimited << TxDMAShift) |
ERROR:CODE_INDENT: code indent should use tabs where possible
#811: FILE: drivers/net/r8169/r8169_hw.c:609:
+^I (InterFrameGap << TxInterFrameGapShift));$
CHECK:CAMELCASE: Avoid CamelCase: <TxInterFrameGapShift>
#811: FILE: drivers/net/r8169/r8169_hw.c:609:
+ (InterFrameGap << TxInterFrameGapShift));
CHECK:CAMELCASE: Avoid CamelCase: <Config1>
#840: FILE: drivers/net/r8169/r8169_hw.c:638:
+ RTL_W8(hw, Config1, RTL_R8(hw, Config1) & ~0x10);
ERROR:CODE_INDENT: code indent should use tabs where possible
#867: FILE: drivers/net/r8169/r8169_hw.c:665:
+^I^I hw->mcfg == CFG_METHOD_71)$
ERROR:CODE_INDENT: code indent should use tabs where possible
#897: FILE: drivers/net/r8169/r8169_hw.c:695:
+^I^I BIT_0);$
ERROR:CODE_INDENT: code indent should use tabs where possible
#951: FILE: drivers/net/r8169/r8169_hw.c:749:
+^I^I (BIT_7 | BIT_8 | BIT_9 | BIT_10 | BIT_11 | BIT_12));$
ERROR:CODE_INDENT: code indent should use tabs where possible
#955: FILE: drivers/net/r8169/r8169_hw.c:753:
+^I^I BIT_4 | BIT_3 | BIT_2 | BIT_1 | BIT_0);$
CHECK:CAMELCASE: Avoid CamelCase: <EnableRxDescV4_0>
#985: FILE: drivers/net/r8169/r8169_hw.c:783:
+ RTL_W8(hw, 0xd8, RTL_R8(hw, 0xd8) & ~EnableRxDescV4_0);
CHECK:USLEEP_RANGE: usleep_range is preferred over udelay; see Documentation/timers/timers-howto.rst
#1004: FILE: drivers/net/r8169/r8169_hw.c:802:
+ udelay(10);
WARNING:BLOCK_COMMENT_STYLE: Block comments use a trailing */ on a separate line
#1049: FILE: drivers/net/r8169/r8169_phy.c:2:
+ * Copyright(c) 2024 Realtek Corporation. All rights reserved */
WARNING:TYPO_SPELLING: 'stdio' may be misspelled - perhaps 'studio'?
#1052: FILE: drivers/net/r8169/r8169_phy.c:5:
+#include <stdio.h>
ERROR:CODE_INDENT: code indent should use tabs where possible
#1067: FILE: drivers/net/r8169/r8169_phy.c:20:
+ u16 setmask)$
WARNING:LEADING_SPACE: please, no spaces at the start of a line
#1067: FILE: drivers/net/r8169/r8169_phy.c:20:
+ u16 setmask)$
total: 25 errors, 7 warnings, 50 checks, 989 lines checked
^ permalink raw reply [flat|nested] only message in thread