summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorYongseok Koh <yskoh@mellanox.com>2019-01-14 02:00:21 -0800
committerFerruh Yigit <ferruh.yigit@intel.com>2019-01-14 17:44:29 +0100
commitcc28a6907b228d55f02bfbf0a40498db0a22ea62 (patch)
tree58bc810f71c78d050a2ea412c4b50a518c9f2438 /app
parent04df418f0fafa03f5f9f6326d3e1e517a1eaec47 (diff)
downloaddpdk-next-eventdev-cc28a6907b228d55f02bfbf0a40498db0a22ea62.zip
dpdk-next-eventdev-cc28a6907b228d55f02bfbf0a40498db0a22ea62.tar.gz
dpdk-next-eventdev-cc28a6907b228d55f02bfbf0a40498db0a22ea62.tar.xz
app/testpmd: fix pointer reference in macswap
The pointer is misused and could set wrong MAC address. As a result, some of packets can be dropped in receiver side due to MAC address mismatch. This can be shown as performance degradation. Bugzilla ID: 188 Fixes: 62b52877adbe ("app/testpmd: batch MAC swap for performance on x86") Signed-off-by: Yongseok Koh <yskoh@mellanox.com> Acked-by: Bernard Iremonger <bernard.iremonger@intel.com>
Diffstat (limited to 'app')
-rw-r--r--app/test-pmd/macswap_sse.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/test-pmd/macswap_sse.h b/app/test-pmd/macswap_sse.h
index 7d268bf..662fe79 100644
--- a/app/test-pmd/macswap_sse.h
+++ b/app/test-pmd/macswap_sse.h
@@ -76,7 +76,7 @@ do_macswap(struct rte_mbuf *pkts[], uint16_t nb,
eth_hdr[0] = rte_pktmbuf_mtod(mb[0], struct ether_hdr *);
/* Swap dest and src mac addresses. */
- addr0 = _mm_loadu_si128((__m128i *)eth_hdr);
+ addr0 = _mm_loadu_si128((__m128i *)eth_hdr[0]);
addr0 = _mm_shuffle_epi8(addr0, shfl_msk);
_mm_storeu_si128((__m128i *)eth_hdr[0], addr0);