aboutsummaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorPedro Tammela2023-02-24 14:56:01 -0300
committerGreg Kroah-Hartman2023-06-21 16:01:02 +0200
commit8f375998110473702d284edd544f6bd096b2338d (patch)
treede93dca84bb79e62fc27baf8328de06fa2d2deab /net
parent4b4cae8e4b37c7ad4d9721dbda060a62e49e3c17 (diff)
net/sched: act_api: move TCA_EXT_WARN_MSG to the correct hierarchy
commit 923b2e30dc9cd05931da0f64e2e23d040865c035 upstream. TCA_EXT_WARN_MSG is currently sitting outside of the expected hierarchy for the tc actions code. It should sit within TCA_ACT_TAB. Fixes: 0349b8779cc9 ("sched: add new attr TCA_EXT_WARN_MSG to report tc extact message") Reviewed-by: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-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: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net')
-rw-r--r--net/sched/act_api.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/sched/act_api.c b/net/sched/act_api.c
index cc6628a42e83..2bdcaf4f9285 100644
--- a/net/sched/act_api.c
+++ b/net/sched/act_api.c
@@ -1603,12 +1603,12 @@ static int tca_get_fill(struct sk_buff *skb, struct tc_action *actions[],
if (tcf_action_dump(skb, actions, bind, ref, false) < 0)
goto out_nlmsg_trim;
- nla_nest_end(skb, nest);
-
if (extack && extack->_msg &&
nla_put_string(skb, TCA_EXT_WARN_MSG, extack->_msg))
goto out_nlmsg_trim;
+ nla_nest_end(skb, nest);
+
nlh->nlmsg_len = skb_tail_pointer(skb) - b;
return skb->len;