diff options
author | Jesse Brandeburg <jesse.brandeburg@intel.com> | 2020-09-25 15:24:45 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-09-25 16:29:00 -0700 |
commit | d0ea5cbdc286de4efdfe6acdd8b2b9e2377c5199 (patch) | |
tree | d01eff1882b2304a66f9d03d14853859932d4098 /drivers/net/ethernet/oki-semi/pch_gbe | |
parent | add3c86aa22976c4fbca4126b9d31c5f2f249a97 (diff) |
drivers/net/ethernet: clean up mis-targeted comments
As part of the W=1 cleanups for ethernet, a million [*] driver
comments had to be cleaned up to get the W=1 compilation to
succeed. This change finally makes the drivers/net/ethernet tree
compile with W=1 set on the command line. NOTE: The kernel uses
kdoc style (see Documentation/process/kernel-doc.rst) when
documenting code, not doxygen or other styles.
After this patch the x86_64 build has no warnings from W=1, however
scripts/kernel-doc says there are 1545 more warnings in source files, that
I need to develop a script to fix in a followup patch.
The errors fixed here are all kdoc of a few classes, with a few outliers:
In file included from drivers/net/ethernet/qlogic/netxen/netxen_nic_hw.c:10:
drivers/net/ethernet/qlogic/netxen/netxen_nic.h:1193:18: warning: ‘FW_DUMP_LEVELS’ defined but not used [-Wunused-const-variable=]
1193 | static const u32 FW_DUMP_LEVELS[] = { 0x3, 0x7, 0xf, 0x1f, 0x3f, 0x7f, 0xff };
| ^~~~~~~~~~~~~~
... repeats 4 times...
drivers/net/ethernet/sun/cassini.c:2084:24: warning: suggest braces around empty body in an ‘else’ statement [-Wempty-body]
2084 | RX_USED_ADD(page, i);
drivers/net/ethernet/natsemi/ns83820.c: In function ‘phy_intr’:
drivers/net/ethernet/natsemi/ns83820.c:603:6: warning: variable ‘tbisr’ set but not used [-Wunused-but-set-variable]
603 | u32 tbisr, tanar, tanlpar;
| ^~~~~
drivers/net/ethernet/natsemi/ns83820.c: In function ‘ns83820_get_link_ksettings’:
drivers/net/ethernet/natsemi/ns83820.c:1207:11: warning: variable ‘tanar’ set but not used [-Wunused-but-set-variable]
1207 | u32 cfg, tanar, tbicr;
| ^~~~~
drivers/net/ethernet/packetengines/yellowfin.c:1063:18: warning: variable ‘yf_size’ set but not used [-Wunused-but-set-variable]
1063 | int data_size, yf_size;
| ^~~~~~~
Normal kdoc fixes:
warning: Function parameter or member 'x' not described in 'y'
warning: Excess function parameter 'x' description in 'y'
warning: Cannot understand <string> on line <NNN> - I thought it was a doc line
[*] - ok it wasn't quite a million, but it felt like it.
Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/oki-semi/pch_gbe')
-rw-r--r-- | drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_ethtool.c | 4 | ||||
-rw-r--r-- | drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c | 5 | ||||
-rw-r--r-- | drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c | 14 |
3 files changed, 12 insertions, 11 deletions
diff --git a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_ethtool.c b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_ethtool.c index b36aa5bf3c5f..a58f14aca10c 100644 --- a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_ethtool.c +++ b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_ethtool.c @@ -8,7 +8,7 @@ #include "pch_gbe.h" #include "pch_gbe_phy.h" -/** +/* * pch_gbe_stats - Stats item information */ struct pch_gbe_stats { @@ -24,7 +24,7 @@ struct pch_gbe_stats { .offset = offsetof(struct pch_gbe_hw_stats, m), \ } -/** +/* * pch_gbe_gstrings_stats - ethtool information status name list */ static const struct pch_gbe_stats pch_gbe_gstrings_stats[] = { diff --git a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c index 23f7c76737c9..ade8c44c01cd 100644 --- a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c +++ b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_main.c @@ -295,7 +295,7 @@ static s32 pch_gbe_mac_read_mac_addr(struct pch_gbe_hw *hw) /** * pch_gbe_wait_clr_bit - Wait to clear a bit * @reg: Pointer of register - * @busy: Busy bit + * @bit: Busy bit */ static void pch_gbe_wait_clr_bit(void *reg, u32 bit) { @@ -1034,7 +1034,7 @@ static void pch_gbe_set_mode(struct pch_gbe_adapter *adapter, u16 speed, /** * pch_gbe_watchdog - Watchdog process - * @data: Board private structure + * @t: timer list containing a Board private structure */ static void pch_gbe_watchdog(struct timer_list *t) { @@ -2270,6 +2270,7 @@ static int pch_gbe_ioctl(struct net_device *netdev, struct ifreq *ifr, int cmd) /** * pch_gbe_tx_timeout - Respond to a Tx Hang * @netdev: Network interface device structure + * @txqueue: index of hanging queue */ static void pch_gbe_tx_timeout(struct net_device *netdev, unsigned int txqueue) { diff --git a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c index dceec80fd642..81fc5a6e3221 100644 --- a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c +++ b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c @@ -13,7 +13,7 @@ #define OPTION_DISABLED 0 #define OPTION_ENABLED 1 -/** +/* * TxDescriptors - Transmit Descriptor Count * @Valid Range: PCH_GBE_MIN_TXD - PCH_GBE_MAX_TXD * @Default Value: PCH_GBE_DEFAULT_TXD @@ -22,7 +22,7 @@ static int TxDescriptors = OPTION_UNSET; module_param(TxDescriptors, int, 0); MODULE_PARM_DESC(TxDescriptors, "Number of transmit descriptors"); -/** +/* * RxDescriptors -Receive Descriptor Count * @Valid Range: PCH_GBE_MIN_RXD - PCH_GBE_MAX_RXD * @Default Value: PCH_GBE_DEFAULT_RXD @@ -31,7 +31,7 @@ static int RxDescriptors = OPTION_UNSET; module_param(RxDescriptors, int, 0); MODULE_PARM_DESC(RxDescriptors, "Number of receive descriptors"); -/** +/* * Speed - User Specified Speed Override * @Valid Range: 0, 10, 100, 1000 * - 0: auto-negotiate at all supported speeds @@ -44,7 +44,7 @@ static int Speed = OPTION_UNSET; module_param(Speed, int, 0); MODULE_PARM_DESC(Speed, "Speed setting"); -/** +/* * Duplex - User Specified Duplex Override * @Valid Range: 0-2 * - 0: auto-negotiate for duplex @@ -59,7 +59,7 @@ MODULE_PARM_DESC(Duplex, "Duplex setting"); #define HALF_DUPLEX 1 #define FULL_DUPLEX 2 -/** +/* * AutoNeg - Auto-negotiation Advertisement Override * @Valid Range: 0x01-0x0F, 0x20-0x2F * @@ -85,7 +85,7 @@ MODULE_PARM_DESC(AutoNeg, "Advertised auto-negotiation setting"); #define PHY_ADVERTISE_1000_FULL 0x0020 #define PCH_AUTONEG_ADVERTISE_DEFAULT 0x2F -/** +/* * FlowControl - User Specified Flow Control Override * @Valid Range: 0-3 * - 0: No Flow Control @@ -124,7 +124,7 @@ MODULE_PARM_DESC(XsumTX, "Disable or enable Transmit Checksum offload"); #define PCH_GBE_DEFAULT_TX_CSUM true /* trueorfalse */ -/** +/* * pch_gbe_option - Force the MAC's flow control settings * @hw: Pointer to the HW structure * Returns: |