projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2102a27
)
flow_offload: improve extack msg for user when adding invalid filter
author
Baowen Zheng
<baowen.zheng@corigine.com>
Wed, 2 Mar 2022 03:29:29 +0000
(11:29 +0800)
committer
Jakub Kicinski
<kuba@kernel.org>
Thu, 3 Mar 2022 06:16:10 +0000
(22:16 -0800)
Add extack message to return exact message to user when adding invalid
filter with conflict flags for TC action.
In previous implement we just return EINVAL which is confusing for user.
Signed-off-by: Baowen Zheng <baowen.zheng@corigine.com>
Reviewed-by: Roi Dayan <roid@nvidia.com>
Link:
https://lore.kernel.org/r/1646191769-17761-1-git-send-email-baowen.zheng@corigine.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/sched/act_api.c
patch
|
blob
|
history
diff --git
a/net/sched/act_api.c
b/net/sched/act_api.c
index ca03e72842541f131f9e54dc112ab92a7519b458..4f51094da9dab75d882b43bc8aa013266e55ccfd 100644
(file)
--- a/
net/sched/act_api.c
+++ b/
net/sched/act_api.c
@@
-1446,6
+1446,8
@@
int tcf_action_init(struct net *net, struct tcf_proto *tp, struct nlattr *nla,
continue;
if (skip_sw != tc_act_skip_sw(act->tcfa_flags) ||
skip_hw != tc_act_skip_hw(act->tcfa_flags)) {
+ NL_SET_ERR_MSG(extack,
+ "Mismatch between action and filter offload flags");
err = -EINVAL;
goto err;
}