From: John Fastabend <john.fastabend@gmail•com>
To: Sridhar Samudrala <sridhar.samudrala@intel•com>,
john.r.fastabend@intel•com, netdev@vger•kernel.org
Subject: Re: [PATCH v2 net-next 2/2] net: cls_u32: Add support for skip-sw flag to tc u32 classifier.
Date: Fri, 13 May 2016 11:15:36 -0700 [thread overview]
Message-ID: <573619C8.2040905@gmail.com> (raw)
In-Reply-To: <1463098103-2434-3-git-send-email-sridhar.samudrala@intel.com>
On 16-05-12 05:08 PM, Sridhar Samudrala wrote:
> On devices that support TC U32 offloads, this flag enables a filter to be
> added only to HW. 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>
> ---
Looks good to me thanks for doing this.
Acked-by: John Fastabend <john.r.fastabend@intel•com>
next prev parent reply other threads:[~2016-05-13 18:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-05-13 0:08 [PATCH v2 net-next 0/2] Enable SW only or HW only offloads with u32 classifier Sridhar Samudrala
2016-05-13 0:08 ` [PATCH v2 net-next 1/2] net: sched: Move TCA_CLS_FLAGS_SKIP_HW to uapi header file Sridhar Samudrala
2016-05-13 17:40 ` John Fastabend
2016-05-13 0:08 ` [PATCH v2 net-next 2/2] net: cls_u32: Add support for skip-sw flag to tc u32 classifier Sridhar Samudrala
2016-05-13 18:15 ` John Fastabend [this message]
2016-05-16 17:31 ` [PATCH v2 net-next 0/2] Enable SW only or HW only offloads with " David Miller
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=573619C8.2040905@gmail.com \
--to=john.fastabend@gmail$(echo .)com \
--cc=john.r.fastabend@intel$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
--cc=sridhar.samudrala@intel$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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