Hello netdev-team, this is a pull request of 23 patches for net-next/main. The first 9 patches are by Oleksij Rempel and add self tests for the CAN J1939 protocol. The remaining patches target the peak_usb driver and fix various problems mainly found by LLM review. The first is by Stefan Günther, the remaining ones by Stéphane Grosjean. regards, Marc The following changes since commit c63b67b946fcd4efb24439f70ee081dfa485dc40: tools: ynl: reject missing regen path argument (2026-12-02 19:13:17 +0100) are available in the Git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can-next.git tags/linux-can-next-for-7.5-20261203 for you to fetch changes up to bd650ec39de3abb8339c5b453f3e48da389d1e52: Merge patch series "can: peak_usb: fixes and input validation hardening" (2026-12-02 23:58:16 +0100) ---------------------------------------------------------------- linux-can-next-for-7.5-20261203 ---------------------------------------------------------------- Marc Kleine-Budde (2): Merge patch series "selftests: can: add J1939 socket and transport tests" Merge patch series "can: peak_usb: fixes and input validation hardening" Oleksij Rempel (9): selftests: can: install net/lib.sh with the CAN tests selftests: can: add J1939 test helper header and library selftests: can: add J1939 base functional tests selftests: can: add J1939 socket option and metadata tests selftests: can: add J1939 addressing and concurrency tests selftests: can: add J1939 wire-format tests against CAN_RAW selftests: can: add J1939 TP/ETP multi-frame tests against CAN_RAW selftests: can: cover J1939 transport abort and timeout paths selftests: can: check SO_J1939_PROMISC receive effect Stefan Günther (1): can: peak_usb: fix missing CAN_ERR_FLAG when reporting error counters Stéphane Grosjean (13): can: peak_usb: harden PCAN-USB message validation can: peak_usb: replace open-coded bitmask operations with bitops can: peak_usb: harden channel handling in PCAN-USB FD can: peak_usb: fix RX cursor desync for self-received RTR frames with SRR can: peak_usb: reject records for unset channels in PCAN-USB Pro can: peak_usb: register the netdevs only once all channels are set up can: peak_usb: validate the data length of PCAN-USB Pro CAN records can: peak_usb: don't read past the message in PCAN-USB Pro decoders can: peak_usb: dump undecodable URBs once and rate limit decode errors can: peak_usb: don't return an uninitialized PCAN-USB CAN channel ID can: peak_usb: pass the dev_num argument of PCAN-USB Pro GETDEVID can: peak_usb: don't send uninitialized stack bytes to PCAN-USB devices can: peak_usb: don't send uninitialized heap bytes in restart commands MAINTAINERS | 1 + drivers/net/can/usb/peak_usb/pcan_usb.c | 69 +- drivers/net/can/usb/peak_usb/pcan_usb_core.c | 111 ++- drivers/net/can/usb/peak_usb/pcan_usb_core.h | 10 +- drivers/net/can/usb/peak_usb/pcan_usb_fd.c | 91 +- drivers/net/can/usb/peak_usb/pcan_usb_pro.c | 85 +- tools/testing/selftests/net/can/.gitignore | 6 + tools/testing/selftests/net/can/Makefile | 26 +- tools/testing/selftests/net/can/config | 3 + tools/testing/selftests/net/can/j1939_gw.c | 129 +++ tools/testing/selftests/net/can/j1939_helpers.c | 593 +++++++++++++ tools/testing/selftests/net/can/j1939_helpers.h | 328 +++++++ tools/testing/selftests/net/can/j1939_lib.sh | 171 ++++ tools/testing/selftests/net/can/j1939_tests.h | 99 +++ tools/testing/selftests/net/can/test_j1939_addr.c | 233 +++++ tools/testing/selftests/net/can/test_j1939_addr.sh | 4 + tools/testing/selftests/net/can/test_j1939_base.c | 241 ++++++ tools/testing/selftests/net/can/test_j1939_base.sh | 7 + tools/testing/selftests/net/can/test_j1939_multi.c | 964 +++++++++++++++++++++ .../testing/selftests/net/can/test_j1939_multi.sh | 4 + tools/testing/selftests/net/can/test_j1939_opts.c | 442 ++++++++++ tools/testing/selftests/net/can/test_j1939_opts.sh | 4 + tools/testing/selftests/net/can/test_j1939_wire.c | 202 +++++ tools/testing/selftests/net/can/test_j1939_wire.sh | 4 + 24 files changed, 3709 insertions(+), 118 deletions(-) create mode 100644 tools/testing/selftests/net/can/j1939_gw.c create mode 100644 tools/testing/selftests/net/can/j1939_helpers.c create mode 100644 tools/testing/selftests/net/can/j1939_helpers.h create mode 100644 tools/testing/selftests/net/can/j1939_lib.sh create mode 100644 tools/testing/selftests/net/can/j1939_tests.h create mode 100644 tools/testing/selftests/net/can/test_j1939_addr.c create mode 100755 tools/testing/selftests/net/can/test_j1939_addr.sh create mode 100644 tools/testing/selftests/net/can/test_j1939_base.c create mode 100755 tools/testing/selftests/net/can/test_j1939_base.sh create mode 100644 tools/testing/selftests/net/can/test_j1939_multi.c create mode 100755 tools/testing/selftests/net/can/test_j1939_multi.sh create mode 100644 tools/testing/selftests/net/can/test_j1939_opts.c create mode 100755 tools/testing/selftests/net/can/test_j1939_opts.sh create mode 100644 tools/testing/selftests/net/can/test_j1939_wire.c create mode 100755 tools/testing/selftests/net/can/test_j1939_wire.sh