mirror of
https://github.com/torvalds/linux.git
synced 2026-05-28 09:04:39 +02:00
net: ngbe: change the default ITR setting
Change the default RX/TX ITR for wx_mac_em devices from 20K to 7K, which is an experience value from out-of-tree ngbe driver, to get higher performance on some platforms with weak single-core performance. TCP_SRTEAM test on Phytium 2000+ shows that the throughput of 64-Byte packets is increased from 350.53Mbits/s to 395.92Mbits/s. Signed-off-by: Jiawen Wu <jiawenwu@trustnetic.com> Reviewed-by: Michal Swiatkowski <michal.swiatkowski@linux.intel.com> Link: https://patch.msgid.link/20250821023408.53472-2-jiawenwu@trustnetic.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
2fa1369db3
commit
6d3f753c9c
|
|
@ -359,10 +359,14 @@ int wx_set_coalesce(struct net_device *netdev,
|
|||
else
|
||||
wx->rx_itr_setting = ec->rx_coalesce_usecs;
|
||||
|
||||
if (wx->rx_itr_setting == 1)
|
||||
rx_itr_param = WX_20K_ITR;
|
||||
else
|
||||
if (wx->rx_itr_setting == 1) {
|
||||
if (wx->mac.type == wx_mac_em)
|
||||
rx_itr_param = WX_7K_ITR;
|
||||
else
|
||||
rx_itr_param = WX_20K_ITR;
|
||||
} else {
|
||||
rx_itr_param = wx->rx_itr_setting;
|
||||
}
|
||||
|
||||
if (ec->tx_coalesce_usecs > 1)
|
||||
wx->tx_itr_setting = ec->tx_coalesce_usecs << 2;
|
||||
|
|
@ -377,7 +381,7 @@ int wx_set_coalesce(struct net_device *netdev,
|
|||
tx_itr_param = WX_12K_ITR;
|
||||
break;
|
||||
default:
|
||||
tx_itr_param = WX_20K_ITR;
|
||||
tx_itr_param = WX_7K_ITR;
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -119,9 +119,8 @@ static int ngbe_sw_init(struct wx *wx)
|
|||
num_online_cpus());
|
||||
wx->rss_enabled = true;
|
||||
|
||||
/* enable itr by default in dynamic mode */
|
||||
wx->rx_itr_setting = 1;
|
||||
wx->tx_itr_setting = 1;
|
||||
wx->rx_itr_setting = WX_7K_ITR;
|
||||
wx->tx_itr_setting = WX_7K_ITR;
|
||||
|
||||
/* set default ring sizes */
|
||||
wx->tx_ring_count = NGBE_DEFAULT_TXD;
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user