From 17917ff85a3765df6cc72fafa132d1539cabe58e Mon Sep 17 00:00:00 2001 From: Ksawlii Date: Sun, 24 Nov 2024 00:23:55 +0100 Subject: [PATCH] Revert "netfilter: nf_tables: set element extended ACK reporting support" This reverts commit 466cd07e9a4d6885e228531f3c6aac25b9b3fbc4. --- net/netfilter/nf_tables_api.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/net/netfilter/nf_tables_api.c b/net/netfilter/nf_tables_api.c index 0bc92edb7..f4bbddfbb 100755 --- a/net/netfilter/nf_tables_api.c +++ b/net/netfilter/nf_tables_api.c @@ -5354,10 +5354,8 @@ static int nf_tables_getsetelem(struct net *net, struct sock *nlsk, nla_for_each_nested(attr, nla[NFTA_SET_ELEM_LIST_ELEMENTS], rem) { err = nft_get_set_elem(&ctx, set, attr); - if (err < 0) { - NL_SET_BAD_ATTR(extack, attr); + if (err < 0) break; - } } return err; @@ -5850,10 +5848,8 @@ static int nf_tables_newsetelem(struct net *net, struct sock *nlsk, nla_for_each_nested(attr, nla[NFTA_SET_ELEM_LIST_ELEMENTS], rem) { err = nft_add_set_elem(&ctx, set, attr, nlh->nlmsg_flags); - if (err < 0) { - NL_SET_BAD_ATTR(extack, attr); + if (err < 0) return err; - } } if (nft_net->validate_state == NFT_VALIDATE_DO) @@ -6062,10 +6058,9 @@ static int nf_tables_delsetelem(struct net *net, struct sock *nlsk, nla_for_each_nested(attr, nla[NFTA_SET_ELEM_LIST_ELEMENTS], rem) { err = nft_del_setelem(&ctx, set, attr); - if (err < 0) { - NL_SET_BAD_ATTR(extack, attr); + if (err < 0) break; - } + set->ndeact++; } return err;