]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net: stmmac: Modify configuration method of EEE timers
authorVineetha G. Jaya Kumaran <vineetha.g.jaya.kumaran@intel.com>
Thu, 1 Oct 2020 15:56:09 +0000 (23:56 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 14 Oct 2020 09:55:57 +0000 (11:55 +0200)
commita974b4bddae366ae31cbf6d3d92d2d7e4d7769fb
tree63ae50eb43c0b59de1d4c815afb0a35b619d7a73
parentd0eb9588f724be8f192fff0760eb335434474f09
net: stmmac: Modify configuration method of EEE timers

[ Upstream commit 388e201d41fa1ed8f2dce0f0567f56f8e919ffb0 ]

Ethtool manual stated that the tx-timer is the "the amount of time the
device should stay in idle mode prior to asserting its Tx LPI". The
previous implementation for "ethtool --set-eee tx-timer" sets the LPI TW
timer duration which is not correct. Hence, this patch fixes the
"ethtool --set-eee tx-timer" to configure the EEE LPI timer.

The LPI TW Timer will be using the defined default value instead of
"ethtool --set-eee tx-timer" which follows the EEE LS timer implementation.

Changelog V2
*Not removing/modifying the eee_timer.
*EEE LPI timer can be configured through ethtool and also the eee_timer
module param.
*EEE TW Timer will be configured with default value only, not able to be
configured through ethtool or module param. This follows the implementation
of the EEE LS Timer.

Fixes: d765955d2ae0 ("stmmac: add the Energy Efficient Ethernet support")
Signed-off-by: Vineetha G. Jaya Kumaran <vineetha.g.jaya.kumaran@intel.com>
Signed-off-by: Voon Weifeng <weifeng.voon@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/stmicro/stmmac/stmmac.h
drivers/net/ethernet/stmicro/stmmac/stmmac_ethtool.c
drivers/net/ethernet/stmicro/stmmac/stmmac_main.c