Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 55593960 authored by Or Gerlitz's avatar Or Gerlitz Committed by David S. Miller
Browse files

net/sched: cls_flower: Reflect HW offload status



Flower support for the "in hw" offloading flags.

Signed-off-by: default avatarOr Gerlitz <ogerlitz@mellanox.com>
Reviewed-by: default avatarAmir Vadai <amir@vadai.me>
Acked-by: default avatarJiri Pirko <jiri@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent e696028a
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -273,6 +273,8 @@ static int fl_hw_replace_filter(struct tcf_proto *tp,

	err = dev->netdev_ops->ndo_setup_tc(dev, tp->q->handle, tp->protocol,
					    tc);
	if (!err)
		f->flags |= TCA_CLS_FLAGS_IN_HW;

	if (tc_skip_sw(f->flags))
		return err;
@@ -912,6 +914,9 @@ static int fl_change(struct net *net, struct sk_buff *in_skb,
			goto errout;
	}

	if (!tc_in_hw(fnew->flags))
		fnew->flags |= TCA_CLS_FLAGS_NOT_IN_HW;

	if (fold) {
		if (!tc_skip_sw(fold->flags))
			rhashtable_remove_fast(&head->ht, &fold->ht_node,