bnxt_en: Fix HDS and jumbo thresholds for RX packets
authorMichael Chan <michael.chan@broadcom.com>
Tue, 27 Dec 2022 03:19:40 +0000 (22:19 -0500)
committerDavid S. Miller <davem@davemloft.net>
Wed, 28 Dec 2022 10:16:57 +0000 (10:16 +0000)
commita056ebcc30e2f78451d66f615d2f6bdada3e6438
tree91945c50902ddd7e70352c2447e024ee76c5ed21
parent1abeacc1979fa4a756695f5030791d8f0fa934b9
bnxt_en: Fix HDS and jumbo thresholds for RX packets

The recent XDP multi-buffer feature has introduced regressions in the
setting of HDS and jumbo thresholds.  HDS was accidentally disabled in
the nornmal mode without XDP.  This patch restores jumbo HDS placement
when not in XDP mode.  In XDP multi-buffer mode, HDS should be disabled
and the jumbo threshold should be set to the usable page size in the
first page buffer.

Fixes: 32861236190b ("bnxt: change receive ring space parameters")
Reviewed-by: Mohammad Shuab Siddique <mohammad-shuab.siddique@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Andy Gospodarek <andrew.gospodarek@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bnxt/bnxt.c