linux-stable/include/net
Xin Long 0a7c9d1f55 net: sched: do not offload flows with a helper in act_ct
[ Upstream commit 7cd5af0e93 ]

There is no hardware supporting ct helper offload. However, prior to this
patch, a flower filter with a helper in the ct action can be successfully
set into the HW, for example (eth1 is a bnxt NIC):

  # tc qdisc add dev eth1 ingress_block 22 ingress
  # tc filter add block 22 proto ip flower skip_sw ip_proto tcp \
    dst_port 21 ct_state -trk action ct helper ipv4-tcp-ftp
  # tc filter show dev eth1 ingress

    filter block 22 protocol ip pref 49152 flower chain 0 handle 0x1
      eth_type ipv4
      ip_proto tcp
      dst_port 21
      ct_state -trk
      skip_sw
      in_hw in_hw_count 1   <----
        action order 1: ct zone 0 helper ipv4-tcp-ftp pipe
         index 2 ref 1 bind 1
        used_hw_stats delayed

This might cause the flower filter not to work as expected in the HW.

This patch avoids this problem by simply returning -EOPNOTSUPP in
tcf_ct_offload_act_setup() to not allow to offload flows with a helper
in act_ct.

Fixes: a21b06e731 ("net: sched: add helper support in act_ct")
Signed-off-by: Xin Long <lucien.xin@gmail.com>
Reviewed-by: Jamal Hadi Salim <jhs@mojatatu.com>
Link: https://lore.kernel.org/r/f8685ec7702c4a448a1371a8b34b43217b583b9d.1699898008.git.lucien.xin@gmail.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-11-28 17:19:54 +00:00
..
9p
bluetooth Bluetooth: Make handle of hci_conn be unique 2023-11-20 11:59:03 +01:00
caif net: caif: Remove unused declaration cfsrvl_ctrlcmd() 2023-08-10 18:24:48 -07:00
iucv
mana net: mana: Fix oversized sge0 for GSO packets 2023-10-05 11:45:06 +02:00
netfilter netfilter: nf_tables: fix pointer math issue in nft_byteorder_eval() 2023-11-28 17:19:52 +00:00
netns xfrm: fix a data-race in xfrm_gen_index() 2023-09-13 09:20:28 +02:00
nfc
page_pool page_pool: fix documentation typos 2023-10-04 14:22:27 -07:00
phonet
sctp sctp: Remove unused declaration sctp_backlog_migrate() 2023-08-10 19:31:52 -07:00
tc_act net: sched: do not offload flows with a helper in act_ct 2023-11-28 17:19:54 +00:00
6lowpan.h
act_api.h
addrconf.h
af_ieee802154.h
af_rxrpc.h
af_unix.h
af_vsock.h af_vsock: Remove unused declaration vsock_release_pending()/vsock_init_tap() 2023-08-04 15:34:03 -07:00
ah.h
amt.h
arp.h
atmclip.h
ax25.h
ax88796.h
bareudp.h
bond_3ad.h bonding: 3ad: Remove unused declaration bond_3ad_update_lacp_active() 2023-07-28 18:06:30 -07:00
bond_alb.h
bond_options.h
bonding.h bonding: fix macvlan over alb bond support 2023-08-24 10:07:13 +02:00
bpf_sk_storage.h
busy_poll.h net: invert the netdevice.h vs xdp.h dependency 2023-08-03 08:38:07 -07:00
calipso.h
cfg80211-wext.h
cfg80211.h wifi: cfg80211: fix kernel-doc for wiphy_delayed_work_flush() 2023-11-20 11:58:55 +01:00
cfg802154.h
checksum.h
cipso_ipv4.h
cls_cgroup.h
codel.h
codel_impl.h
codel_qdisc.h
compat.h
datalink.h net: datalink: Remove unused declarations 2023-07-27 17:17:32 -07:00
dcbevent.h
dcbnl.h
devlink.h devlink: Expose port function commands to control IPsec packet offloads 2023-08-27 17:08:45 -07:00
dropreason-core.h net: add skb_queue_purge_reason and __skb_queue_purge_reason 2023-08-19 15:30:15 +01:00
dropreason.h net: openvswitch: add last-action drop reason 2023-08-14 08:01:06 +01:00
dsa.h
dsa_stubs.h
dsfield.h
dst.h
dst_cache.h
dst_metadata.h
dst_ops.h net: remove unnecessary input parameter 'how' in ifdown function 2023-08-22 13:19:02 +02:00
erspan.h
esp.h
espintcp.h
ethoc.h
failover.h
fib_notifier.h
fib_rules.h
firewire.h
flow.h inet: shrink struct flowi_common 2023-11-20 11:59:34 +01:00
flow_dissector.h net: flow_dissector: Add IPSEC dissector 2023-08-02 10:09:31 +01:00
flow_offload.h tc: flower: Enable offload support IPSEC SPI field. 2023-08-02 10:09:32 +01:00
fou.h
fq.h net: fq: Remove unused typedef fq_flow_get_default_t 2023-08-08 15:58:23 -07:00
fq_impl.h
garp.h
gen_stats.h
genetlink.h genetlink: add genlmsg_iput() API 2023-08-15 15:01:03 -07:00
geneve.h
gre.h
gro.h net: gro: fix misuse of CB in udp socket lookup 2023-07-29 17:10:27 +01:00
gro_cells.h
gso.h
gtp.h
gue.h
handshake.h net/handshake: Add helpers for parsing incoming TLS Alerts 2023-07-28 14:07:59 -07:00
hwbm.h
icmp.h
ieee80211_radiotap.h wifi: radiotap: fix kernel-doc notation warnings 2023-08-22 21:40:40 +02:00
ieee802154_netdev.h
if_inet6.h
ife.h
inet6_connection_sock.h
inet6_hashtables.h net: Fix slab-out-of-bounds in inet[6]_steal_sock 2023-08-15 13:57:51 -07:00
inet_common.h net: factor out __inet_listen_sk() helper 2023-08-14 07:06:13 +01:00
inet_connection_sock.h inet: move inet->is_icsk to inet->inet_flags 2023-08-16 11:09:17 +01:00
inet_dscp.h
inet_ecn.h
inet_frag.h
inet_hashtables.h net: Fix slab-out-of-bounds in inet[6]_steal_sock 2023-08-15 13:57:51 -07:00
inet_sock.h Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2023-08-24 10:51:39 -07:00
inet_timewait_sock.h
inetpeer.h
ioam6.h
ip.h ipv4: ignore dst hint for multipath routes 2023-09-01 08:11:51 +01:00
ip6_checksum.h
ip6_fib.h net: fib: avoid warn splat in flow dissector 2023-08-31 12:33:03 +02:00
ip6_route.h IPv6: add extack info for IPv6 address add/delete 2023-07-28 11:01:56 +01:00
ip6_tunnel.h
ip_fib.h ipv4/fib: send notify when delete source address routes 2023-10-03 09:00:40 +02:00
ip_tunnels.h ip_tunnels: use DEV_STATS_INC() 2023-09-06 06:05:59 +01:00
ip_vs.h
ipcomp.h
ipconfig.h
ipv6.h tcp: Fix bind() regression for v4-mapped-v6 wildcard address. 2023-09-13 07:18:04 +01:00
ipv6_frag.h
ipv6_stubs.h
iw_handler.h wifi: wext: Remove unused declaration dev_get_wireless_info() 2023-08-22 21:40:40 +02:00
kcm.h
l3mdev.h
lag.h
lapb.h
lib80211.h
llc.h
llc_c_ac.h net: llc: Remove unused function declarations 2023-08-04 15:33:17 -07:00
llc_c_ev.h net: llc: Remove unused function declarations 2023-08-04 15:33:17 -07:00
llc_c_st.h
llc_conn.h llc: Check netns in llc_estab_match() and llc_listener_match(). 2023-07-20 10:46:28 +02:00
llc_if.h
llc_pdu.h
llc_s_ac.h
llc_s_ev.h
llc_s_st.h
llc_sap.h
lwtunnel.h lwt: Check LWTUNNEL_XMIT_CONTINUE strictly 2023-08-18 16:05:26 +02:00
mac80211.h wireless-next patches for v6.6 2023-08-25 18:35:09 -07:00
mac802154.h
macsec.h net: macsec: indicate next pn update when offloading 2023-10-10 10:30:30 +02:00
mctp.h
mctpdevice.h
mip6.h
mld.h
mpls.h
mpls_iptunnel.h
mptcp.h mptcp: add struct mptcp_sched_ops 2023-08-22 17:31:18 -07:00
mrp.h
ncsi.h
ndisc.h ndisc: Remove unused ndisc_ifinfo_sysctl_strategy() declaration 2023-08-07 08:53:55 +01:00
neighbour.h neighbour: fix data-races around n->output 2023-10-01 17:14:37 +01:00
net_debug.h
net_failover.h
net_namespace.h sysctl-6.6-rc1 2023-08-29 17:39:15 -07:00
net_ratelimit.h
net_trackers.h
netdev_queues.h
netdev_rx_queue.h net: move struct netdev_rx_queue out of netdevice.h 2023-08-03 08:38:07 -07:00
netevent.h
netlabel.h
netlink.h netlink: allow be16 and be32 types in all uint policy checks 2023-07-27 13:45:51 +02:00
netprio_cgroup.h
netrom.h
nexthop.h
nl802154.h
nsh.h
p8022.h net: 802: Remove unused function declarations 2023-08-04 15:33:50 -07:00
pie.h
ping.h
pkt_cls.h net: pkt_cls: Remove unused inline helpers 2023-08-07 08:53:54 +01:00
pkt_sched.h
pptp.h
protocol.h
psample.h
psnap.h
raw.h
rawv6.h
red.h
regulatory.h
request_sock.h
rose.h
route.h inet: move inet->transparent to inet->inet_flags 2023-08-16 11:09:17 +01:00
rpl.h
rsi_91x.h
rtnetlink.h net: validate veth and vxcan peer ifindexes 2023-08-20 11:40:03 +01:00
rtnh.h
sch_generic.h net/sched: wrap open coded Qdics class filter counter 2023-08-01 10:47:24 +02:00
scm.h af_unix: Fix msg_controllen test in scm_pidfd_recv() for MSG_CMSG_COMPAT. 2023-09-04 11:00:17 +01:00
secure_seq.h
seg6.h
seg6_hmac.h
seg6_local.h
selftests.h
slhc_vj.h
smc.h
snmp.h
sock.h net: annotate data-races around sk->sk_dst_pending_confirm 2023-11-28 17:19:38 +00:00
sock_reuseport.h
Space.h net: Space.h: Remove unused function declarations 2023-08-03 18:10:10 -07:00
stp.h
strparser.h
switchdev.h net: switchdev: Remove unused declaration switchdev_port_fwd_mark_set() 2023-08-09 13:12:15 -07:00
tc_wrapper.h
tcp.h tcp: fix cookie_init_timestamp() overflows 2023-11-20 11:59:01 +01:00
tcp_states.h
tcx.h
timewait_sock.h
tipc.h
tls.h tls: move tls_cipher_size_desc to net/tls/tls.h 2023-08-27 17:17:41 -07:00
tls_prot.h net/tls: Add TLS Alert definitions 2023-07-28 14:07:59 -07:00
tls_toe.h
transp_v6.h inet6: Remove unused function declaration udpv6_connect() 2023-08-01 15:06:27 -07:00
tso.h
tun_proto.h
udp.h udp/udplite: Remove unused function declarations udp{,lite}_get_port() 2023-08-07 08:53:55 +01:00
udp_tunnel.h udp: lockless UDP_ENCAP_L2TPINUDP / UDP_GRO 2023-11-20 11:58:56 +01:00
udplite.h udplite: fix various data-races 2023-11-20 11:58:56 +01:00
vsock_addr.h
vxlan.h vxlan: Fix nexthop hash size 2023-08-02 10:58:26 +01:00
wext.h
x25.h
x25device.h
xdp.h net: invert the netdevice.h vs xdp.h dependency 2023-08-03 08:38:07 -07:00
xdp_priv.h
xdp_sock.h
xdp_sock_drv.h
xfrm.h xfrm: don't skip free of empty state in acquire policy 2023-08-01 12:04:43 +02:00
xsk_buff_pool.h