Nelson Escobar
ce93d3c36d
net/enic: fix resource check failures when bonding devices
The enic PMD was using the same variables in the enic structure to track two different things. Initially rq_count, wq_count, cq_count, and intr_count were set to the values obtained from the VIC adapters as the maximum resources allocated on the VIC, then in enic_set_vnic_res(), they were set to the counts of resources actually used, discarding the initial values. The checks in enic_set_vnic_res() were technically incorrect if it is called more than once on a port, which happens when using bonding, but were harmless in practice as the checks couldn't fail on the second call. The enic rx-scatter patch misunderstood the subtleties of enic_set_vnic_res(), and naively added a multiply by two to the rq_count check. This resulted in the rq_count check failing when enic_set_vnic_res() was called a second time, ie when using bonding. This patch adds new variables to the enic structure to track the maximum resources the VIC is configured to provide so that the information isn't later lost and calls to enic_set_vnic_res() do the expected thing. Fixes: 856d7ba7ed22 ("net/enic: support scattered Rx") Signed-off-by: Nelson Escobar <neescoba@cisco.com>
DPDK is a set of libraries and drivers for fast packet processing. It supports many processor architectures and both FreeBSD and Linux. The DPDK uses the Open Source BSD license for the core libraries and drivers. The kernel components are GPLv2 licensed. Please check the doc directory for release notes, API documentation, and sample application information. For questions and usage discussions, subscribe to: users@dpdk.org Report bugs and issues to the development mailing list: dev@dpdk.org
Description
Languages
C
99.1%
Meson
0.5%
Python
0.2%
Shell
0.1%