summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXiao Zhang <xiao.zhang@intel.com>2019-08-06 07:20:53 +0800
committerKevin Traynor <ktraynor@redhat.com>2019-09-13 10:37:20 +0100
commit0416d451f398895dd6a4ae84a4674e2a16608472 (patch)
treeff4b98768354925707f5c9a8a890c5155c8ad890
parent6b012183b8381fa92f309bd553e2e51e58c00d41 (diff)
downloaddpdk-stable-0416d451f398895dd6a4ae84a4674e2a16608472.zip
dpdk-stable-0416d451f398895dd6a4ae84a4674e2a16608472.tar.gz
dpdk-stable-0416d451f398895dd6a4ae84a4674e2a16608472.tar.xz
net/avf: fix address of first segment
[ upstream commit ba38f91468a896d9363e92261cbf17c6517e098a ] This patch fixes (dereference after null check) coverity issue. The address of first segmented packets was not set correctly during reassembling packets which led to this issue. Coverity issue: 343447 Fixes: 319c421f3890 ("net/avf: enable SSE Rx Tx") Signed-off-by: Xiao Zhang <xiao.zhang@intel.com> Acked-by: Xiaolong Ye <xiaolong.ye@intel.com>
-rw-r--r--drivers/net/avf/avf_rxtx_vec_sse.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/avf/avf_rxtx_vec_sse.c b/drivers/net/avf/avf_rxtx_vec_sse.c
index 343a6aa..13e94ce 100644
--- a/drivers/net/avf/avf_rxtx_vec_sse.c
+++ b/drivers/net/avf/avf_rxtx_vec_sse.c
@@ -521,6 +521,7 @@ avf_recv_scattered_pkts_vec(void *rx_queue, struct rte_mbuf **rx_pkts,
i++;
if (i == nb_bufs)
return nb_bufs;
+ rxq->pkt_first_seg = rx_pkts[i];
}
return i + reassemble_packets(rxq, &rx_pkts[i], nb_bufs - i,
&split_flags[i]);