net/iavf: fix wrong Tx context descriptor
PATCH 1/1 net/iavf: fix wrong Tx context descriptor
From: Beilei Xing <[email protected]>
The QW0 of Tx context descriptor should be reset to 0, otherwise the previous hardware writeback value may polute the next context descriptor write.
--- drivers/net/iavf/iavf_rxtx.c | 5 +++++ 1 file changed, 5 insertions(+)
drivers/net/iavf/iavf_rxtx.c +5 -0
@@ -2245,6 +2245,11 @@ iavf_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) (volatile struct iavf_tx_context_desc *) &txr[tx_id]; +/* clear QW0 or the previous writeback value +* may impact next write +*/ + *(volatile uint64_t *)ctx_txd =0 ; + txn = &sw_ring[txe->next_id];RTE_MBUF_PREFETCH_TO_FREE (txn->mbuf);if (txe->mbuf) {
Signature · 1 line
2.26.2
PATCH v2 1/1 net/iavf: fix wrong Tx context descriptor
From: Beilei Xing <[email protected]>
The QW0 of Tx context descriptor should be reset to 0, otherwise the previous hardware writeback value may pollute the next context descriptor write.
---
v2 change:
- Typo fix.
drivers/net/iavf/iavf_rxtx.c | 5 +++++ 1 file changed, 5 insertions(+)
drivers/net/iavf/iavf_rxtx.c +5 -0
@@ -2245,6 +2245,11 @@ iavf_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) (volatile struct iavf_tx_context_desc *) &txr[tx_id]; +/* clear QW0 or the previous writeback value +* may impact next write +*/ + *(volatile uint64_t *)ctx_txd =0 ; + txn = &sw_ring[txe->next_id];RTE_MBUF_PREFETCH_TO_FREE (txn->mbuf);if (txe->mbuf) {
Signature · 1 line
2.26.2
Quoted 11 lines
-----Original Message-----
From: Xing, Beilei <[email protected]>
Sent: Wednesday, May 12, 2021 4:10 PM
To: Zhang, Qi Z <[email protected]>
Cc: [email protected]; Xing, Beilei <[email protected]>; [email protected]
Subject: [PATCH v2] net/iavf: fix wrong Tx context descriptorFrom: Beilei Xing <[email protected]>
Quoted 8 lines
The QW0 of Tx context descriptor should be reset to 0, otherwise the previous hardware writeback value may pollute the next context descriptor write.
Fixes a2b29a7733ef ("net/avf: enable basic Rx Tx")Signed-off-by Qi Zhang <[email protected]>Signed-off-by Beilei Xing <[email protected]>
Applied to dpdk-next-net-intel.
Thanks
Qi