netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Kicinski <jakub.kicinski@netronome.com>
To: davem@davemloft.net, daniel@iogearbox.net,
	alexei.starovoitov@gmail.com, netdev@vger.kernel.org
Cc: dsahern@gmail.com, oss-drivers@netronome.com, jiri@resnulli.us,
	john.fastabend@gmail.com, jhs@mojatatu.com, gerlitz.or@gmail.com,
	aring@mojatatu.com, xiyou.wangcong@gmail.com,
	Quentin Monnet <quentin.monnet@netronome.com>
Subject: [PATCH bpf-next v3 03/11] net: sched: cls_matchall: propagate extack support for filter offload
Date: Tue, 16 Jan 2018 13:38:31 -0800	[thread overview]
Message-ID: <20180116213839.24537-4-jakub.kicinski@netronome.com> (raw)
In-Reply-To: <20180116213839.24537-1-jakub.kicinski@netronome.com>

From: Quentin Monnet <quentin.monnet@netronome.com>

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>
---
 net/sched/cls_matchall.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/net/sched/cls_matchall.c b/net/sched/cls_matchall.c
index dc3c57116bbd..16752abcb76b 100644
--- a/net/sched/cls_matchall.c
+++ b/net/sched/cls_matchall.c
@@ -85,7 +85,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;
@@ -202,7 +203,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;
 	}
-- 
2.15.1

  parent reply	other threads:[~2018-01-16 21:39 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-16 21:38 [PATCH bpf-next v3 00/11] net: sched: add extack support for cls offload Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 01/11] net: sched: add extack support to change() classifier operation Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 02/11] net: sched: cls_flower: propagate extack support for filter offload Jakub Kicinski
2018-01-16 21:38 ` Jakub Kicinski [this message]
2018-01-16 21:38 ` [PATCH bpf-next v3 04/11] net: sched: cls_u32: " Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 05/11] net: sched: cls_bpf: plumb extack support in filter for hardware offload Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 06/11] net: sched: add extack support for offload via tc_cls_common_offload Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 07/11] net: sched: create tc_can_offload_extack() wrapper Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 08/11] nfp: bpf: plumb extack into functions related to XDP offload Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 09/11] nfp: bpf: use extack support to improve debugging Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 10/11] netdevsim: add extack support for TC eBPF offload Jakub Kicinski
2018-01-16 21:38 ` [PATCH bpf-next v3 11/11] selftests/bpf: add checks on extack messages for eBPF hw offload tests Jakub Kicinski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180116213839.24537-4-jakub.kicinski@netronome.com \
    --to=jakub.kicinski@netronome.com \
    --cc=alexei.starovoitov@gmail.com \
    --cc=aring@mojatatu.com \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=dsahern@gmail.com \
    --cc=gerlitz.or@gmail.com \
    --cc=jhs@mojatatu.com \
    --cc=jiri@resnulli.us \
    --cc=john.fastabend@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=oss-drivers@netronome.com \
    --cc=quentin.monnet@netronome.com \
    --cc=xiyou.wangcong@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).