]> www.infradead.org Git - users/jedix/linux-maple.git/commit
bnxt_en: Set initial default RX and TX ring numbers the same in combined mode.
authorMichael Chan <michael.chan@broadcom.com>
Wed, 17 Jan 2018 08:21:08 +0000 (03:21 -0500)
committerJack Vogel <jack.vogel@oracle.com>
Fri, 9 Mar 2018 05:05:39 +0000 (21:05 -0800)
commit3523dcaac7ab561e72dbd991efda0c6316d0db37
tree303f3d916a64927e4ce1682a9a61c7bfe6614ebe
parent302a55567763bdbb61fcc324fd16e3f8f8b6f614
bnxt_en: Set initial default RX and TX ring numbers the same in combined mode.

Orabug: 2764835527648339

In combined mode, the driver is currently not setting RX and TX ring
numbers the same when firmware can allocate more RX than TX or vice versa.
This will confuse the user as the ethtool convention assumes they are the
same in combined mode.  Fix it by adding bnxt_trim_dflt_sh_rings() to trim
RX and TX ring numbers to be the same as the completion ring number in
combined mode.

Note that if TCs are enabled and/or XDP is enabled, the number of TX rings
will not be the same as RX rings in combined mode.

Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 58ea801ac4c166cdcaa399ce7f9b3e9095ff2842)
Signed-off-by: Brian Maly <brian.maly@oracle.com>
Reviewed-by: Jack Vogel <jack.vogel@oracle.com>
drivers/net/ethernet/broadcom/bnxt/bnxt.c