Skip to content

Commit

Permalink
net: sched: cls_matchall: propagate extack support for filter offload
Browse files Browse the repository at this point in the history
Propagate the extack pointer from the `->change()` classifier operation
to the function used for filter replacement in cls_matchall. This makes
it possible to use netlink extack messages in the future at replacement
time for this filter, although it is not used at this point.

Signed-off-by: Quentin Monnet <quentin.monnet@netronome.com>
Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Quentin Monnet authored and David S. Miller committed Jan 22, 2018
1 parent 4100203 commit 0279814
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions net/sched/cls_matchall.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,8 @@ static void mall_destroy_hw_filter(struct tcf_proto *tp,

static int mall_replace_hw_filter(struct tcf_proto *tp,
struct cls_mall_head *head,
unsigned long cookie)
unsigned long cookie,
struct netlink_ext_ack *extack)
{
struct tc_cls_matchall_offload cls_mall = {};
struct tcf_block *block = tp->chain->block;
Expand Down Expand Up @@ -205,7 +206,8 @@ static int mall_change(struct net *net, struct sk_buff *in_skb,
goto err_set_parms;

if (!tc_skip_hw(new->flags)) {
err = mall_replace_hw_filter(tp, new, (unsigned long)new);
err = mall_replace_hw_filter(tp, new, (unsigned long)new,
extack);
if (err)
goto err_replace_hw_filter;
}
Expand Down

0 comments on commit 0279814

Please sign in to comment.