Skip to content

Commit fd23e0e

Browse files
idoschdavem330
authored andcommitted
net/sched: flower: Avoid overwriting error messages
The various error paths of tc_setup_offload_action() now report specific error messages. Remove the generic messages to avoid overwriting the more specific ones. Before: # tc filter add dev dummy0 ingress pref 1 proto ip flower skip_sw dst_ip 198.51.100.1 action police rate 100Mbit burst 10000 Error: cls_flower: Failed to setup flow action. We have an error talking to the kernel After: # tc filter add dev dummy0 ingress pref 1 proto ip flower skip_sw dst_ip 198.51.100.1 action police rate 100Mbit burst 10000 Error: act_police: Offload not supported when conform/exceed action is "reclassify". We have an error talking to the kernel Signed-off-by: Ido Schimmel <[email protected]> Reviewed-by: Petr Machata <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 0cba5c3 commit fd23e0e

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

net/sched/cls_flower.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -468,8 +468,6 @@ static int fl_hw_replace_filter(struct tcf_proto *tp,
468468
cls_flower.common.extack);
469469
if (err) {
470470
kfree(cls_flower.rule);
471-
NL_SET_ERR_MSG_MOD(cls_flower.common.extack,
472-
"Failed to setup flow action");
473471

474472
return skip_sw ? err : 0;
475473
}
@@ -2358,8 +2356,6 @@ static int fl_reoffload(struct tcf_proto *tp, bool add, flow_setup_cb_t *cb,
23582356
cls_flower.common.extack);
23592357
if (err) {
23602358
kfree(cls_flower.rule);
2361-
NL_SET_ERR_MSG_MOD(cls_flower.common.extack,
2362-
"Failed to setup flow action");
23632359
if (tc_skip_sw(f->flags)) {
23642360
__fl_put(f);
23652361
return err;

0 commit comments

Comments
 (0)