net/thunderx: fix Tx desc corruption in scatter-gather mode
authorSubrahmanyam Nilla <snilla@caviumnetworks.com>
Fri, 9 Nov 2018 05:50:55 +0000 (05:50 +0000)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 13 Nov 2018 23:35:53 +0000 (00:35 +0100)
commit823ebfc219f3fa53361afc7ce663f72464bfb3ff
tree4e43fa41da5d04898c366b894ef41c7eb9a7d75d
parent27e5d9000c55d9e7c0257ff284159a642d269b40
net/thunderx: fix Tx desc corruption in scatter-gather mode

For performance reasons, word1 of send_hdr_s
sub descriptor was not cleared assuming it is always
having default value of zero since it comes from fixed
offsets of SQ buffer.
This is causing issues in case of SG mode because,
the size of send command might change and hence the word1
of send_hdr_s is not always at fixed offsets of the SQ buffer
and hence not having default value of zero.

This fixes the issue by clearing the word1 in case of SG mode
for every packet.

Fixes: 1c421f18e095 ("net/thunderx: add single and multi-segment Tx")
Cc: stable@dpdk.org
Signed-off-by: Subrahmanyam Nilla <snilla@caviumnetworks.com>
Signed-off-by: Nithin Dabilpuram <nithin.dabilpuram@caviumnetworks.com>
Acked-by: Jerin Jacob <jerin.jacob@caviumnetworks.com>
drivers/net/thunderx/nicvf_rxtx.c