]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net: change sk_filter_trim_cap() to return a drop_reason by value
authorEric Dumazet <edumazet@google.com>
Thu, 9 Apr 2026 14:56:24 +0000 (14:56 +0000)
committerJakub Kicinski <kuba@kernel.org>
Sun, 12 Apr 2026 21:30:25 +0000 (14:30 -0700)
commitfb37aea2a00e67ef5264ea39371d350a1d19b24f
treeb32c696c4b12e594ca801c925f0382abc5cc4242
parent97449a5f1a586d2befde5297b0fcb0bfdade774e
net: change sk_filter_trim_cap() to return a drop_reason by value

Current return value can be replaced with the drop_reason,
reducing kernel bloat:

$ scripts/bloat-o-meter -t vmlinux.old vmlinux.new
add/remove: 0/2 grow/shrink: 1/11 up/down: 32/-603 (-571)
Function                                     old     new   delta
tcp_v6_rcv                                  3135    3167     +32
unix_dgram_sendmsg                          1731    1726      -5
netlink_unicast                              957     945     -12
netlink_dump                                1372    1359     -13
sk_filter_trim_cap                           882     858     -24
tcp_v4_rcv                                  3143    3111     -32
__pfx_tcp_filter                              32       -     -32
netlink_broadcast_filtered                  1633    1595     -38
sock_queue_rcv_skb_reason                    126      76     -50
tun_net_xmit                                1127    1074     -53
__sk_receive_skb                             690     632     -58
udpv6_queue_rcv_one_skb                      935     869     -66
udp_queue_rcv_one_skb                        919     853     -66
tcp_filter                                   154       -    -154
Total: Before=29722783, After=29722212, chg -0.00%

Signed-off-by: Eric Dumazet <edumazet@google.com>
Link: https://patch.msgid.link/20260409145625.2306224-6-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
include/linux/filter.h
include/net/tcp.h
net/core/filter.c
net/core/sock.c
net/ipv4/udp.c
net/ipv6/udp.c
net/rose/rose_in.c