]> git.baikalelectronics.ru Git - kernel.git/commit
net: bnxt: don't complain if TC flower can't be supported
authorJakub Kicinski <kuba@kernel.org>
Fri, 17 Jul 2020 20:59:58 +0000 (13:59 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sat, 18 Jul 2020 01:26:20 +0000 (18:26 -0700)
commit99f622a056c53cf4ebfb53b3d62aab7712c748ec
treea70192dce8cc746b33fca7d698986a8d0d3c5014
parent61013bf5b5ab70e4e9d814e4544663665f37bede
net: bnxt: don't complain if TC flower can't be supported

The fact that NETIF_F_HW_TC is not set should be a sufficient
indication to the user that TC offloads are not supported.
No need to bother users of older firmware versions with
pointless warnings on every boot.

Also, since the support is optional, bnxt_init_tc() should not
return an error in case FW is old, similarly to how error
is not returned when CONFIG_BNXT_FLOWER_OFFLOAD is not set.

With that we can add an error message to the caller, to warn
about actual unexpected failures.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Reviewed-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bnxt/bnxt.c
drivers/net/ethernet/broadcom/bnxt/bnxt_tc.c