From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.5 required=3.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_PASS,URIBL_BLOCKED,USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DE7E1C282D7 for ; Sat, 2 Feb 2019 15:28:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 87DCD2084A for ; Sat, 2 Feb 2019 15:28:22 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=resnulli-us.20150623.gappssmtp.com header.i=@resnulli-us.20150623.gappssmtp.com header.b="RzA8S7+i" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727778AbfBBP2V (ORCPT ); Sat, 2 Feb 2019 10:28:21 -0500 Received: from mail-wm1-f65.google.com ([209.85.128.65]:35985 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727366AbfBBP2V (ORCPT ); Sat, 2 Feb 2019 10:28:21 -0500 Received: by mail-wm1-f65.google.com with SMTP id p6so9082013wmc.1 for ; Sat, 02 Feb 2019 07:28:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=resnulli-us.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=D+C1Ks3uLyH3gdWJZqhUpGZaNqNx5DKJVFIxo3SyMmo=; b=RzA8S7+iKzpM0B2BnR4mJqfiyu92WCkCYYuPjc/tMR519k8iqCFWugNx56gF5qj+KV FZJsQisSmsWZbPf9DGGd6K6W1yFsRbjfqEP7t5JzrYOzBKVZs2nAX86Am2iu4r68uFP6 yIZyhAQBEVEnby4fpynM98A2W7BWy1ityxd0Ei+R3GHtjeW9D3ZrJ+FNrxHIf9wnVcG9 rF8xu+J/6XNDaYsfnMOrS5tGktpa7STchR4nKM4zXxdiqzabf9NdE8yAYlW2s6B5wz8M YdAPyV3Qt6SyR/mOCoI6kOW4pH5p65mkJ8KqOXMqW9dt9ItyN5cxXnVSYz2cDJCfoFKU ocLw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=D+C1Ks3uLyH3gdWJZqhUpGZaNqNx5DKJVFIxo3SyMmo=; b=k0SCLUayybSFsykTqJoGGqdVTHElqZnWruGLQu0CAKFWhBEw8zqVUK90AloDo4QlJT q1pL4Q/9oXmD/BqwiHC/+XrdQ8wSmkkhtahwfkSrjVY2uHlGsEbDzFRfEbC+0UM0BWN7 yHueIT8bhYSnmAitT/ZdRcQsZX55bfPkjlhzbmsA+zafNzEPzt8c6pJem8093oC8CfFq kkpvh1bcwt8aMpINpGYgWK7P8MCW3Vo9rY86imAsl0a6cUcRZxJ/7EWbyH2pfImC4IPf z61XC+Ffi9Ii/Yuv8MO+ZQgU9mjWvhUPFYeRhuIyzAOj5G7IsP7vyI+wn1R5vxsLOuml fCSg== X-Gm-Message-State: AHQUAuZadmtSo58ZD/FNjvkJrNl8c/BdIfziiCpEQAGd9pO+BuH5SJAi VyJ6xmHTB2lebaRF0xHrLRu3bA== X-Google-Smtp-Source: AHgI3IbBOND7K+zjMYRqWmd71F5NPNqHFF1ZLBTgxNDrbHRkHzcVqiqGRQbxXKVyBzSQ4WE41YwZeA== X-Received: by 2002:a1c:448a:: with SMTP id r132mr6458968wma.47.1549121299274; Sat, 02 Feb 2019 07:28:19 -0800 (PST) Received: from localhost (jirka.pirko.cz. [84.16.102.26]) by smtp.gmail.com with ESMTPSA id j8sm6721835wrt.40.2019.02.02.07.28.18 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 02 Feb 2019 07:28:18 -0800 (PST) Date: Sat, 2 Feb 2019 16:19:14 +0100 From: Jiri Pirko To: Pablo Neira Ayuso Cc: netdev@vger.kernel.org, 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, netfilter-devel@vger.kernel.org, cphealy@gmail.com Subject: Re: [PATCH 01/12 net-next,v7] flow_offload: add flow_rule and flow_match structures and use them Message-ID: <20190202151914.GA2778@nanopsycho> References: <20190202115054.4880-1-pablo@netfilter.org> <20190202115054.4880-2-pablo@netfilter.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190202115054.4880-2-pablo@netfilter.org> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Sat, Feb 02, 2019 at 12:50:43PM CET, pablo@netfilter.org wrote: >This patch wraps the dissector key and mask - that flower uses to >represent the matching side - around the flow_match structure. > >To avoid a follow up patch that would edit the same LoCs in the drivers, >this patch also wraps this new flow match structure around the flow rule >object. This new structure will also contain the flow actions in follow >up patches. > >This introduces two new interfaces: > > bool flow_rule_match_key(rule, dissector_id) > >that returns true if a given matching key is set on, and: > > flow_rule_match_XYZ(rule, &match); > >To fetch the matching side XYZ into the match container structure, to >retrieve the key and the mask with one single call. > >Signed-off-by: Pablo Neira Ayuso >--- >v7: rebase on top of net-next. Dropping previous Acked-by tags since > this one is slightly large, and it would be good another look after > this rebase. Looks good to me. Acked-by: Jiri Pirko From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jiri Pirko Subject: Re: [PATCH 01/12 net-next,v7] flow_offload: add flow_rule and flow_match structures and use them Date: Sat, 2 Feb 2019 16:19:14 +0100 Message-ID: <20190202151914.GA2778@nanopsycho> References: <20190202115054.4880-1-pablo@netfilter.org> <20190202115054.4880-2-pablo@netfilter.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: netdev@vger.kernel.org, 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, netfilter-devel@v To: Pablo Neira Ayuso Return-path: Content-Disposition: inline In-Reply-To: <20190202115054.4880-2-pablo@netfilter.org> Sender: netdev-owner@vger.kernel.org List-Id: netfilter-devel.vger.kernel.org Sat, Feb 02, 2019 at 12:50:43PM CET, pablo@netfilter.org wrote: >This patch wraps the dissector key and mask - that flower uses to >represent the matching side - around the flow_match structure. > >To avoid a follow up patch that would edit the same LoCs in the drivers, >this patch also wraps this new flow match structure around the flow rule >object. This new structure will also contain the flow actions in follow >up patches. > >This introduces two new interfaces: > > bool flow_rule_match_key(rule, dissector_id) > >that returns true if a given matching key is set on, and: > > flow_rule_match_XYZ(rule, &match); > >To fetch the matching side XYZ into the match container structure, to >retrieve the key and the mask with one single call. > >Signed-off-by: Pablo Neira Ayuso >--- >v7: rebase on top of net-next. Dropping previous Acked-by tags since > this one is slightly large, and it would be good another look after > this rebase. Looks good to me. Acked-by: Jiri Pirko