]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
rxrpc: Use the core ICMP/ICMP6 parsers
authorDavid Howells <dhowells@redhat.com>
Wed, 12 Oct 2022 08:51:12 +0000 (09:51 +0100)
committerDavid Howells <dhowells@redhat.com>
Tue, 8 Nov 2022 16:42:28 +0000 (16:42 +0000)
commitb6c66c4324e7dd66a06a6a034204ae7d4e95c28c
treed3c0cfd49b626a1663b2b35c3f78bae43ef1047d
parent42fb06b391ace2aec5cdb1ebb8ff668f0a34332f
rxrpc: Use the core ICMP/ICMP6 parsers

Make rxrpc_encap_rcv_err() pass the ICMP/ICMP6 skbuff to ip_icmp_error() or
ipv6_icmp_error() as appropriate to do the parsing rather than trying to do
it in rxrpc.

This pushes an error report onto the UDP socket's error queue and calls
->sk_error_report() from which point rxrpc can pick it up.

It would be preferable to steal the packet directly from ip*_icmp_error()
rather than letting it get queued, but this is probably good enough.

Also note that __udp4_lib_err() calls sk_error_report() twice in some
cases.

Signed-off-by: David Howells <dhowells@redhat.com>
cc: Marc Dionne <marc.dionne@auristor.com>
cc: linux-afs@lists.infradead.org
net/rxrpc/ar-internal.h
net/rxrpc/local_object.c
net/rxrpc/peer_event.c