diff options
author | Jakub Kicinski <jakub.kicinski@netronome.com> | 2018-11-09 18:50:00 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-11-09 19:49:00 -0800 |
commit | 560f1ba4d8e8cb70f59b704a6edfa094b9bc0266 (patch) | |
tree | 6f2544925f6b233b4c323df34362a24ae8098c87 /drivers/net/ethernet/netronome/nfp/nfp_net_common.c | |
parent | 3f2bba7d681b4bc38a7421940b8c2472f41711e4 (diff) | |
download | lwn-560f1ba4d8e8cb70f59b704a6edfa094b9bc0266.tar.gz lwn-560f1ba4d8e8cb70f59b704a6edfa094b9bc0266.zip |
nfp: use the new __netdev_tx_sent_queue() BQL optimisation
__netdev_tx_sent_queue() was added in commit e59020abf0f
("net: bql: add __netdev_tx_sent_queue()") and allows for
better GSO performance.
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: Dirk van der Merwe <dirk.vandermerwe@netronome.com>
Reviewed-by: Simon Horman <simon.horman@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/netronome/nfp/nfp_net_common.c')
-rw-r--r-- | drivers/net/ethernet/netronome/nfp/nfp_net_common.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c index e00d5a2a41ee..a0343f25068a 100644 --- a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c +++ b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c @@ -890,8 +890,6 @@ static int nfp_net_tx(struct sk_buff *skb, struct net_device *netdev) u64_stats_update_end(&r_vec->tx_sync); } - netdev_tx_sent_queue(nd_q, txbuf->real_len); - skb_tx_timestamp(skb); tx_ring->wr_p += nr_frags + 1; @@ -899,7 +897,7 @@ static int nfp_net_tx(struct sk_buff *skb, struct net_device *netdev) nfp_net_tx_ring_stop(nd_q, tx_ring); tx_ring->wr_ptr_add += nr_frags + 1; - if (!skb->xmit_more || netif_xmit_stopped(nd_q)) + if (__netdev_tx_sent_queue(nd_q, txbuf->real_len, skb->xmit_more)) nfp_net_tx_xmit_more_flush(tx_ring); return NETDEV_TX_OK; |