]> git.baikalelectronics.ru Git - kernel.git/commit
bnxt_en: fix potentially incorrect return value for ndo_rx_flow_steer
authorAlex Barba <alex.barba@broadcom.com>
Thu, 3 Nov 2022 23:33:27 +0000 (19:33 -0400)
committerJakub Kicinski <kuba@kernel.org>
Sat, 5 Nov 2022 02:29:03 +0000 (19:29 -0700)
commitc573420b9bd941f5d79f7d4dc8195518423a5811
tree78bc4f312bef6a43ed4e6213ee37ed7d28bd94b9
parentd9d9709fc8b794a5b1f1f006a08653ef6a67eb88
bnxt_en: fix potentially incorrect return value for ndo_rx_flow_steer

In the bnxt_en driver ndo_rx_flow_steer returns '0' whenever an entry
that we are attempting to steer is already found.  This is not the
correct behavior.  The return code should be the value/index that
corresponds to the entry.  Returning zero all the time causes the
RFS records to be incorrect unless entry '0' is the correct one.  As
flows migrate to different cores this can create entries that are not
correct.

Fixes: dfe047769e71 ("bnxt_en: New Broadcom ethernet driver.")
Reported-by: Akshay Navgire <anavgire@purestorage.com>
Signed-off-by: Alex Barba <alex.barba@broadcom.com>
Signed-off-by: Andy Gospodarek <gospo@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/broadcom/bnxt/bnxt.c