]> git.baikalelectronics.ru Git - kernel.git/commit
amd-xgbe: Fix Rx coalescing reporting
authorLendacky, Thomas <Thomas.Lendacky@amd.com>
Fri, 20 Mar 2015 16:50:34 +0000 (11:50 -0500)
committerDavid S. Miller <davem@davemloft.net>
Fri, 20 Mar 2015 20:33:57 +0000 (16:33 -0400)
commite6ec50f89867cb581b8e579e6c9fefb6bf99a0aa
treede0886860782befd0b2730bb6097e028f189ad28
parent1c8ce9af524bb34f6ffe84925d6eb2cc607ec635
amd-xgbe: Fix Rx coalescing reporting

The Rx coalescing value is internally converted from usecs to a value
that the hardware can use. When reporting the Rx coalescing value, this
internal value is converted back to usecs. During the conversion from
and back to usecs some rounding occurs. So, for example, when setting an
Rx usec of 30, it will be reported as 29. Fix this reporting issue by
keeping the original usec value and using that during reporting.

Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/amd/xgbe/xgbe-drv.c
drivers/net/ethernet/amd/xgbe/xgbe-ethtool.c
drivers/net/ethernet/amd/xgbe/xgbe.h