All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemming@brocade.com>
To: Sridhar Samudrala <sridhar.samudrala@intel.com>
Cc: <john.r.fastabend@intel.com>, <jakub.kicinski@netronome.com>,
	<netdev@vger.kernel.org>
Subject: Re: [PATCH v2 iproute2] tc: f_u32: Add support for skip_hw and skip_sw flags
Date: Wed, 8 Jun 2016 16:46:59 -0700	[thread overview]
Message-ID: <20160608164659.695ce9c5@xeon-e3> (raw)
In-Reply-To: <1465427761-7038-1-git-send-email-sridhar.samudrala@intel.com>

On Wed, 8 Jun 2016 16:16:01 -0700
Sridhar Samudrala <sridhar.samudrala@intel.com> wrote:

> On devices that support TC U32 offloads, these flags enable a filter to be
> added only to HW or only to SW. skip_sw and skip_hw are mutually exclusive
> flags. By default without any flags, the filter is added to both HW and SW,
> but no error checks are done in case of failure to add to HW.
> With skip-sw, failure to add to HW is treated as an error.
> 
> Here is a sample script that adds 2 filters, one with skip_sw and the other
> with skip_hw flag.
> 
>    # add ingress qdisc
>    tc qdisc add dev p4p1 ingress
> 
>    # enable hw tc offload.
>    ethtool -K p4p1 hw-tc-offload on
> 
>    # add u32 filter with skip-sw flag.
>    tc filter add dev p4p1 parent ffff: protocol ip prio 99 \
>       handle 800:0:1 u32 ht 800: flowid 800:1 \
>       skip-sw \
>       match ip src 192.168.1.0/24 \
>       action drop
> 
>    # add u32 filter with skip-hw flag.
>    tc filter add dev p4p1 parent ffff: protocol ip prio 99 \
>       handle 800:0:2 u32 ht 800: flowid 800:2 \
>       skip-hw \
>       match ip src 192.168.2.0/24 \
>       action drop
> 
> Signed-off-by: Sridhar Samudrala <sridhar.samudrala@intel.com>

Applied, then updated, already needed to cleanup some style issues in f_u32 anyway.

      reply	other threads:[~2016-06-08 23:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-08 23:16 [PATCH v2 iproute2] tc: f_u32: Add support for skip_hw and skip_sw flags Sridhar Samudrala
2016-06-08 23:46 ` Stephen Hemminger [this message]

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=20160608164659.695ce9c5@xeon-e3 \
    --to=shemming@brocade.com \
    --cc=jakub.kicinski@netronome.com \
    --cc=john.r.fastabend@intel.com \
    --cc=netdev@vger.kernel.org \
    --cc=sridhar.samudrala@intel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.