net/bnxt: fix Rx queue start/stop for Thor based NICs
authorLance Richardson <lance.richardson@broadcom.com>
Mon, 4 Nov 2019 20:27:47 +0000 (15:27 -0500)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 8 Nov 2019 22:15:04 +0000 (23:15 +0100)
commitfc4bfea59696cfba397c31ec842b6656fc27f50a
treed1149b5006ae8eeaff713a5cf552e583feec88a2
parent67678ec0769fd4df3d9c7aceb5e6da6e7f0ce7a6
net/bnxt: fix Rx queue start/stop for Thor based NICs

Controller-specific handling is required for Thor-based NICs when
stopping or starting a receive queue, otherwise packet reception
may not be reliably resumed when a stopped receive queue is
restarted:
  - The VNIC default receive ring needs to be recomputed when a
    receive queue is stopped or started.
  - When stopping the last (or only) receive queue for a given
    VNIC, ensure that no packets can reach the default receive
    ring by temporarily setting the VNIC MRU to zero.

Fixes: f8168ca0e690 ("net/bnxt: support thor controller")
Cc: stable@dpdk.org
Signed-off-by: Lance Richardson <lance.richardson@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
drivers/net/bnxt/bnxt_hwrm.c
drivers/net/bnxt/bnxt_rxq.c