From patchwork Fri Dec 14 18:12:00 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Pablo Neira Ayuso X-Patchwork-Id: 1013666 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming-netdev@ozlabs.org Delivered-To: patchwork-incoming-netdev@ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=vger.kernel.org (client-ip=209.132.180.67; helo=vger.kernel.org; envelope-from=netdev-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=netfilter.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 43Gdv33sNNz9s3C for ; Sat, 15 Dec 2018 05:12:47 +1100 (AEDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730539AbeLNSMq (ORCPT ); Fri, 14 Dec 2018 13:12:46 -0500 Received: from mail.us.es ([193.147.175.20]:56930 "EHLO mail.us.es" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726662AbeLNSMp (ORCPT ); Fri, 14 Dec 2018 13:12:45 -0500 Received: from antivirus1-rhel7.int (unknown [192.168.2.11]) by mail.us.es (Postfix) with ESMTP id 9B7822519A0 for ; Fri, 14 Dec 2018 19:12:43 +0100 (CET) Received: from antivirus1-rhel7.int (localhost [127.0.0.1]) by antivirus1-rhel7.int (Postfix) with ESMTP id 83480DA4DA for ; Fri, 14 Dec 2018 19:12:43 +0100 (CET) Received: by antivirus1-rhel7.int (Postfix, from userid 99) id 7CC13DA4D8; Fri, 14 Dec 2018 19:12:43 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on antivirus1-rhel7.int X-Spam-Level: X-Spam-Status: No, score=-108.2 required=7.5 tests=ALL_TRUSTED,BAYES_50, SMTPAUTH_US2,USER_IN_WHITELIST autolearn=disabled version=3.4.1 Received: from antivirus1-rhel7.int (localhost [127.0.0.1]) by antivirus1-rhel7.int (Postfix) with ESMTP id 5D37EDA4D4; Fri, 14 Dec 2018 19:12:29 +0100 (CET) Received: from 192.168.1.97 (192.168.1.97) by antivirus1-rhel7.int (F-Secure/fsigk_smtp/550/antivirus1-rhel7.int); Fri, 14 Dec 2018 19:12:29 +0100 (CET) X-Virus-Status: clean(F-Secure/fsigk_smtp/550/antivirus1-rhel7.int) Received: from salvia.here (sys.soleta.eu [212.170.55.40]) (Authenticated sender: pneira@us.es) by entrada.int (Postfix) with ESMTPA id 1457A4265A4C; Fri, 14 Dec 2018 19:12:28 +0100 (CET) X-SMTPAUTHUS: auth mail.us.es From: Pablo Neira Ayuso To: netdev@vger.kernel.org Cc: davem@davemloft.net, thomas.lendacky@amd.com, f.fainelli@gmail.com, ariel.elior@cavium.com, michael.chan@broadcom.com, santosh@chelsio.com, madalin.bucur@nxp.com, yisen.zhuang@huawei.com, salil.mehta@huawei.com, jeffrey.t.kirsher@intel.com, tariqt@mellanox.com, saeedm@mellanox.com, jiri@mellanox.com, idosch@mellanox.com, jakub.kicinski@netronome.com, peppe.cavallaro@st.com, grygorii.strashko@ti.com, andrew@lunn.ch, vivien.didelot@savoirfairelinux.com, alexandre.torgue@st.com, joabreu@synopsys.com, linux-net-drivers@solarflare.com, ganeshgr@chelsio.com, ogerlitz@mellanox.com, Manish.Chopra@cavium.com, marcelo.leitner@gmail.com, mkubecek@suse.cz, venkatkumar.duvvuru@broadcom.com, julia.lawall@lip6.fr, john.fastabend@gmail.com, jhs@mojatatu.com, gerlitz.or@gmail.com Subject: [PATCH net-next, v6 07/12] cls_flower: don't expose TC actions to drivers anymore Date: Fri, 14 Dec 2018 19:12:00 +0100 Message-Id: <20181214181205.28812-8-pablo@netfilter.org> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20181214181205.28812-1-pablo@netfilter.org> References: <20181214181205.28812-1-pablo@netfilter.org> X-Virus-Scanned: ClamAV using ClamSMTP Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Now that drivers have been converted to use the flow action infrastructure, remove this field from the tc_cls_flower_offload structure. Signed-off-by: Pablo Neira Ayuso Acked-by: Jiri Pirko --- v6: rebase on top of net-next. include/net/pkt_cls.h | 1 - net/sched/cls_flower.c | 5 ----- 2 files changed, 6 deletions(-) diff --git a/include/net/pkt_cls.h b/include/net/pkt_cls.h index a08c06e383db..9bd724bfa860 100644 --- a/include/net/pkt_cls.h +++ b/include/net/pkt_cls.h @@ -768,7 +768,6 @@ struct tc_cls_flower_offload { unsigned long cookie; struct flow_rule *rule; struct flow_stats stats; - struct tcf_exts *exts; u32 classid; }; diff --git a/net/sched/cls_flower.c b/net/sched/cls_flower.c index 8271668d6c60..6502acba1f68 100644 --- a/net/sched/cls_flower.c +++ b/net/sched/cls_flower.c @@ -392,7 +392,6 @@ static int fl_hw_replace_filter(struct tcf_proto *tp, cls_flower.rule->match.dissector = &f->mask->dissector; cls_flower.rule->match.mask = &f->mask->key; cls_flower.rule->match.key = &f->mkey; - cls_flower.exts = &f->exts; cls_flower.classid = f->res.classid; err = tc_setup_flow_action(&cls_flower.rule->action, &f->exts); @@ -427,7 +426,6 @@ static void fl_hw_update_stats(struct tcf_proto *tp, struct cls_fl_filter *f) tc_cls_common_offload_init(&cls_flower.common, tp, f->flags, NULL); cls_flower.command = TC_CLSFLOWER_STATS; cls_flower.cookie = (unsigned long) f; - cls_flower.exts = &f->exts; cls_flower.classid = f->res.classid; tc_setup_cb_call(block, &f->exts, TC_SETUP_CLSFLOWER, @@ -1487,7 +1485,6 @@ static int fl_reoffload(struct tcf_proto *tp, bool add, tc_setup_cb_t *cb, cls_flower.rule->match.dissector = &mask->dissector; cls_flower.rule->match.mask = &mask->key; cls_flower.rule->match.key = &f->mkey; - cls_flower.exts = &f->exts; err = tc_setup_flow_action(&cls_flower.rule->action, &f->exts); @@ -1520,7 +1517,6 @@ static int fl_hw_create_tmplt(struct tcf_chain *chain, { struct tc_cls_flower_offload cls_flower = {}; struct tcf_block *block = chain->block; - struct tcf_exts dummy_exts = { 0, }; cls_flower.rule = flow_rule_alloc(0); if (!cls_flower.rule) @@ -1532,7 +1528,6 @@ static int fl_hw_create_tmplt(struct tcf_chain *chain, cls_flower.rule->match.dissector = &tmplt->dissector; cls_flower.rule->match.mask = &tmplt->mask; cls_flower.rule->match.key = &tmplt->dummy_key; - cls_flower.exts = &dummy_exts; /* We don't care if driver (any of them) fails to handle this * call. It serves just as a hint for it.