From: Jiri Benc <jbenc@redhat.com>
To: Amir Vadai <amir@vadai.me>
Cc: "David S. Miller" <davem@davemloft.net>,
netdev@vger.kernel.org, Jiri Pirko <jiri@mellanox.com>,
Or Gerlitz <ogerlitz@mellanox.com>,
Hadar Har-Zion <hadarh@mellanox.com>
Subject: Re: [PATCH net-next V2 0/3] net/sched: act_pedit: Use offset relative to conventional network headers
Date: Thu, 5 Jan 2017 12:54:14 +0100 [thread overview]
Message-ID: <20170105125414.5640b1b8@griffin> (raw)
In-Reply-To: <20170105095454.32644-1-amir@vadai.me>
On Thu, 5 Jan 2017 11:54:51 +0200, Amir Vadai wrote:
> You asked me [1] why did I use specific header names instead of layers (L2, L3...),
> and I explained that it is on purpose, this extra information is planned to be used
> by hardware drivers to offload the action.
>
> Some FW/HW parser APIs are such that they need to get the specific header type (e.g
> IPV4 or IPV6, TCP or UDP) and not only the networking level (e.g network or transport).
Don't we need better API specification (and enforcement) then, though?
See below.
> Usage example:
> $ tc filter add dev enp0s9 protocol ip parent ffff: \
> flower \
> ip_proto tcp \
> dst_port 80 \
> action \
> pedit munge ip ttl add 0xff \
> pedit munge tcp dport set 8080 \
> pipe action mirred egress redirect dev veth0
What happens when one does:
tc filter add ... flower ip_proto udp action pedit munge tcp ...
?
Jiri
next prev parent reply other threads:[~2017-01-05 11:54 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-01-05 9:54 [PATCH net-next V2 0/3] net/sched: act_pedit: Use offset relative to conventional network headers Amir Vadai
2017-01-05 9:54 ` [PATCH net-next V2 1/3] net/skbuff: Introduce skb_mac_offset() Amir Vadai
2017-01-05 9:54 ` [PATCH net-next V2 2/3] net/act_pedit: Support using offset relative to the conventional network headers Amir Vadai
2017-01-05 9:54 ` [PATCH net-next V2 3/3] net/act_pedit: Introduce 'add' operation Amir Vadai
2017-01-05 11:54 ` Jiri Benc [this message]
2017-01-05 12:34 ` [PATCH net-next V2 0/3] net/sched: act_pedit: Use offset relative to conventional network headers Amir Vadai
2017-01-05 12:44 ` Jiri Benc
2017-01-07 1:51 ` David Miller
2017-01-08 8:46 ` Amir Vadai
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=20170105125414.5640b1b8@griffin \
--to=jbenc@redhat.com \
--cc=amir@vadai.me \
--cc=davem@davemloft.net \
--cc=hadarh@mellanox.com \
--cc=jiri@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).