Netfilter-Devel Archive on lore.kernel.org
 help / color / Atom feed
From: wenxu <wenxu@ucloud.cn>
To: pablo@netfilter.org, fw@strlen.de
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH nf-next v3 0/9] netfilter: nf_tables_offload: support more expr and obj offload
Date: Tue, 13 Aug 2019 18:58:08 +0800
Message-ID: <e43baf4a-0137-16ca-91cb-ae622b03211c@ucloud.cn> (raw)
In-Reply-To: <1564668086-16260-1-git-send-email-wenxu@ucloud.cn>

Hi pablo,

How about also for this series?


On 8/1/2019 10:01 PM, wenxu@ucloud.cn wrote:
> From: wenxu <wenxu@ucloud.cn>
>
> This series patch support more expr and obj offload: 
> fw_nedev, set payload, tunnel encap/decap action,
> tunnel meta match, objref offload
>
> The follwing is the test sample:
>
> # nft add table netdev firewall
> # nft add tunnel netdev firewall encap tunid 1000 tundst 0xf198a8ac tunsrc 0x4b98a8ac tunrelease 0
> # nft add tunnel netdev firewall decap tunid 0 tundst 0 tunsrc 0  tunrelease 1
> # nft add chain netdev firewall aclout { type filter hook ingress device mlx_pf0vf0 priority - 300 \; }
> # nft --debug=netlink add rule netdev firewall aclout ip daddr 10.0.1.7  @ll,0,48 set 0x00002e9ca06e2596 @ll,48,48 set 0xfaffffffffff tunnel name encap fwd to gretap
>   [ meta load protocol => reg 1 ]
>   [ cmp eq reg 1 0x00000008 ]
>   [ payload load 4b @ network header + 16 => reg 1 ]
>   [ cmp eq reg 1 0x0701000a ]
>   [ immediate reg 1 0x6ea09c2e 0x00009625 ]
>   [ payload write reg 1 => 6b @ link header + 0 csum_type 0 csum_off 0 csum_flags 0x0 ]
>   [ immediate reg 1 0xfffffffa 0x0000ffff ]
>   [ payload write reg 1 => 6b @ link header + 6 csum_type 0 csum_off 0 csum_flags 0x0 ]
>   [ objref type 6 name encap ]
>   [ immediate reg 1 0x00000019 ]
>   [ fwd sreg_dev 1 ]
>
>
> # nft add chain netdev firewall aclin { type filter hook ingress device gretap priority - 300 \; }
> # nft --debug=netlink add rule netdev firewall aclin ip daddr 10.0.0.7 tunnel tunid 1000 tunnel tundst 172.168.152.75 tunnel tunsrc 172.168.152.241 tunnel name decap @ll,0,48 set 0x0000525400001275 @ll,48,48 set 0xfaffffffffff fwd to mlx_pf0vf0
>   [ meta load protocol => reg 1 ]
>   [ cmp eq reg 1 0x00000008 ]
>   [ payload load 4b @ network header + 16 => reg 1 ]
>   [ cmp eq reg 1 0x0700000a ]
>   [ tunnel load id => reg 1 ]
>   [ cmp eq reg 1 0x000003e8 ]
>   [ tunnel load tun_dst => reg 1 ]
>   [ cmp eq reg 1 0xaca8984b ]
>   [ tunnel load tun_src => reg 1 ]
>   [ cmp eq reg 1 0xaca898f1 ]
>   [ objref type 6 name decap ]
>   [ immediate reg 1 0x00005452 0x00007512 ]
>   [ payload write reg 1 => 6b @ link header + 0 csum_type 0 csum_off 0 csum_flags 0x0 ]
>   [ immediate reg 1 0xfffffffa 0x0000ffff ]
>   [ payload write reg 1 => 6b @ link header + 6 csum_type 0 csum_off 0 csum_flags 0x0 ]
>   [ immediate reg 1 0x0000000f ]
>   [ fwd sreg_dev 1 ]
>
> wenxu (9):
>   netfilter: nf_flow_offload: add net in offload_ctx
>   netfilter: nf_tables_offload: add offload_actions callback
>   netfilter: nft_fwd_netdev: add fw_netdev action support
>   netfilter: nft_payload: add nft_set_payload offload support
>   netfilter: nft_tunnel: support NFT_TUNNEL_SRC/DST_IP match
>   netfilter: nft_tunnel: support tunnel meta match offload
>   netfilter: nft_tunnel: add NFTA_TUNNEL_KEY_RELEASE action
>   netfilter: nft_objref: add nft_objref_type offload
>   netfilter: nft_tunnel: support nft_tunnel_obj offload
>
>  include/net/netfilter/nf_tables.h         |  10 ++-
>  include/net/netfilter/nf_tables_offload.h |   7 +-
>  include/uapi/linux/netfilter/nf_tables.h  |   3 +
>  net/netfilter/nf_tables_api.c             |   2 +-
>  net/netfilter/nf_tables_offload.c         |   7 +-
>  net/netfilter/nft_fwd_netdev.c            |  27 +++++++
>  net/netfilter/nft_immediate.c             |   2 +-
>  net/netfilter/nft_objref.c                |  15 ++++
>  net/netfilter/nft_payload.c               |  56 ++++++++++++++
>  net/netfilter/nft_tunnel.c                | 123 ++++++++++++++++++++++++++----
>  10 files changed, 230 insertions(+), 22 deletions(-)
>

      parent reply index

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-01 14:01 wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 1/9] netfilter: nf_flow_offload: add net in offload_ctx wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 2/9] netfilter: nf_tables_offload: add offload_actions callback wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 3/9] netfilter: nft_fwd_netdev: add fw_netdev action support wenxu
2019-08-07 12:15   ` kbuild test robot
2019-08-08  6:06     ` wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 4/9] netfilter: nft_payload: add nft_set_payload offload support wenxu
2019-08-07 12:18   ` kbuild test robot
2019-08-08  6:07     ` wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 5/9] netfilter: nft_tunnel: support NFT_TUNNEL_SRC/DST_IP match wenxu
2019-08-13 18:19   ` Pablo Neira Ayuso
2019-08-14  7:54     ` wenxu
2019-08-14  8:00       ` Pablo Neira Ayuso
2019-08-14  8:19         ` Pablo Neira Ayuso
2019-08-14  8:28           ` wenxu
2019-08-14  9:17             ` Pablo Neira Ayuso
2019-08-14  8:22         ` wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 6/9] netfilter: nft_tunnel: support tunnel meta match offload wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 7/9] netfilter: nft_tunnel: add NFTA_TUNNEL_KEY_RELEASE action wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 8/9] netfilter: nft_objref: add nft_objref_type offload wenxu
2019-08-01 14:01 ` [PATCH nf-next v3 9/9] netfilter: nft_tunnel: support nft_tunnel_obj offload wenxu
2019-08-13 10:58 ` wenxu [this message]

Reply instructions:

You may reply publically 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=e43baf4a-0137-16ca-91cb-ae622b03211c@ucloud.cn \
    --to=wenxu@ucloud.cn \
    --cc=fw@strlen.de \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=pablo@netfilter.org \
    /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

Netfilter-Devel Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/netfilter-devel/0 netfilter-devel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 netfilter-devel netfilter-devel/ https://lore.kernel.org/netfilter-devel \
		netfilter-devel@vger.kernel.org netfilter-devel@archiver.kernel.org
	public-inbox-index netfilter-devel


Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.netfilter-devel


AGPL code for this site: git clone https://public-inbox.org/ public-inbox