From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pablo Neira Ayuso Subject: [PATCH net-next,v5 08/12] flow_offload: add wake-up-on-lan and queue to flow_action Date: Thu, 6 Dec 2018 23:39:58 +0100 Message-ID: <20181206224002.5109-9-pablo@netfilter.org> References: <20181206224002.5109-1-pablo@netfilter.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 To: netdev@vger.kernel.org Return-path: Received: from mail.us.es ([193.147.175.20]:46542 "EHLO mail.us.es" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725935AbeLFWkm (ORCPT ); Thu, 6 Dec 2018 17:40:42 -0500 Received: from antivirus1-rhel7.int (unknown [192.168.2.11]) by mail.us.es (Postfix) with ESMTP id 6D0F815C101 for ; Thu, 6 Dec 2018 23:40:40 +0100 (CET) Received: from antivirus1-rhel7.int (localhost [127.0.0.1]) by antivirus1-rhel7.int (Postfix) with ESMTP id 4EFEEDA7F2 for ; Thu, 6 Dec 2018 23:40:40 +0100 (CET) In-Reply-To: <20181206224002.5109-1-pablo@netfilter.org> Sender: netdev-owner@vger.kernel.org List-ID: These actions need to be added to support the ethtool_rx_flow interface. The queue action includes a field to specify the RSS context, that is set via FLOW_RSS flow type flag and the rss_context field in struct ethtool_rxnfc, plus the corresponding queue index. FLOW_RSS implies that rss_context is non-zero, therefore, queue.ctx == 0 means that FLOW_RSS was not set. Signed-off-by: Pablo Neira Ayuso --- v5: add queue structure and context field, per Michal Kubecek. include/net/flow_offload.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/net/flow_offload.h b/include/net/flow_offload.h index f9ce39992dbd..6489fb9eb394 100644 --- a/include/net/flow_offload.h +++ b/include/net/flow_offload.h @@ -116,6 +116,8 @@ enum flow_action_id { FLOW_ACTION_ADD, FLOW_ACTION_CSUM, FLOW_ACTION_MARK, + FLOW_ACTION_WAKE, + FLOW_ACTION_QUEUE, }; /* This is mirroring enum pedit_header_type definition for easy mapping between @@ -150,6 +152,10 @@ struct flow_action_entry { const struct ip_tunnel_info *tunnel; /* FLOW_ACTION_TUNNEL_ENCAP */ u32 csum_flags; /* FLOW_ACTION_CSUM */ u32 mark; /* FLOW_ACTION_MARK */ + struct { /* FLOW_ACTION_QUEUE */ + u32 ctx; + u32 index; + } queue; }; }; -- 2.11.0