Re: panic: assertion failed in iflib_txq_drain()

From: David Wolfskill <david_at_catwhisker.org>
Date: Sat, 18 Apr 2026 12:06:44 UTC
On Sat, Apr 18, 2026 at 11:47:14AM +0200, Ricardo Branco wrote:
> I'm getting this on FreeBSD-kernel-generic 16.snap20260416224424
> 
> This is happening as soon as I try to ssh to a GMKTec NucBox G3 Plus with
> Ethernet Controller I226-V.
> 
> It also happens when trying to do any TCP connection.  Attached gzipped
> /var/crash/core.txt
> 
> panic: Assertion mp != NULL && *mp != NULL failed at
> /home/pkgbuild/worktrees/main/sys/net/iflib.c:3922 cpuid= 3 time 1776500574
> KDB: stack backtrace:
> db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame
> 0xfffff81078b7450 vpanic at vpanic+0x136/frame 0xfffffe01078b7580
> panic
> at panic+0x43/frame 0xfffffe01078b75e0
> iflib_txq_drain at iflib_txq_drain+0x429/frame 0xfffffe81078b7660
> drain_ring_lockless() at drain_ring_lockless+0x8a/frame 0xfffffe01078b76b0
> ifmp_ring_enqueue() at ifmp_ring_enqueue+0x332/frame 0xfffffe81078b7700
> ....

So... one of the machines on which I track head got this, as well -- my
(mostly-)headless build machine.  (2 laptops, updated in sync with the
build machine, did not panic.  One of those also uses a wired NIC.)

In my case, the failure occurred after updating from 

FreeBSD 16.0-CURRENT #547 main-n285122-3b373d484046: Fri Apr 17 13:15:23 UTC 2026     root@freebeast.catwhisker.org:/common/S4/obj/usr/src/amd64.amd64/sys/GENERIC amd64 1600015 1600015

to main-n285179-7e9d974bc023.  (As noted, 2 other machines (so far)
updated to main-n285179-7e9d974bc023 without issue.)

For now, I will reboot the machine to stable/15 (so it can build
packages for tomorrow's weekly update), but once that's done, I'm
happy to poke at it a bit or try out a patch or three, given suitable
clues.

The panic appears "quite reproducible." :-}

Peace,
david
-- 
David H. Wolfskill                              david@catwhisker.org

See https://www.catwhisker.org/~david/publickey.gpg for my public key.