RDMA/bnxt_re: Fix stats counters
authorNaresh Kumar PBS <nareshkumar.pbs@broadcom.com>
Sun, 11 Jul 2021 13:31:36 +0000 (06:31 -0700)
committerJason Gunthorpe <jgg@nvidia.com>
Mon, 12 Jul 2021 17:42:27 +0000 (14:42 -0300)
commit0c23af52ccd1605926480b5dfd1dd857ef604611
tree098966ac4df41412b1def4d2a030780c96faa5a8
parente73f0f0ee7541171d89f2e2491130c7771ba58d3
RDMA/bnxt_re: Fix stats counters

Statistical counters are not incrementing in some adapter versions with
newer FW. This is due to the stats context length mismatch between FW and
driver. Since the L2 driver updates the length correctly, use the stats
length from L2 driver while allocating the DMA'able memory and creating
the stats context.

Fixes: 9d6b648c3112 ("bnxt_en: Update firmware interface spec to 1.10.1.65.")
Link: https://lore.kernel.org/r/1626010296-6076-1-git-send-email-selvin.xavier@broadcom.com
Signed-off-by: Naresh Kumar PBS <nareshkumar.pbs@broadcom.com>
Signed-off-by: Selvin Xavier <selvin.xavier@broadcom.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/hw/bnxt_re/main.c
drivers/infiniband/hw/bnxt_re/qplib_res.c
drivers/infiniband/hw/bnxt_re/qplib_res.h