diff options
| author | Jakub Kicinski <kuba@kernel.org> | 2022-11-04 19:54:29 -0700 |
|---|---|---|
| committer | Jakub Kicinski <kuba@kernel.org> | 2022-11-04 19:54:29 -0700 |
| commit | bcc8f44acac1f5c0cc80abe5658857903a6bb68b (patch) | |
| tree | 1ce633fe7b1d3133c47eb6f73275f316700e2fc3 /drivers/net/ethernet/sfc/tc.h | |
| parent | 8e0aa1ff44ca30b0b9df95dfa72003522d9a088d (diff) | |
| parent | 5d1d24da00dba75f94f1640717b3fd2a243e4b5f (diff) | |
Merge branch 'sfc-add-basic-flower-matches-to-offload'
Edward Cree says:
====================
sfc: add basic flower matches to offload
Support offloading TC flower rules with matches on L2-L4 fields.
====================
Link: https://lore.kernel.org/r/cover.1667412458.git.ecree.xilinx@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/ethernet/sfc/tc.h')
| -rw-r--r-- | drivers/net/ethernet/sfc/tc.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/net/ethernet/sfc/tc.h b/drivers/net/ethernet/sfc/tc.h index 4373c3243e3c..4240c375a8e6 100644 --- a/drivers/net/ethernet/sfc/tc.h +++ b/drivers/net/ethernet/sfc/tc.h @@ -15,6 +15,8 @@ #include <linux/rhashtable.h> #include "net_driver.h" +#define IS_ALL_ONES(v) (!(typeof (v))~(v)) + struct efx_tc_action_set { u16 deliver:1; u32 dest_mport; @@ -26,6 +28,20 @@ struct efx_tc_match_fields { /* L1 */ u32 ingress_port; u8 recirc_id; + /* L2 (inner when encap) */ + __be16 eth_proto; + __be16 vlan_tci[2], vlan_proto[2]; + u8 eth_saddr[ETH_ALEN], eth_daddr[ETH_ALEN]; + /* L3 (when IP) */ + u8 ip_proto, ip_tos, ip_ttl; + __be32 src_ip, dst_ip; +#ifdef CONFIG_IPV6 + struct in6_addr src_ip6, dst_ip6; +#endif + bool ip_frag, ip_firstfrag; + /* L4 */ + __be16 l4_sport, l4_dport; /* Ports (UDP, TCP) */ + __be16 tcp_flags; }; struct efx_tc_match { |
