Linux/linux d89e1d1 — fs/crypto keyring.c keysetup.c, fs/ext4 inode.c crypto.c

Merge tag 'fscrypt-for-linus' of git://git.kernel.org/pub/scm/fs/fscrypt/linux

Pull fscrypt fixes from Eric Biggers:

 - Add more checks to prevent encryption on "large block size" ext4
   filesystems (s_blocksize > PAGE_SIZE), which isn't supported yet.
   There was already a mount-time check, but it wasn't enough.

 - Add missing memory barrier to fscrypt_find_mode_key()

 - Add missing zeroization in an error path

* tag 'fscrypt-for-linus' of git://git.kernel.org/pub/scm/fs/fscrypt/linux:
  ext4: reject encrypted inodes when block size > page size
  ext4: refuse encryption when block size > page size
  fscrypt: Fix missing barrier in fscrypt_find_mode_key()
  fscrypt: Explicitly zeroize sw_secret in error path
DeltaFile
+9-0fs/ext4/crypto.c
+7-1fs/crypto/keysetup.c
+6-0fs/ext4/inode.c
+3-1fs/crypto/keyring.c
+25-24 files

Linux/linux 0ff8f40 — fs/ntfs3 index.c xattr.c, include/trace/events ntfs3.h

Merge tag 'ntfs3_for_7.4' of https://github.com/Paragon-Software-Group/linux-ntfs3

Pull ntfs3 updates from Konstantin Komarov:
 "The bulk of this cycle is hardening against corrupted or maliciously
  crafted volumes. Most of these fixes come from fuzzing and KASAN
  reports. The main areas are:

   - $LogFile replay, where several unchecked on-disk sizes could make
     mount write past the MFT record buffer
   - MFT record and index parsing
   - extended attributes, where a bad $EA entry could leak up to 64K of
     kernel heap to userspace through getxattr()

  Reading a damaged compressed file could also return uninitialized page
  cache contents to userspace; that is fixed too.

  A few fixes affect healthy volumes as well: a heap overflow in
  fallocate(INSERT_RANGE) on small files, a use-after-free when a
  WOF-compressed file is opened for writing during a concurrent read, a

    [33 lines not shown]
DeltaFile
+389-0include/trace/events/ntfs3.h
+123-68fs/ntfs3/attrib.c
+43-25fs/ntfs3/dir.c
+28-16fs/ntfs3/xattr.c
+40-4fs/ntfs3/super.c
+35-5fs/ntfs3/index.c
+658-11810 files not shown
+785-14616 files

Linux/linux 5fade97 — kernel/debug debug_core.c gdbstub.c, kernel/debug/kdb kdb_io.c kdb_private.h

Merge tag 'kgdb-7.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/danielt/linux

Pull kgdb updates from Daniel Thompson:
 "Varied updates this cycle.

  Naveen Kumar Chaudhary fixed a memory leak when the environment is
  already full, eliminated to weird historical cruft (CMD_BUFLEN having
  different values in different files) and removed some dead code.

  Fang Xieyan tackled a family of related buffer overflows in the gdb
  remote protocol parsing (great fixes from a defensive coding point of
  view but not security relavent; gdb can already do anything it wants
  to)"

* tag 'kgdb-7.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/danielt/linux:
  kgdb: Fix buffer overflow in the qRcmd packet handler
  kgdb: Fix buffer overflow in the 'M' and 'X' packet handlers
  kgdb: Fix buffer overflow in the 'm' packet handler
  kgdb: remove unreachable return in kgdb_reenter_check()

    [2 lines not shown]
DeltaFile
+47-8kernel/debug/gdbstub.c
+3-4kernel/debug/kdb/kdb_main.c
+2-1kernel/debug/kdb/kdb_private.h
+0-2kernel/debug/debug_core.c
+0-1kernel/debug/kdb/kdb_io.c
+52-165 files

Linux/linux 9c7e3d5 — Documentation/virt/hyperv overview.rst, drivers/hv vmbus_drv.c mshv_vtl_main.c

Merge tag 'hyperv-next-signed-20261028' of git://git.kernel.org/pub/scm/linux/kernel/git/hyperv/linux

Pull hyperv updates from Wei Liu:

 - Update to documents and code comments (Michael Kelley)

 - Harden Vmbus (Kameron Carr)

 - Rework MSHV driver page deposit logic (Mukesh Rathor)

 - Vmbus kexec bug fix (Shradha Gupta)

 - Miscellaneous bug fixes (Daehyeon Ko, Jiale Yao, Sasha Levin)

* tag 'hyperv-next-signed-20261028' of git://git.kernel.org/pub/scm/linux/kernel/git/hyperv/linux:
  Drivers: hv: Remove leftover support for old Hyper-V versions
  mshv: Remove unused *_old memory deposit functions
  mshv: Redesign hypervisor memory deposit logic
  mshv: Rename memory deposit memory functions to _old

    [15 lines not shown]
DeltaFile
+147-113drivers/hv/hv_proc.c
+51-75drivers/hv/ring_buffer.c
+45-13include/linux/hyperv.h
+47-8drivers/hv/mshv_vtl_main.c
+20-10drivers/hv/vmbus_drv.c
+15-13Documentation/virt/hyperv/overview.rst
+325-23210 files not shown
+363-30116 files

Linux/linux 1b8b675 — arch/riscv/boot/dts/sophgo sg2044-cpus.dtsi, arch/riscv/boot/dts/spacemit k1.dtsi

Merge tag 'riscv-for-linus-7.4-mw1' of git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux

Pull RISC-V updates from Paul Walmsley:

 - Add support for crash hotplug

 - Improve user copy performance on cores with fast misaligned accesses

 - Optimize code paths involving pgtable_l{4,5}_enabled() by patching in
   the return values during early boot (since these don't change during
   runtime), or by specifying the return values directly in Kconfig
   files (for purpose-built kernels)

 - Change the PCIe bus reassignment behavior to depend on the
   PCI_REASSIGN_ALL_BUS PCI flag (as ARM64 does)

 - Avoid an unnecessary sstatus CSR read during context switch

 - Make the sbi_ecall() macro variadic, improving code clarity

    [54 lines not shown]
DeltaFile
+221-0tools/testing/selftests/riscv/vector/v_uaccess_stress.c
+64-64arch/riscv/boot/dts/sophgo/sg2044-cpus.dtsi
+113-0arch/riscv/kernel/crash.c
+81-10arch/riscv/kernel/cpufeature.c
+75-6arch/riscv/include/asm/sbi.h
+40-40arch/riscv/boot/dts/spacemit/k1.dtsi
+594-12052 files not shown
+1,171-48658 files

Linux/linux fb7bd3a — drivers/android/binder process.rs, rust bindgen_parameters

Merge tag 'rust-fixes-7.4' of git://git.kernel.org/pub/scm/linux/kernel/git/ojeda/linux

Pull Rust fixes from Miguel Ojeda:
 "Toolchain and infrastructure:

   - Fix 'objtool' warnings for the upcoming Rust 1.101.0 (expected
     2026-12-24) by adding one more 'noreturn' function

  'kernel' crate:

   - Fix KCFI failures on every call from C to Rust IRQ handlers and
     'hrtimer' callbacks by giving the C enum bindings the correct
     'cfi_encoding'. Also prevent the same issue for DMA callbacks
     taking 'dma_data_direction'

   - 'workqueue' module: fix a runtime warning when queueing work on the
     deprecated 'system_wq' by switching to 'system_{percpu,dfl}_wq'"

* tag 'rust-fixes-7.4' of git://git.kernel.org/pub/scm/linux/kernel/git/ojeda/linux:

    [5 lines not shown]
DeltaFile
+27-25rust/kernel/workqueue.rs
+17-11rust/kernel/irq/request.rs
+11-10rust/kernel/dma.rs
+3-3rust/kernel/time/hrtimer.rs
+6-0rust/bindgen_parameters
+2-2drivers/android/binder/process.rs
+66-515 files not shown
+71-5511 files

Linux/linux 4dd16e3 — drivers/net/ethernet/broadcom/genet bcmgenet.c, drivers/net/ethernet/intel/ice ice_ptp.c

Merge tag 'net-7.4-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net

Pull networking fixes from Jakub Kicinski:
 "Current release - new code bugs:

   - mctp: usblib: fix assertion breaking esoteric builds

  Previous releases - regressions:

   - Revert advertising the TCP MSS from the configured MTU

  - netlink: check sk_rcvbuf before charging the dump skb

   - eth:
      - ti: am65-cpts: fix support for PTP_EXTTS_REQUEST2 ioctl
      - mlx4: always create the eth and ib auxiliary devices
      - tg3: invert restart quirk logic to restrict SNP power-down bypass
      - bnxt: recycle agg buffers when Rx head buffer allocation fails


    [38 lines not shown]
DeltaFile
+129-45drivers/net/ethernet/intel/ice/ice_ptp.c
+70-32drivers/net/ethernet/broadcom/genet/bcmgenet.c
+102-0tools/testing/selftests/net/netlink-dumps.c
+94-2drivers/net/ppp/ppp_generic.c
+71-0tools/testing/selftests/tc-testing/tc-tests/filters/matchall.json
+0-67tools/testing/selftests/net/packetdrill/tcp_advmss_pmtu_ipv4.pkt
+466-146136 files not shown
+1,596-684142 files

Linux/linux 46806af — kernel/bpf verifier.c, tools/lib/bpf libbpf.c

Merge tag 'bpf-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf

Pull bpf fixes from Alexei Starovoitov:

 - Remove BPF_F_ARENA_SCALAR flag and .arena.data section in libbpf that
   were added for rust-bpf in this merge window. We found a cleaner
   approach that does it on compiler side instead of kernel/libbpf. No
   released kernel has them (Alexei Starovoitov)

 - Fix bpf_send_signal_task() returning -EPERM when it is called from a
   kernel thread (Aditya Sharma)

 - Various fixes (Alexei Starovoitov):
     - Use emit_rsb_call() to call bpf_unwind_target() in x86 JIT to fix
       objtool warning during the build
     - Fix scalar evolution: clear delta of a widened register, don't
       widen a pointer to a buffer, don't clamp a register whose type
       changed in the loop, and reset the range of a clamped packet
       pointer

    [60 lines not shown]
DeltaFile
+0-1,155tools/testing/selftests/bpf/progs/verifier_arena_scalar.c
+496-8tools/testing/selftests/bpf/progs/verifier_scev.c
+20-413tools/lib/bpf/libbpf.c
+370-0tools/testing/selftests/bpf/progs/iters_testmod.c
+0-216tools/testing/selftests/bpf/prog_tests/data_in_arena.c
+112-93kernel/bpf/verifier.c
+998-1,88555 files not shown
+1,884-2,58061 files

Linux/linux d011f64 — kernel kthread.c

Merge tag 'kthread-fix-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks

Pull kthread fix from Frederic Weisbecker:
 "Fix a bug where dynamic CPU isolation through cpuset isolated
  partitions can move a kthread out of the housekeeping range.

  The fix makes sure the fallback affinity is always a set of online
  housekeeper"

* tag 'kthread-fix-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic/linux-dynticks:
  kthread: Fall back when no preferred housekeeping CPU is online
DeltaFile
+1-1kernel/kthread.c
+1-11 files

Linux/linux cb01c69 — Documentation/translations/pt_BR/admin-guide kernel-parameters.rst sysfs-rules.rst, Documentation/translations/pt_BR/process/debugging userspace_debugging_guide.rst

Merge tag 'docs-7.4-2' of git://git.kernel.org/pub/scm/linux/kernel/git/docs/linux

Pull more documentation updates from Jonathan Corbet:
 "A handful of late-arriving changes, most of which were ready ahead of
  the merge window:

   - More Portuguese translation updates

   - Some docs-build and self-test fixes

   - Bring documentation for the user-space access primitives
     in include/linux/uaccess.h into the docs build.

     This revealed a number of malformed kerneldoc comments,
     which are fixed in a subsequent tweak to uaccess.h"

* tag 'docs-7.4-2' of git://git.kernel.org/pub/scm/linux/kernel/git/docs/linux:
  uaccess: fix some erroneous kerneldoc comments
  docs/translations/pt_BR: admin-guide: add efi-stub.rst

    [18 lines not shown]
DeltaFile
+425-0Documentation/translations/pt_BR/admin-guide/bootconfig.rst
+328-0Documentation/translations/pt_BR/admin-guide/perf-security.rst
+297-0Documentation/translations/pt_BR/process/debugging/userspace_debugging_guide.rst
+195-0Documentation/translations/pt_BR/admin-guide/sysfs-rules.rst
+134-0Documentation/translations/pt_BR/admin-guide/kernel-parameters.rst
+81-39tools/docs/test_doc_build.py
+1,460-3913 files not shown
+1,900-6319 files

Linux/linux 729beb5 — kernel/sched/ext sub.h internal.h, tools/sched_ext scx_qmap.bpf.c

Merge tag 'sched_ext-for-7.4-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/sched_ext

Pull sched_ext fixes from Tejun Heo:
 "This is a big pull for fixes, but much of it was in the works before
  the merge window.

  Most of these fixes are in sub-scheduler support, which nests BPF
  schedulers under a parent that hands them CPUs. It was heavily
  reworked over recent cycles and is now functionally complete. Porting
  real schedulers on it drove the latest additions and keeps finding
  corner cases.

  For example, once CPUs are shared and can be taken back, the kernel
  must keep every task moving when its scheduler can't run it or is
  failing, and those fallbacks interact subtly with each other and with
  other new core features.

   - The fallback paths meant to keep a task moving when its scheduler
     can't run it or is failing could themselves leave it stuck

    [36 lines not shown]
DeltaFile
+685-246kernel/sched/ext/ext.c
+546-192kernel/sched/ext/sub.c
+73-17kernel/sched/ext/internal.h
+15-14tools/sched_ext/include/scx/enums_abi.autogen.h
+24-2kernel/sched/ext/sub.h
+3-22tools/sched_ext/scx_qmap.bpf.c
+1,346-4935 files not shown
+1,401-50611 files

Linux/linux 2152c75 — Documentation/admin-guide cgroup-v2.rst, kernel/cgroup cpuset-internal.h cgroup.c

Merge tag 'cgroup-for-7.4-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup

Pull cgroup fixes from Tejun Heo:

 - cgroup.kill did not kill a process whose thread group leader had
   exited while other threads still ran, nor those threads once moved to
   another cgroup, letting a process survive its container being killed

 - A cgroup.procs write under favordynmods could migrate a newly forked
   process before fork linked it to its cgroup, corrupting cgroup task
   lists

 - cpuset partition fixes for nested hierarchies: invalidation, revival,
   shrinking and switches between root and isolated could leak isolated
   CPUs, skip or miscompute the housekeeping check, or leave wrong
   effective CPUs:

     - A root partition can no longer be created under an isolated
       parent or stay valid under one, as disabling it could leave no

    [35 lines not shown]
DeltaFile
+406-274kernel/cgroup/cpuset.c
+226-58tools/testing/selftests/cgroup/test_cpuset_prs.sh
+158-0tools/testing/selftests/cgroup/test_kill.c
+29-1kernel/cgroup/cgroup.c
+6-0kernel/cgroup/cpuset-internal.h
+3-1Documentation/admin-guide/cgroup-v2.rst
+828-3346 files

Linux/linux 8f44631 — drivers/net tun.c

tun: drop batched packets while the device is down

tun_sendmsg() handles TUN_MSG_PTR batches from vhost-net by calling
tun_xdp_one() instead of tun_get_user(). But this path does not check
IFF_UP, allowing packets from a guest to be injected into the host
receive path while the device is administratively down.

Check IFF_UP in tun_xdp_one() before running XDP or building an skb.
Drop the packet when the device is down, matching tun_get_user().

Fixes: 043d222f93ab ("tuntap: accept an array of XDP buffs through sendmsg()")
Signed-off-by: Xiao Liang <shaw.leon at gmail.com>
Reviewed-by: Willem de Bruijn <willemb at google.com>
Link: https://patch.msgid.link/20261027101830.85327-1-shaw.leon@gmail.com
Signed-off-by: Jakub Kicinski <kuba at kernel.org>
DeltaFile
+6-0drivers/net/tun.c
+6-01 files

Linux/linux 5bc3aaa — net/netlink af_netlink.c, tools/testing/selftests/net netlink-dumps.c

Merge branch 'netlink-fix-a-dump-livelock-with-a-notification-queued'

Jhonata Poma-Hansen says:

====================
netlink: fix a dump livelock with a notification queued

A netlink dump that starts while a notification is still charged to a
socket with a small receive buffer fails with ENOBUFS, and every retry
from recvmsg() fails the same way. A reader that peeks before reading,
as libnl does, never consumes the message at the head of the queue and
spins forever. I hit this with "iw dev wlan0 scan" on an arm64 board.

Patch 1 goes back to checking sk_rcvbuf before charging the dump skb,
as before commit ae8f160e7eb2. Patch 2 adds a selftest; it fails
without patch 1 and is skipped without the privileges to create a
netns.
====================


    [2 lines not shown]
DeltaFile
+102-0tools/testing/selftests/net/netlink-dumps.c
+5-1net/netlink/af_netlink.c
+107-12 files

Linux/linux e615d0a — tools/testing/selftests/net netlink-dumps.c

selftests: net: netlink-dumps: start a dump with a notification queued

Add a test which starts a link dump on a socket with SO_RCVBUF 2048
while a link notification is still queued, after a large read made the
kernel attempt large dump skbs. It reads like libnl does, peeking
before each read, and expects the dump to complete with a zero status
and at least one link. The notifications come from bringing lo up and
down, so the test runs in its own netns and is skipped without the
privileges to create one.

The test fails without the previous patch.

Signed-off-by: Jhonata Poma-Hansen <jhonata.poma at gmail.com>
Link: https://patch.msgid.link/20261027-netlink-dump-livelock-v2-2-c4bb05352a33@gmail.com
Signed-off-by: Jakub Kicinski <kuba at kernel.org>
DeltaFile
+102-0tools/testing/selftests/net/netlink-dumps.c
+102-01 files

Linux/linux b45d377 — net/netlink af_netlink.c

netlink: check sk_rcvbuf before charging the dump skb

Since commit ae8f160e7eb2 ("netlink: Fix wraparounds of
sk->sk_rmem_alloc."), netlink_dump() charges the dump skb first and
queues it only if sk_rmem_alloc is still below sk_rcvbuf. Commit
a215b5723922 ("netlink: make sure we allow at least one dump skb")
added an exception for an empty socket.

A dump that starts while something else is still charged to a socket
with a small receive buffer fails with ENOBUFS and stays running.
Every recvmsg() retries it, fails again and sets sk_err, so a reader
that peeks before reading, as libnl does, gets ENOBUFS on the read
after each peek, never consumes the message at the head of the queue
and spins forever.

I hit this with "iw dev wlan0 scan" hanging at 100% CPU on an arm64
board with a 6.6 based kernel (iw 5.19 sets SO_RCVBUF to 8KiB). A
kprobe trace showed the scan dump starting while the NEW_SCAN_RESULTS
notification iw had just read was still charged to its socket,

    [17 lines not shown]
DeltaFile
+5-1net/netlink/af_netlink.c
+5-11 files

Linux/linux c989725 — drivers/net loopback.c, include/linux etherdevice.h

Merge branch 'net-fix-eth_type_trans-crashes-on-skbs-coming-from-the-stack'

Eric Dumazet says:

====================
net: fix eth_type_trans() crashes on skbs coming from the stack

eth_type_trans() assumes ETH_HLEN bytes are present in skb->head.
NIC drivers always provide this, and they should keep using the fast
version, without an extra pskb_may_pull().

Devices looping skbs from their transmit path back to their receive
path get skbs built by the stack instead. tc actions (act_vlan pop_eth,
act_ife decode), BPF helpers (bpf_skb_change_head() before a redirect)
or OVS actions (pop_eth followed by pop_mpls/pop_nsh) can leave fewer
than ETH_HLEN bytes in the linear part, and eth_type_trans() then hits
the BUG() in __skb_pull().

Instead of fixing every producer, or adding a check to all

    [41 lines not shown]
DeltaFile
+28-0include/linux/etherdevice.h
+12-7tools/testing/selftests/bpf/prog_tests/empty_skb.c
+13-5net/core/dev.c
+7-1net/openvswitch/vport-internal_dev.c
+7-1drivers/net/loopback.c
+4-0net/sched/act_ife.c
+71-146 files

Linux/linux 498c631 — net/sched act_ife.c

net/sched: act_ife: do not consume the inner header on egress

The issue:
tcf_ife_decode() unconditionally calls eth_type_trans(), which pulls
ETH_HLEN.  On egress this consumes the inner Ethernet header, and the
device receives an skb whose data points to the L3 header:

- loopback_xmit() parses L3 data as Ethernet: the "ethertype" comes
  from the inner IPv4 source address, and the decapsulated packet is
  dropped or misparsed.
- a real NIC transmits the frame without its Ethernet header.

(The __skb_pull() BUG this used to trigger in loopback_xmit() when the
remaining linear area was short is handled by "loopback: use
eth_type_trans_careful()".)

The Fix:
Parse the inner Ethernet header with eth_type_trans() in both directions,
then restore the egress data position and MAC length.  On ingress the

    [19 lines not shown]
DeltaFile
+4-0net/sched/act_ife.c
+4-01 files

Linux/linux b55e5a0 — net/openvswitch vport-internal_dev.c

openvswitch: use eth_type_trans_careful() in internal_dev_recv()

OVS actions like pop_eth followed by pop_mpls(ETH_P_TEB) or pop_nsh
can expose an inner Ethernet header which is not in the linear part
of the skb. Output to an internal port then crashes in eth_type_trans():

  flow: in_port(0),eth(),eth_type(0x8847),mpls(lse=0x00010140)
  actions: pop_eth,pop_mpls(0x6558),0
  # AF_PACKET SOCK_RAW on dp0: eth / mpls / eth / 4096 bytes of payload

  kernel BUG at include/linux/skbuff.h:2839!
  RIP: 0010:eth_type_trans (include/linux/etherdevice.h:635 net/ethernet/eth.c:163)
  Call Trace:
   internal_dev_recv (net/openvswitch/vport-internal_dev.c:202) openvswitch
   do_execute_actions (net/openvswitch/actions.c:1296) openvswitch
   ovs_execute_actions (net/openvswitch/actions.c:1606) openvswitch
   ovs_dp_process_packet (net/openvswitch/datapath.c:310) openvswitch
   ovs_vport_receive (net/openvswitch/vport.c:448) openvswitch
   internal_dev_xmit (net/openvswitch/vport-internal_dev.c:42) openvswitch

    [18 lines not shown]
DeltaFile
+7-1net/openvswitch/vport-internal_dev.c
+7-11 files

Linux/linux 2519a6f — include/linux etherdevice.h

net: add eth_type_trans_careful()

eth_type_trans() assumes ETH_HLEN bytes are present in skb->head.
NIC drivers always provide this, and they should keep using the fast
version.

Devices looping skbs from their transmit path back to their receive
path get skbs built by the stack instead. Their link-layer header
might have been popped by tc actions (act_vlan pop_eth, act_ife decode)
or OVS actions (pop_eth + pop_mpls / pop_nsh), leaving fewer than
ETH_HLEN bytes in the linear part. eth_type_trans() then hits
the BUG() in __skb_pull().

Add eth_type_trans_careful(), which first pulls the Ethernet header,
and returns a drop reason on failure, so that the few devices exposed
to this can drop such packets.

Signed-off-by: Eric Dumazet <edumazet at kernel.org>
Reviewed-by: Aaron Conole <aconole at redhat.com>

    [6 lines not shown]
DeltaFile
+28-0include/linux/etherdevice.h
+28-01 files

Linux/linux 695e140 — net/core dev.c, tools/testing/selftests/bpf/prog_tests empty_skb.c

net: use eth_type_trans_careful() in __dev_forward_skb2()

A tc egress BPF program can push a tiny link-layer header with
bpf_skb_change_head() on an skb whose head is almost empty, then
redirect it to an Ethernet device ingress. __bpf_redirect_common()
only checks mac_header < network_header, and __dev_forward_skb2()
crashes in eth_type_trans():

  tc filter add dev lo egress pref 1 matchall action vlan pop_eth continue
  tc filter add dev lo egress pref 2 bpf da obj prog.o
  # prog: bpf_skb_change_head(skb, 1, 0);
  #       return bpf_redirect(veth1_ifindex, BPF_F_INGRESS);
  # AF_PACKET SOCK_RAW on lo: eth / eth / 8192 bytes of payload

  kernel BUG at include/linux/skbuff.h:2839!
  RIP: 0010:eth_type_trans (include/linux/etherdevice.h:635 net/ethernet/eth.c:163)
  Call Trace:
   __dev_forward_skb2 (net/core/dev.c:2507)
   dev_forward_skb_nomtu (net/core/dev.c:2546)

    [21 lines not shown]
DeltaFile
+12-7tools/testing/selftests/bpf/prog_tests/empty_skb.c
+13-5net/core/dev.c
+25-122 files

Linux/linux 093a289 — drivers/net loopback.c

loopback: use eth_type_trans_careful()

tc egress actions can leave an skb with fewer than ETH_HLEN bytes in
its linear part. loopback_xmit() then crashes in eth_type_trans():

  tc qdisc add dev lo clsact
  tc filter add dev lo egress matchall action vlan pop_eth
  # AF_PACKET SOCK_RAW: eth / eth / 8192 bytes of payload

  kernel BUG at include/linux/skbuff.h:2839!
  RIP: 0010:eth_type_trans (include/linux/etherdevice.h:635 net/ethernet/eth.c:163)
  Call Trace:
   loopback_xmit (drivers/net/loopback.c:87)
   dev_hard_start_xmit (include/linux/netdevice.h:5455 include/linux/netdevice.h:5464 net/core/dev.c:4057 net/core/dev.c:4073)
   __dev_queue_xmit (net/core/dev.c:5066)
   packet_sendmsg (net/packet/af_packet.c:3157 net/packet/af_packet.c:3189)

The same happens with "action ife decode" on lo egress.


    [13 lines not shown]
DeltaFile
+7-1drivers/net/loopback.c
+7-11 files

Linux/linux b7ff0e7 — net/ipv4 tcp_ipv4.c

tcp: initialize mapped children before route lookup

IPv4 passive opens on a dual-stack listener go through
tcp_v4_syn_recv_sock() with tcp_v6_mapped_child_init() as the optional
initializer. The callback currently runs after the output route lookup.
If that lookup fails, tcp_done() destroys a clone whose pinet6 and
ipv6_fl_list still refer to the listener's state.

With the flowlabel list head in inet_sock, fl6_free_socklist() walks
the clone's list and RCU-frees its nodes without unlinking them from the
live listener. Subsequent flowlabel operations can use or free the nodes
again. Commit 858d2a4f67ff ("tcp: fix potential race in
tcp_v6_syn_recv_sock()") moved the initializer before ehash insertion,
but did not cover this error path.

Invoke the existing initializer after the IPv4 fields it consumes have
been set, but before route lookup can fail. It needs neither the
destination nor sk_setup_caps(), and all later disposal paths remain
covered.

    [7 lines not shown]
DeltaFile
+6-4net/ipv4/tcp_ipv4.c
+6-41 files

Linux/linux c1df9c0 — net/ipv4 tcp_output.c

tcp: fix reordering addition overflow in MTU probing

Commit efb8763d7bbb ("net: ipv4: bound TCP reordering sysctl writes and
MTU probe sizes") widened size_needed and the MSS multiplication, but
tp->reordering + 1 is still evaluated as u32. RTAX_REORDERING accepts
an unrestricted u32, and tcp_init_metrics() can install U32_MAX.

In that case the extra-data requirement becomes zero. A write queue
with probe_size - 1 data bytes and a FIN satisfies the sequence-space
check. The coalescing walk can pass the queue head to
tcp_skb_can_collapse(), and tcp_clone_payload() can produce an skb
whose advertised payload exceeds the data in its fragments. Local
delivery followed by TCP_ZEROCOPY_RECEIVE can then walk beyond the
fragment array. KASAN reports a slab-out-of-bounds read in
can_map_frag().

Cast reordering before incrementing it so the arithmetic handles the
entire u32 metric range. For U32_MAX, the required size exceeds the
32-bit queue and window limits, so the existing checks skip the probe.

    [13 lines not shown]
DeltaFile
+1-1net/ipv4/tcp_output.c
+1-11 files

Linux/linux dbd62ad — net/ipv4 tcp.c

tcp: avoid double destroy in tcp_abort() of an unaccepted child

tcp_abort() checks for TCP_CLOSE while only owning the socket lock,
then grabs the BH lock before calling tcp_done_with_error().

For a child still sitting in a listener accept queue (which can be
reached via SOCK_DESTROY or bpf_sock_destroy()), inet_csk_listen_stop()
can run in this window: it only holds the child BH lock, and calls
inet_child_forget(), which disconnects, orphans and destroys the child.

tcp_abort() then calls tcp_done_with_error() -> tcp_done(), which sees
SOCK_DEAD and calls inet_csk_destroy_sock() a second time, leading to
a double sock_put() and a use-after-free.

Recheck TCP_CLOSE after acquiring the BH lock, unless we just closed
a listener ourselves, in which case tcp_done_with_error() must still
run to report the error.

Note that the WARN_ON(sock_owned_by_user(child)) in

    [9 lines not shown]
DeltaFile
+13-1net/ipv4/tcp.c
+13-11 files

Linux/linux 4f45e97 — drivers/net/ethernet/broadcom bgmac.c

net: bgmac: fix TX DMA unmapping and slot cleanup

When mapping a fragment fails, bgmac_dma_tx_add() unwinds with the
wrong slots. It passes the failed fragment's slot->dma_addr, which
holds the mapping error, to dma_unmap_single() for the head. The
fragment loop indexes from ring->end instead of ring->end + 1, so it
unmaps the head a second time as a page and leaves the last mapped
fragment mapped. None of the affected slots get their dma_addr cleared
either, which includes the head slot when mapping the head fails.

bgmac_dma_tx_ring_free() unmaps every slot with a non-zero dma_addr,
so tearing down the ring unmaps these addresses again. It also frees
the skbs of pending TX slots but leaves slot->skb and slot->dma_addr
set. The slots survive a down/up cycle, and bgmac_dma_tx_add() only
sets slot->skb on the last slot of a packet. If a slot with a stale
pointer is later used for the head or a fragment of a scatter/gather
packet, bgmac_dma_tx_free() frees the old skb a second time when that
slot completes.


    [20 lines not shown]
DeltaFile
+32-19drivers/net/ethernet/broadcom/bgmac.c
+32-191 files

Linux/linux de788d8 — net/core gro.c, net/ipv4 tcp_offload.c

gro: do not GRO GSO packets with inconsistent payload

tcp_gro_receive() excludes empty non-GSO packets with the unsigned
len - 1 check, but its GSO branch only checks that gso_size matches
the held packet's MSS. A trusted TCP GSO skb can reach GRO again with
no payload after TC pedit increases its TCP data offset.

If the skb is fully linear, skb_gro_receive() then enters its fragment
transfer path with nr_frags == 0. The do-while loop copies skb_frag_t
entries backwards beyond both fragment arrays. An unprivileged process
using its own user and network namespaces can trigger a KASAN
slab-out-of-bounds write and panic through veth, pedit and GRE.

More generally, the payload of such a packet can be shrunk to any
value, making it inconsistent with its gso_segs, and a GSO packet
with gso_segs == 0 contributes no segment to the GRO packet.

Do not aggregate GSO packets with gso_segs == 0, and require the
payload of GSO packets to be consistent with gso_segs and gso_size,

    [10 lines not shown]
DeltaFile
+9-3net/ipv4/tcp_offload.c
+3-2net/core/gro.c
+12-52 files

Linux/linux dc4dd12 — net/packet af_packet.c

net/packet: check TX_RING fragments before memory accounting

tpacket_fill_skb() adds the full non-linear payload length to
skb->truesize and sk_wmem_alloc before checking MAX_SKB_FRAGS. With
PACKET_VNET_HDR, userspace can submit a ring-sized frame even when it
greatly exceeds the device MTU.

A near-INT_MAX frame can saturate sk_wmem_alloc before the fragment
loop rejects it. A subsequent refcount_add(0x40000001) can temporarily
turn REFCOUNT_SATURATED into 1. A concurrent TX completion can then
drop that apparent last reference and free the still-live packet
socket before refcount_warn_saturate() restores the counter.

Check that the remaining payload fits in MAX_SKB_FRAGS pages before
accounting it. Include the initial page offset in the calculation,
and move the existing -EFAULT handling out of the fragment loop.
This preserves the accepted packet sizes and error code while
preventing an invalid frame from injecting an oversized byte charge.


    [9 lines not shown]
DeltaFile
+6-6net/packet/af_packet.c
+6-61 files

Linux/linux 59e7264 — drivers/net/ethernet/broadcom/bnxt bnxt_xdp.c bnxt_ethtool.c

Merge branch 'eth-bnxt-fix-rx-buffer-leaks-under-oom'

Jakub Kicinski says:

====================
eth: bnxt: fix Rx buffer leaks under OOM

Commit bd3beb5c8691 ("eth: bnxt: disable rx-copybreak by default")
changed the defaults putting users on buggy(ier) driver paths.

Fix various ways bnxt may leak buffers under OOM. The first patch
fixes the real bug that was hit in production. Second patch fixes
an issue I hit while testing the first one. The next 3 patches
fix other Rx buffer leaks pointed out by an LLM during review.
====================

Link: https://patch.msgid.link/20261027234940.1267225-1-kuba@kernel.org
Signed-off-by: Jakub Kicinski <kuba at kernel.org>
DeltaFile
+39-19drivers/net/ethernet/broadcom/bnxt/bnxt.c
+1-0drivers/net/ethernet/broadcom/bnxt/bnxt_xdp.c
+1-0drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
+41-193 files

Linux/linux 1b2f02f — drivers/net/ethernet/broadcom/bnxt bnxt.c

eth: bnxt: don't leak buffers when XDP agg buffer allocation fails

If a replacement agg buffer can't be allocated for a packet received
with XDP attached, bnxt_rx_pkt() drops the packet without returning
its head buffer to the ring. The head buffer leaks, and since rx_prod
still advances, the device gets a BD with a stale DMA address which
points at a buffer the driver no longer owns. When that BD completes
the driver finds no buffer in the slot.

The agg buffers consumed before the failing one have already been
replaced on the agg ring, they are referenced only by the frags of
the xdp_buff, which nobody frees. bnxt_xdp_buff_frags_free() would
skip them since the frags flag is set only on success, so set it
upfront.

Pointed out in LLM review of the first patch of the series.
Tested on a BCM57504 at MTU 9000 with a frags-capable XDP_PASS
program, receiving 8000B ICMPv6 echo requests (a head and two agg
buffers each) while page_pool_alloc_netmems() called from

    [8 lines not shown]
DeltaFile
+11-6drivers/net/ethernet/broadcom/bnxt/bnxt.c
+11-61 files