linux_dsm_epyc7002/drivers/net/ethernet
Arthur Kiyanovski 41c53caa5a net: ena: fix issues in setting interrupt moderation params in ethtool
Issue 1:
--------
Reproduction steps:
1. sudo ethtool -C eth0 rx-usecs 128
2. sudo ethtool -C eth0 adaptive-rx on
3. sudo ethtool -C eth0 adaptive-rx off
4. ethtool -c eth0

expected output: rx-usecs 128
actual output: rx-usecs 0

Reason for issue:
In stage 3, ethtool userspace calls first the ena_get_coalesce() handler
to get the current value of all properties, and then the ena_set_coalesce()
handler. When ena_get_coalesce() is called the adaptive interrupt
moderation is still on. There is an if in the code that returns the
rx_coalesce_usecs only if the adaptive interrupt moderation is off.
And since it is still on, rx_coalesce_usecs is not set, meaning it
stays 0.

Solution to issue:
Remove this if static interrupt moderation intervals have nothing to do
with dynamic ones.

Issue 2:
--------
Reproduction steps:
1. sudo ethtool -C eth0 adaptive-rx on
2. sudo ethtool -C eth0 rx-usecs 128
3. ethtool -c eth0

expected output: rx-usecs 128
actual output: rx-usecs 0

Reason for issue:
In stage 2, when ena_set_coalesce() is called, the handler tests if
rx adaptive interrupt moderation is on, and if it is, it returns before
getting to the part in the function that sets the rx non-adaptive
interrupt moderation interval.

Solution to issue:
Remove the return from the function when rx adaptive interrupt moderation
is on.

Also cleaned up the fixed code in ena_set_coalesce by grouping together
adaptive interrupt moderation toggling, and using && instead of nested
ifs.

Fixes: b3db86dc4b ("net: ena: reimplement set/get_coalesce()")
Fixes: 0eda847953 ("net: ena: fix retrieval of nonadaptive interrupt moderation intervals")
Fixes: 1738cd3ed3 ("net: ena: Add a driver for Amazon Elastic Network Adapters (ENA)")
Signed-off-by: Arthur Kiyanovski <akiyano@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-12-20 21:43:08 -08:00
..
3com
8390
adaptec
aeroflex
agere
alacritech
allwinner
alteon
altera net: of_get_phy_mode: Change API to solve int/unit warnings 2019-11-04 11:21:25 -08:00
amazon net: ena: fix issues in setting interrupt moderation params in ethtool 2019-12-20 21:43:08 -08:00
amd
apm
apple
aquantia net: atlantic: Signedness bug in aq_vec_isr_legacy() 2019-11-13 14:29:28 -08:00
arc net: of_get_phy_mode: Change API to solve int/unit warnings 2019-11-04 11:21:25 -08:00
atheros net: ag71xx: fix compile warnings 2019-12-17 22:38:50 -08:00
aurora net: of_get_phy_mode: Change API to solve int/unit warnings 2019-11-04 11:21:25 -08:00
broadcom bnx2x: Fix logic to get total no. of PFs per engine 2019-12-14 12:59:16 -08:00
brocade
cadence net: macb: fix probing of PHY not described in the dt 2019-12-19 17:32:21 -08:00
calxeda
cavium net: thunderx: start phy before starting autonegotiation 2019-12-05 12:10:40 -08:00
chelsio cxgb4: fix refcount init for TC-MQPRIO offload 2019-12-20 14:13:33 -08:00
cirrus net: ep93xx_eth: fix mismatch of request_mem_region in remove 2019-11-15 12:42:09 -08:00
cisco
cortina net: gemini: Fix memory leak in gmac_setup_txqs 2019-12-16 16:26:54 -08:00
davicom
dec
dlink
emulex net: emulex: benet: indent a Kconfig depends continuation line 2019-11-30 12:25:26 -08:00
ezchip
faraday Here's the main documentation changes for 5.5: 2019-12-02 11:51:02 -08:00
freescale dpaa2-ptp: fix double free of the ptp_qoriq IRQ 2019-12-17 14:10:20 -08:00
fujitsu
google gve: Fix the queue page list allocated pages count 2019-11-26 15:52:34 -08:00
hisilicon net: hisilicon: Fix a BUG trigered by wrong bytes_compl 2019-12-20 21:15:19 -08:00
huawei
i825xx
ibm net/ibmvnic: Fix typo in retry check 2019-12-13 17:23:10 -08:00
intel net/ixgbe: Fix concurrency issues between config flow and XSK 2019-12-19 16:20:49 +01:00
marvell net: marvell: mvpp2: phylink requires the link interrupt 2019-12-14 10:11:36 -08:00
mediatek net: phylink: rename mac_link_state() op to mac_pcs_get_state() 2019-11-23 16:13:39 -08:00
mellanox net/mlx5e: Fix concurrency issues between config flow and XSK 2019-12-19 16:20:49 +01:00
micrel
microchip Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2019-11-16 21:51:42 -08:00
moxa
mscc net: mscc: ocelot: unregister the PTP clock on deinit 2019-12-03 11:27:00 -08:00
myricom
natsemi
neterion
netronome nfp: flower: fix stats id allocation 2019-12-17 22:49:10 -08:00
ni net: of_get_phy_mode: Change API to solve int/unit warnings 2019-11-04 11:21:25 -08:00
nvidia net: forcedeth: add xmit_more support 2019-11-06 10:22:31 -08:00
nxp lpc_eth: kernel BUG on remove 2019-12-06 20:51:19 -08:00
oki-semi
packetengines
pasemi
pensando Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2019-12-08 13:28:11 -08:00
qlogic net: qlogic: Fix error paths in ql_alloc_large_buffers() 2019-12-17 22:01:07 -08:00
qualcomm Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2019-11-22 16:27:24 -08:00
rdc
realtek r8169: fix rtl_hw_jumbo_disable for RTL8168evl 2019-12-07 14:23:06 -08:00
renesas Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2019-11-16 21:51:42 -08:00
rocker
samsung net: of_get_phy_mode: Change API to solve int/unit warnings 2019-11-04 11:21:25 -08:00
seeq
sfc sfc: fix build without CONFIG_RFS_ACCEL 2019-11-24 14:44:09 -08:00
sgi net: sgi: ioc3-eth: ensure tx ring is 16k aligned. 2019-11-04 11:30:14 -08:00
silan
sis
smsc
socionext net: of_get_phy_mode: Change API to solve int/unit warnings 2019-11-04 11:21:25 -08:00
stmicro net: stmmac: platform: Fix MDIO init for platforms without PHY 2019-12-20 21:27:51 -08:00
sun
synopsys
tehuti
ti net: ethernet: ti: build cpsw-common for switchdev 2019-12-14 12:51:00 -08:00
toshiba
tundra
via
wiznet
xilinx net: phylink: rename mac_link_state() op to mac_pcs_get_state() 2019-11-23 16:13:39 -08:00
xircom
xscale
dnet.c
dnet.h
ec_bhf.c
ethoc.c
fealnx.c
jme.c
jme.h
Kconfig hp100: Move 100BaseVG AnyLAN driver to staging 2019-10-31 14:49:52 -07:00
korina.c
lantiq_etop.c
lantiq_xrx200.c
Makefile hp100: Move 100BaseVG AnyLAN driver to staging 2019-10-31 14:49:52 -07:00