Skip to content
Commit 622ab656 authored by Edward Cree's avatar Edward Cree Committed by Jakub Kicinski
Browse files

sfc: fix error unwinds in TC offload



Failure ladders weren't exactly unwinding what the function had done up
 to that point; most seriously, when we encountered an already offloaded
 rule, the failure path tried to remove the new rule from the hashtable,
 which would in fact remove the already-present 'old' rule (since it has
 the same key) from the table, and leak its resources.

Reported-by: default avatarkernel test robot <lkp@intel.com>
Reported-by: default avatarDan Carpenter <error27@gmail.com>
Closes: https://lore.kernel.org/r/202305200745.xmIlkqjH-lkp@intel.com/
Fixes: d902e1a7 ("sfc: bare bones TC offload on EF100")
Fixes: 17654d84

 ("sfc: add offloading of 'foreign' TC (decap) rules")
Signed-off-by: default avatarEdward Cree <ecree.xilinx@gmail.com>
Reviewed-by: default avatarSimon Horman <simon.horman@corigine.com>
Link: https://lore.kernel.org/r/20230530202527.53115-1-edward.cree@amd.com


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
parent 448a5ce1
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment