net/bnxt: fix representor data path
authorSomnath Kotur <somnath.kotur@broadcom.com>
Fri, 11 Sep 2020 01:56:00 +0000 (18:56 -0700)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 18 Sep 2020 16:55:12 +0000 (18:55 +0200)
commit526e0b02008d4f0b6b10672266677ebee0ac2cbd
tree20fa8301675a5465f15f978fda80bb25105f4469
parent9b842a93e21afb16226577c8bb2a7a5bca60c2e0
net/bnxt: fix representor data path

1.Representor Rx ring producer index was not getting reset in
the ring full case. Fix it by incrementing only in
success case.
2.Instead of calling the mbuf specific routine to free the mbuf when
representor ring is full rte_free was being called leading to
'invalid memory' errors being logged.
3. Do not account the pkt meant for the representor in the parent
Rx ring's array that is returned to the application.

Fixes: 6dc83230b43b ("net/bnxt: support port representor data path")
Cc: stable@dpdk.org
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Sriharsha Basavapatna <sriharsha.basavapatna@broadcom.com>
Reviewed-by: Venkat Duvvuru <venkatkumar.duvvuru@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
drivers/net/bnxt/bnxt_reps.c
drivers/net/bnxt/bnxt_rxr.c