OrangePi_CM5/net/core
Andrea Mayer 2d4efc9a0e seg6: bpf: fix skb checksum in bpf_push_seg6_encap()
[ Upstream commit 4889fbd98deaf243c3baadc54e296d71c6af1eb0 ]

Both helper functions bpf_lwt_seg6_action() and bpf_lwt_push_encap() use
the bpf_push_seg6_encap() to encapsulate the packet in an IPv6 with Segment
Routing Header (SRH) or insert an SRH between the IPv6 header and the
payload.
To achieve this result, such helper functions rely on bpf_push_seg6_encap()
which, in turn, leverages seg6_do_srh_{encap,inline}() to perform the
required operation (i.e. encap/inline).

This patch removes the initialization of the IPv6 header payload length
from bpf_push_seg6_encap(), as it is now handled properly by
seg6_do_srh_{encap,inline}() to prevent corruption of the skb checksum.

Fixes: fe94cc290f ("bpf: Add IPv6 Segment Routing helpers")
Signed-off-by: Andrea Mayer <andrea.mayer@uniroma2.it>
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-07-21 21:20:11 +02:00
..
Makefile
…
bpf_sk_storage.c
…
datagram.c
…
datagram.h
…
dev.c net: remove two BUG() from skb_checksum_help() 2022-06-09 10:20:54 +02:00
dev_addr_lists.c
…
dev_ioctl.c
…
devlink.c devlink: Remove misleading internal_flags from health reporter dump 2022-01-27 10:54:34 +01:00
drop_monitor.c drop_monitor: fix data-race in dropmon_net_event / trace_napi_poll_hit 2022-02-23 12:01:02 +01:00
dst.c
…
dst_cache.c wireguard: device: reset peer src endpoint when netns exits 2021-12-08 09:03:22 +01:00
failover.c
…
fib_notifier.c
…
fib_rules.c ipv6: fix memory leak in fib6_rule_suppress 2021-12-08 09:03:21 +01:00
filter.c seg6: bpf: fix skb checksum in bpf_push_seg6_encap() 2022-07-21 21:20:11 +02:00
flow_dissector.c net/sched: flower: fix parsing of ethertype following VLAN header 2022-04-20 09:23:11 +02:00
flow_offload.c netfilter: nf_tables: bail out early if hardware offload is not supported 2022-06-14 18:32:40 +02:00
gen_estimator.c
…
gen_stats.c
…
gro_cells.c
…
hwbm.c
…
link_watch.c net: linkwatch: fix failure to restore device state across suspend/resume 2021-08-18 08:59:13 +02:00
lwt_bpf.c bpf, lwt: Fix crash when using bpf_skb_set_tunnel_key() from bpf_xmit lwt hook 2022-05-09 09:05:02 +02:00
lwtunnel.c lwtunnel: Validate RTA_ENCAP_TYPE attribute length 2022-01-11 15:25:00 +01:00
neighbour.c net, neigh: clear whole pneigh_entry at alloc time 2021-12-14 11:32:43 +01:00
net-procfs.c net-procfs: show net devices bound packet types 2022-02-01 17:25:44 +01:00
net-sysfs.c net-sysfs: add check for netdevice being present to speed_show 2022-03-16 14:16:00 +01:00
net-sysfs.h
…
net-traces.c
…
net_namespace.c netns: add schedule point in ops_exit_list() 2022-01-27 10:54:33 +01:00
netclassid_cgroup.c
…
netevent.c
…
netpoll.c
…
netprio_cgroup.c
…
page_pool.c
…
pktgen.c
…
ptp_classifier.c
…
request_sock.c
…
rtnetlink.c net: limit altnames to 64k total 2022-04-13 21:01:00 +02:00
scm.c
…
secure_seq.c secure_seq: use the 64 bits of the siphash for port offset calculation 2022-05-30 09:33:23 +02:00
skbuff.c net: fix up skbs delta_truesize in UDP GRO frag_list 2022-03-08 19:09:32 +01:00
skmsg.c bpf, sockmap: Fix memleak in tcp_bpf_sendmsg while sk msg is full 2022-04-08 14:40:21 +02:00
sock.c sock: fix /proc/net/sockstat underflow in sk_clone_lock() 2021-11-26 10:39:14 +01:00
sock_diag.c
…
sock_map.c bpf: Fix integer overflow in argument calculation for bpf_map_area_alloc 2021-12-17 10:14:41 +01:00
sock_reuseport.c
…
stream.c net: stream: don't purge sk_error_queue in sk_stream_kill_queues() 2021-11-18 14:04:08 +01:00
sysctl_net_core.c bpf: Prevent increasing bpf_jit_limit above max 2021-11-18 14:03:42 +01:00
timestamping.c
…
tso.c
…
utils.c
…
xdp.c
…