net: sched: cls_u32: Undo tcf_bind_filter if u32_replace_hw_knode
authorVictor Nogueira <victor@mojatatu.com>
Thu, 13 Jul 2023 18:05:11 +0000 (15:05 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 Jul 2023 06:50:41 +0000 (08:50 +0200)
commita9345793469b65ee5ba7b033239916c2a67d3dd4
tree41d942dbd14f4fbf9476f71d059420c50dfc1257
parentfa753f8656777c5caaed54d5c4c71e1ef8a17641
net: sched: cls_u32: Undo tcf_bind_filter if u32_replace_hw_knode

[ Upstream commit 9cb36faedeafb9720ac236aeae2ea57091d90a09 ]

When u32_replace_hw_knode fails, we need to undo the tcf_bind_filter
operation done at u32_set_parms.

Fixes: d34e3e181395 ("net: cls_u32: Add support for skip-sw flag to tc u32 classifier.")
Signed-off-by: Victor Nogueira <victor@mojatatu.com>
Acked-by: Jamal Hadi Salim <jhs@mojatatu.com>
Reviewed-by: Pedro Tammela <pctammela@mojatatu.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/sched/cls_u32.c