netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Florian Fainelli <f.fainelli@gmail.com>
To: Jiri Pirko <jiri@resnulli.us>, netdev@vger.kernel.org
Cc: davem@davemloft.net, idosch@mellanox.com, eladr@mellanox.com,
	mlxsw@mellanox.com, ogerlitz@mellanox.com, jhs@mojatatu.com,
	ivecera@redhat.com, jbenc@redhat.com
Subject: Re: [patch net-next 19/19] mlxsw: spectrum: Implement TC flower offload
Date: Thu, 2 Feb 2017 13:37:23 -0800	[thread overview]
Message-ID: <2bf7a90d-6ec4-8265-bb29-7797e262e570@gmail.com> (raw)
In-Reply-To: <1486048379-19237-20-git-send-email-jiri@resnulli.us>

On 02/02/2017 07:12 AM, Jiri Pirko wrote:
> From: Jiri Pirko <jiri@mellanox.com>
> 
> Extend the existing setup_tc ndo call and allow to offload cls_flower
> rules. Only limited set of dissector keys and actions are supported now.
> Use previously introduced ACL infrastructure to offload cls_flower rules
> to be processed in the HW.
> 
> Signed-off-by: Jiri Pirko <jiri@mellanox.com>
> Reviewed-by: Ido Schimmel <idosch@mellanox.com>
> ---

> +	tcf_exts_to_list(exts, &actions);
> +	list_for_each_entry(a, &actions, list) {
> +		if (is_tcf_gact_shot(a)) {
> +			err = mlxsw_sp_acl_rulei_act_drop(rulei);
> +			if (err)
> +				return err;
> +		} else if (is_tcf_mirred_egress_redirect(a)) {
> +			int ifindex = tcf_mirred_ifindex(a);
> +			struct net_device *out_dev;
> +
> +			out_dev = __dev_get_by_index(dev_net(dev), ifindex);
> +			if (out_dev == dev)
> +				out_dev = NULL;

You are not checking here that out_dev has the same netdev_ops pointer
(unlike the matchall case), is that expected?
-- 
Florian

  reply	other threads:[~2017-02-02 21:37 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-02-02 15:12 [patch net-next 00/19] mlxsw: Introduce TC Flower offload using TCAM Jiri Pirko
2017-02-02 15:12 ` [patch net-next 01/19] mlxsw: item: Add 8bit item helpers Jiri Pirko
2017-02-02 15:12 ` [patch net-next 02/19] mlxsw: item: Add helpers for getting pointer into payload for char buffer item Jiri Pirko
2017-02-02 15:12 ` [patch net-next 03/19] mlxsw: reg: Add Policy-Engine ACL Register Jiri Pirko
2017-02-02 15:12 ` [patch net-next 04/19] mlxsw: reg: Add Policy-Engine ACL Group Table register Jiri Pirko
2017-02-02 15:12 ` [patch net-next 05/19] mlxsw: reg: Add Policy-Engine TCAM Allocation Register Jiri Pirko
2017-02-02 15:12 ` [patch net-next 06/19] mlxsw: reg: Add Policy-Engine TCAM Entry Register Version 2 Jiri Pirko
2017-02-02 15:12 ` [patch net-next 07/19] mlxsw: reg: Add Policy-Engine Port Binding Table Jiri Pirko
2017-02-02 15:12 ` [patch net-next 08/19] mlxsw: reg: Add Policy-Engine Rules Copy Register Jiri Pirko
2017-02-02 15:12 ` [patch net-next 09/19] mlxsw: reg: Add Policy-Engine Policy Based Switching Register Jiri Pirko
2017-02-02 15:12 ` [patch net-next 10/19] mlxsw: reg: Add Policy-Engine Extended Flexible Action Register Jiri Pirko
2017-02-02 15:12 ` [patch net-next 11/19] mlxsw: core: Introduce flexible keys support Jiri Pirko
2017-02-02 15:12 ` [patch net-next 12/19] mlxsw: core: Introduce flexible actions support Jiri Pirko
2017-02-02 15:12 ` [patch net-next 13/19] mlxsw: spectrum: Introduce basic set of flexible key blocks Jiri Pirko
2017-02-02 15:12 ` [patch net-next 14/19] mlxsw: resources: Add ACL related resources Jiri Pirko
2017-02-02 15:12 ` [patch net-next 15/19] list: introduce list_for_each_entry_from_reverse helper Jiri Pirko
2017-02-02 15:12 ` [patch net-next 16/19] lib: Introduce priority array area manager Jiri Pirko
2017-02-02 21:58   ` Tom Herbert
2017-02-02 22:28     ` Eric Dumazet
2017-02-03  7:08     ` Jiri Pirko
2017-02-02 22:51   ` Joe Perches
2017-02-03  7:01     ` Jiri Pirko
2017-02-02 15:12 ` [patch net-next 17/19] mlxsw: spectrum: Introduce ACL core with simple TCAM implementation Jiri Pirko
2017-02-02 22:34   ` David Miller
2017-02-03  6:53     ` Jiri Pirko
2017-02-02 15:12 ` [patch net-next 18/19] sched: cls_flower: expose priority to offloading netdevice Jiri Pirko
2017-02-02 15:12 ` [patch net-next 19/19] mlxsw: spectrum: Implement TC flower offload Jiri Pirko
2017-02-02 21:37   ` Florian Fainelli [this message]
2017-02-03  7:38     ` Jiri Pirko
2017-02-02 21:40 ` [patch net-next 00/19] mlxsw: Introduce TC Flower offload using TCAM Florian Fainelli
2017-02-03  6:58   ` Jiri Pirko
2017-02-03 17:57     ` Florian Fainelli
2017-02-03 18:10       ` Jiri Pirko

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=2bf7a90d-6ec4-8265-bb29-7797e262e570@gmail.com \
    --to=f.fainelli@gmail.com \
    --cc=davem@davemloft.net \
    --cc=eladr@mellanox.com \
    --cc=idosch@mellanox.com \
    --cc=ivecera@redhat.com \
    --cc=jbenc@redhat.com \
    --cc=jhs@mojatatu.com \
    --cc=jiri@resnulli.us \
    --cc=mlxsw@mellanox.com \
    --cc=netdev@vger.kernel.org \
    --cc=ogerlitz@mellanox.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).