0day kernel testing robot got the below dmesg and the first bad commit is
Author: Jason A. Donenfeld <Jason(a)zx2c4.com>
AuthorDate: Wed Nov 20 20:38:49 2019 +0100
Commit: Jason A. Donenfeld <Jason(a)zx2c4.com>
CommitDate: Thu Dec 5 16:55:58 2019 +0100
net: WireGuard secure network tunnel
WireGuard is a layer 3 secure networking tunnel made specifically for
the kernel, that aims to be much simpler and easier to audit than IPsec.
Extensive documentation and description of the protocol and
considerations, along with formal proofs of the cryptography, are
This commit implements WireGuard as a simple network device driver,
accessible in the usual RTNL way used by virtual network drivers. It
makes use of the udp_tunnel APIs, GRO, GSO, NAPI, and the usual set of
networking subsystem APIs. It has a somewhat novel multicore queueing
system designed for maximum throughput and minimal latency of encryption
operations, but it is implemented modestly using workqueues and NAPI.
Configuration is done via generic Netlink, and following a review from
the Netlink maintainer a year ago, several high profile userspace tools
have already implemented the API.
This commit also comes with several different tests, both in-kernel
tests and out-of-kernel tests based on network namespaces, taking profit
of the fact that sockets used by WireGuard intentionally stay in the
namespace the WireGuard interface was originally created, exactly like
the semantics of userspace tun devices. See wireguard.com/netns/ for
pictures and examples.
The source code is fairly short, but rather than combining everything
into a single file, WireGuard is developed as cleanly separable files,
making auditing and comprehension easier. Things are laid out as
* noise.[ch], cookie.[ch], messages.h: These implement the bulk of the
cryptographic aspects of the protocol, and are mostly data-only in
nature, taking in buffers of bytes and spitting out buffers of
bytes. They also handle reference counting for their various shared
pieces of data, like keys and key lists.
* ratelimiter.[ch]: Used as an integral part of cookie.[ch] for
ratelimiting certain types of cryptographic operations in accordance
with particular WireGuard semantics.
* allowedips.[ch], peerlookup.[ch]: The main lookup structures of
WireGuard, the former being trie-like with particular semantics, an
integral part of the design of the protocol, and the latter just
being nice helper functions around the various hashtables we use.
* device.[ch]: Implementation of functions for the netdevice and for
rtnl, responsible for maintaining the life of a given interface and
wiring it up to the rest of WireGuard.
* peer.[ch]: Each interface has a list of peers, with helper functions
available here for creation, destruction, and reference counting.
* socket.[ch]: Implementation of functions related to udp_socket and
the general set of kernel socket APIs, for sending and receiving
ciphertext UDP packets, and taking care of WireGuard-specific sticky
socket routing semantics for the automatic roaming.
* netlink.[ch]: Userspace API entry point for configuring WireGuard
peers and devices. The API has been implemented by several userspace
tools and network management utility, and the WireGuard project
distributes the basic wg(8) tool.
* queueing.[ch]: Shared function on the rx and tx path for handling
the various queues used in the multicore algorithms.
* send.c: Handles encrypting outgoing packets in parallel on
multiple cores, before sending them in order on a single core, via
workqueues and ring buffers. Also handles sending handshake and cookie
messages as part of the protocol, in parallel.
* receive.c: Handles decrypting incoming packets in parallel on
multiple cores, before passing them off in order to be ingested via
the rest of the networking subsystem with GRO via the typical NAPI
poll function. Also handles receiving handshake and cookie messages
as part of the protocol, in parallel.
* timers.[ch]: Uses the timer wheel to implement protocol particular
event timeouts, and gives a set of very simple event-driven entry
point functions for callers.
* main.c, version.h: Initialization and deinitialization of the module.
* selftest/*.h: Runtime unit tests for some of the most security
* tools/testing/selftests/wireguard/netns.sh: Aforementioned testing
script using network namespaces.
This commit aims to be as self-contained as possible, implementing
WireGuard as a standalone module not needing much special handling or
coordination from the network subsystem. I expect for future
optimizations to the network stack to positively improve WireGuard, and
vice-versa, but for the time being, this exists as intentionally
We introduce a menu option for CONFIG_WIREGUARD, as well as providing a
verbose debug log and self-tests via CONFIG_WIREGUARD_DEBUG.
Signed-off-by: Jason A. Donenfeld <Jason(a)zx2c4.com>
Cc: David Miller <davem(a)davemloft.net>
Cc: Greg KH <gregkh(a)linuxfoundation.org>
Cc: Linus Torvalds <torvalds(a)linux-foundation.org>
Cc: Herbert Xu <herbert(a)gondor.apana.org.au>
aaa35ee980 crypto: arch - conditionalize crypto api in arch glue for lib code
d8bc22f0b6 net: WireGuard secure network tunnel
bd75d5ec36 [DO NOT UPSTREAM] integration tree maintainer scripts
| | aaa35ee980 | d8bc22f0b6 | bd75d5ec36 |
| boot_successes | 39 | 0 | 0 |
| boot_failures | 0 | 19 | 24 |
| BUG:kernel_reboot-without-warning_in_boot_stage | 0 | 19 | 24 |
If you fix the issue, kindly add following tag
Reported-by: kernel test robot <lkp(a)intel.com>
Decompressing Linux... Parsing ELF... done.
Booting the kernel.
BUG: kernel reboot-without-warning in boot stage
Linux version 5.4.0-10273-gd8bc22f0b6306 #1
Command line: root=/dev/ram0 hung_task_panic=1 debug apic=debug sysrq_always_enabled rcupdate.rcu_cpu_stall_timeout=100 net.ifnames=0 printk.devkmsg=on panic=-1 softlockup_panic=1 nmi_watchdog=panic oops=panic load_ramdisk=2 prompt_ramdisk=0 drbd.minor_count=8 systemd.log_level=err ignore_loglevel console=tty0 earlyprintk=ttyS0,115200 console=ttyS0,115200 vga=normal rw link=/cephfs/kbuild/run-queue/yocto-vm-yocto/x86_64-randconfig-c001-20191205/zx2c4:jd:wireguard-azinc:d8bc22f0b63068476818bfb607a34487676815e6:bisect-BUG:_kernel_reboot-without-warning_in_boot_stage/.vmlinuz-d8bc22f0b63068476818bfb607a34487676815e6-20191206202648-4:yocto-vm-yocto-cfb84499a0ac branch=zx2c4/jd/wireguard-azinc BOOT_IMAGE=/pkg/linux/x86_64-randconfig-c001-20191205/gcc-7/d8bc22f0b63068476818bfb607a34487676815e6/vmlinuz-5.4.0-10273-gd8bc22f0b6306 rcuperf.shutdown=0 watchdog_thresh=60
# HH:MM RESULT GOOD BAD GOOD_BUT_DIRTY DIRTY_NOT_BAD
git bisect start bd75d5ec36a5b9bb8028bcfc6754b6a32e6c2261 596cf45cbf6e4fa7bcb0df33e373a7d062b644b5 --
git bisect good aaa35ee980a42670d5d91d5e54589d9471fb3ed7 # 15:10 G 31 0 0 0 crypto: arch - conditionalize crypto api in arch glue for lib code
git bisect bad d8bc22f0b63068476818bfb607a34487676815e6 # 15:21 B 0 19 57 0 net: WireGuard secure network tunnel
# first bad commit: [d8bc22f0b63068476818bfb607a34487676815e6] net: WireGuard secure network tunnel
git bisect good aaa35ee980a42670d5d91d5e54589d9471fb3ed7 # 19:07 G 31 0 0 0 crypto: arch - conditionalize crypto api in arch glue for lib code
# extra tests with debug options
git bisect good d8bc22f0b63068476818bfb607a34487676815e6 # 19:39 G 10 0 0 2 net: WireGuard secure network tunnel
# extra tests on head commit of zx2c4/jd/wireguard-azinc
git bisect bad bd75d5ec36a5b9bb8028bcfc6754b6a32e6c2261 # 00:42 B 0 24 54 0 [DO NOT UPSTREAM] integration tree maintainer scripts
# bad: [bd75d5ec36a5b9bb8028bcfc6754b6a32e6c2261] [DO NOT UPSTREAM] integration tree maintainer scripts
# extra tests on revert first bad commit
git bisect good 69d6861b57da29459a51c7ea0cdd4406bf3647ca # 01:46 G 11 0 0 0 Revert "net: WireGuard secure network tunnel"
# good: [69d6861b57da29459a51c7ea0cdd4406bf3647ca] Revert "net: WireGuard secure network tunnel"
0-DAY kernel test infrastructure Open Source Technology Center
https://email@example.com Intel Corporation
Do you know if there are plans to port LKP to RISCV? Or if the
activity has already started.
We have linux (yocto) on Riscv-HiFive Unleashed-64 bit. Wanted to
port/test lkp on it.