FreeBSD git weekly: 2026-03-16 to 2026-03-22

Introduction

This is a display of mostly-automatically-classified git commits from 2026-03-16 to 2026-03-22.

DEBUG: This version of the report is primarily for checking the classifiers, and therefore contains extra information (in this colour).

Table of contents and commits per category:

(0) Highlighted commits (these are copies, not in stats)
1 1.0% Userland programs
4 4.0% Documentation
21 20.8% Hardware support
12 11.9% Networking
12 11.9% System administration
1 1.0% Libraries
2 2.0% Filesystems
18 17.8% Kernel
13 12.9% Build system
0 0.0% Internal organizational stuff
6 5.9% Testing
2 2.0% Style, typos, and comments
5 5.0% Contrib code
4 4.0% Reverted commits
0 0.0% Unclassified commits
101 100% total
Technical notes about this page

debug: info about the automatic classification

num % num changed stage
3 3.0% 0 00-reverts
2 2.0% 0 01-style
17 16.8% 0 02-filenames_wildcards
5 5.0% 0 02b-filenames_wildcards2
44 43.6% 0 03-filenames_plain1
22 21.8% 0 04-filenames_plain2
6 5.9% 0 05-summary-prefix
2 2.0% 0 Manually-classified commits
0 0.0% 0 Unclassified commits

debug: more stats

num % stage
0 0.0% Misclassified commits
99 98.0% Classified commits, no corrections

debug: groups

3 3.0% num in revert
2 2.0% num in fixes
10 9.9% num in consecutive
15 14.9% Commits in groups

Highlighted commits

For extra visibility, these are copies of commits found in other sections. Most (if not all) come from the commit message containing "Relnotes:", or commits modifying UPDATING.

-- no commits in this category this week --

Userland programs

Commits about commands found in man section 1 (other than networking).

llvm: Link cross-tools with static libllvm.a
We generally use TOOLS_PREFIX being set to indicate that we are building
in the cross-build tools stage.  This check was missing for llvm.prog.mk
consumers other than *tblgen, which have not previously been built as
cross tools.

Reviewed by:    dim
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55930
d478715a72892537d37a70efcb82ee572ac5741a Ed Maste 2026-03-19 02:01:13

debug: classified in 04-filenames_plain2 by 'usr.bin/'

Documentation

Man pages, release notes, etc.

realpath: Improve manual page
* Try to make the RETURN VALUES section flow better.

* Add basename(3), dirname(3), free(3) to the SEE ALSO section.

* Drop the CAVEATS section, which was obsolete the moment realpath(3)
  was added to the Single Unix Specification in 1994.

MFC after:      1 week
Sponsored by:   Klara, Inc.
Reviewed by:    kevans
Differential Revision:  https://reviews.freebsd.org/D55928
1aecb32021ce46d812db36b9037cdc6f423575f9 Dag-Erling Smørgrav 2026-03-19 01:26:21

debug: classified in 02-filenames_wildcards by '.*\.[1-9]'

dtrace.1: Reference dtrace_cam.4
Fixes:        https://cgit.freebsd.org/src/commit/?id=1a7151f79664 cam: Add probes for xpt actions
Event:  AsiaBSDCon 2026
2eb0a888917593220c27c688b026767c20fa68ab Mateusz Piotrowski 2026-03-20 04:24:36

debug: classified in 02-filenames_wildcards by '.*\.[1-9]'

src.conf(5): rebuild after introduction of WITHOUT_PKGSERVE
dc2687bf719a04c81746050bcc1b3c5645efb6cb Baptiste Daroussin 2026-03-20 12:32:55

debug: classified in 02-filenames_wildcards by '.*\.[1-9]'

acpi.4: Update sysctl descriptions for new stypes
The previous S1-S5 options are still accepted for compatibility, but
they are now deprecated in favour of the new generic sleep types.

Reported by:    markj
Reviewed by:    markj
Approved by:    markj
Fixes:          https://cgit.freebsd.org/src/commit/?id=97d152698f48 ("acpi: Use sleep types defined in sys/power.h")
Event:          AsiaBSDCon 2026
Sponsored by:   The FreeBSD Foundation
Differential Revision:  https://reviews.freebsd.org/D56008
2547f972022197012cb3170ab4d6dcd8cd0ee257 Aymeric Wibo 2026-03-21 03:33:30

debug: classified in 02-filenames_wildcards by '.*\.[1-9]'

Hardware support

Hardware drivers and architecture-specific code.

ure(4): Fix spurious link flaps from MII
A race condition in the MII layer causes spurious link down events.
In `statchg`, on link down, check if the PHY reports the link as
actually down using the BMSR register, if not, force the status of the
link to back up and restart TX. Do the same in a MII `linkchg` handler.
On actual link up, restart TX in case it went idle and down.

PR:             https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=252165
Signed-off-by:  Rafael Kitover <rkitover@gmail.com>
Reviewed by:    pouria
Differential Revision: https://reviews.freebsd.org/D55682
33e0568d30a687b3bbd3f00fd9b323ff031e39a2 Rafael Kitover 2026-03-16 10:32:17

debug: classified in 03-filenames_plain1 by 'sys/dev/'

nvme: Removed unused 'regs' variable
The private struct has a 'regs' member that's only written to
and otherwise unused. This change removes it.

Fixes:                  https://cgit.freebsd.org/src/commit/?id=b3d9e5013f3e5 (Don't active memory space)
Requested by:           jhb
Reviewed by:            imp, jhb, jrtc27
Differential Revision:  https://reviews.freebsd.org/D55817
4e3beef84628ce6dfea7f053cddf3289fddf7794 Matt Delco 2026-03-10 19:30:51

debug: classified in 03-filenames_plain1 by 'sys/dev/'

nvme: Replace bus_space_[read|write]_4 with bus_[read|write]_4
The goal this change is to remove the use of the tag and handle
needed by bus_space_[read|write]_4.

Fixes:                  https://cgit.freebsd.org/src/commit/?id=b3d9e5013f3e5 (Don't active memory space)
Requested by:           jhb
Reviewed by:            gallatin, imp, jhb, jrtc27
Differential Revision:  https://reviews.freebsd.org/D55818
889d10d5b12050b4b3923917b5edeac85e8ca706 Matt Delco 2026-03-10 20:12:56

debug: classified in 03-filenames_plain1 by 'sys/dev/'

jevents: include file path in whitelist error message
A small enhancement.

Reviewed by:    Ali Mashtizadeh <ali@mashtizadeh.com>
Sponsored by:   The FreeBSD Foundation
Differential Revision:  https://reviews.freebsd.org/D55830
f0e0c4c52971f58d41a89690d402520500d286bd Mitchell Horne 2026-03-16 23:25:00

debug: classified in 03-filenames_plain1 by 'lib/libpmc/'

libpmc: Query hwpmc for caps
This change allows for fine-grained capabilities per counter index. This
is particularly useful for AMD where subclasses are not exposed to the
general PMC code, but other architectures also have asymmetric behaviors
when it comes to specific counter indices.

A new PMC_OP_GETCAPS op is added to the hwpmc(4) ioctl interface.

Reviewed by:    mhorne
Sponsored by:   Netflix
Pull Request:   https://github.com/freebsd/freebsd-src/pull/2058
44a983d249d05d932b6cff333f130baf70febc22 Ali Mashtizadeh 2026-03-01 22:08:30

debug: classified in 03-filenames_plain1 by '['lib/libpmc/', 'sys/dev/', 'sys/sys/pmc.h']'

pmc.h: bump PMC_VERSION_MINOR
Bump for the addition of PMC_OP_GETCAPS and the recently added Intel
CPUs.

Sponsored by:   The FreeBSD Foundation
e39d3a6b32331437da6c13a4aeb67e5bcca67625 Mitchell Horne 2026-03-16 23:35:35

debug: classified in 03-filenames_plain1 by 'sys/sys/pmc.h'

virtio: Ensure power-of-two alignment for indirect queue
Some platforms enforce power-of-two alignment for bus_dma tags. Rounding up
the natural size may result in over-alignment, but should be safe.

PR:             https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=293770
Reviewed by:    andrew
Fixes:          https://cgit.freebsd.org/src/commit/?id=c499ad6f997c ("virtio: Use bus_dma for ring and indirect buffer allocations")
Sponsored by:   Arm Ltd
Differential Revision:  https://reviews.freebsd.org/D55843
1d13d938fe6c7639d2bb4cb5248a1f81275b6891 Sarah Walker 2026-03-17 10:54:30

debug: classified in 03-filenames_plain1 by 'sys/dev/'

arm64: Have a common call to userret
Rather than each exception calling userret use a common copy. As
syscallret already calls userret we need to skip it in that case.

Reviewed by:    kib
Sponsored by:   Arm Ltd
Differential Revision:  https://reviews.freebsd.org/D55250
14e97448fcebbe4b038eaf5628933abe5f9e690d Andrew Turner 2026-03-17 17:10:07

debug: classified in 03-filenames_plain1 by 'sys/arm64/'

cxgbe(4): adjustments to the output of the slow interrupt handler
- Display an appropriate alert character instead of a question mark for
  unknown bits.
- Display all fatal bits for a register and not just the ones that are
  currently set.

MFC after:      1 week
Sponsored by:   Chelsio Communications
63171222540e10a58f3acacf65a412f44043f511 Navdeep Parhar 2026-03-18 21:56:37

debug: classified in 03-filenames_plain1 by 'sys/dev/'

cxgbe(4): decode the T7 MC interrupt correctly
The layout for the main INT_CAUSE is a bit different for T7.

MFC after:      1 week
Sponsored by:   Chelsio Communications
8f41ee95f9e05b3848d793deaacd591ee2387f0e Navdeep Parhar 2026-03-18 22:20:07

debug: classified in 03-filenames_plain1 by 'sys/dev/'

tpm: fix multi-threaded access with per-open state
The TPM driver currently has a single buffer per instance to hold the
result of a command, and does not allow subsequent commands to be sent
until the current result is read by the same OS thread that sent the
command, with a timeout to throw away the result after a while if the
result is not read in a timely fashion.  This has a couple problems:

 - The timeout code has a bug which causes all subsequent commands to
   hang forever if a different OS thread tries to read the result
   before the OS thread which sent the command, and the OS thread
   which sent the command never tries to read the result.

 - Even if the first problem is fixed, applications expect to be able
   to read the result from a different OS thread than the OS thread
   which sent the command. The particular case that we saw was a go
   application where the go runtime scheduled the goroutine which read
   the result to a different OS thread from one where the goroutine
   that sent the command ran, and there's no way to force these to
   always run on the same OS thread.

Fix all of this by replacing the global result buffer with a per-open
result buffer via devfs_set_cdevpriv(), so that we no longer need to
block subsequent commands until the results of a previous command are
retrieved or care about which OS thread is reading the result of a
command.

Sponsored by:   Netflix
Reviewed by:    olivier, imp
Differential Revision:  https://reviews.freebsd.org/D52328
1fd43ee968c497223254038483685d9f9c68791b Chuck Silvers 2026-03-20 18:48:44

debug: classified in 03-filenames_plain1 by 'sys/dev/'

amd64: move code to check for traps with interrupts disabled into helpers
Reviewed by:  jhb, markj
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D55809
e18449fbe2731399862e82e61fffaadd6739642c Konstantin Belousov 2026-03-11 12:04:55

debug: classified in 03-filenames_plain1 by 'sys/amd64/'

amd64: check that %cs and %ss values from ucontext fit into registers
This change only checks that the values from the user-supplied context
are not truncated by C implicit type convertions.  The validity of the
segment selectors is still checked by hardware.

Reviewed by:    jhb, markj
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D55861
8892176c86db18bd175cc00a2d52dff080babec1 Konstantin Belousov 2026-03-15 07:17:24

debug: classified in 03-filenames_plain1 by 'sys/amd64/'

x86 FRED: add hardware definitions for the trap frames fields
as provided by the Intel document 346446-009 AKA FRED 8.0 and SDM v90,
February 2026.

Note that the layout of the struct trapframe does not change with
FRED. The differences are in addition of two fields at the end of the
structure. Other members are carved from existing tf_cs and tf_ss by
limiting hw-written segments to 16 bits officially, and reusing rest
from the doubleword for the new data.

Reviewed by:    jhb, markj
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D55831
e90950627327de9226b052851b36f341bc72b746 Konstantin Belousov 2026-02-07 03:35:17

debug: classified in 03-filenames_plain1 by '['sys/amd64/', 'sys/x86/']'

amd64: remove assertion about sizeof(struct pcb)
We no longer put pcb on stack, it is part of the struct thread.
Similarly, we do not put user fpu save area on stack.  There is no
constraints on the pcb size due to the XSAVE area required alignment.

Reviewed by:    jhb, markj
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D55931
acce5fa3dbe87ea953fb5060a03859e424398db8 Konstantin Belousov 2026-03-19 03:43:01

debug: classified in 03-filenames_plain1 by 'sys/amd64/'

amd64: add prototype for ia32_syscall()
Sponsored by: The FreeBSD Foundation
MFC after:      1 week
23dc4850fbc9e7abfc54f0ce11f343e4677fd0fb Konstantin Belousov 2026-02-26 00:55:59

debug: classified in 03-filenames_plain1 by 'sys/amd64/'

amd64 trap.c: provide tag for the struct sfhandlers definition
Sponsored by: The FreeBSD Foundation
MFC after:      1 week
8cc1c0f35ec8d5a3edb4ee1ede962a3c1f6baef0 Konstantin Belousov 2026-03-03 06:37:03

debug: classified in 03-filenames_plain1 by 'sys/amd64/'

acpi: Print sysctl name in deprecated sleep type warning
Reported by:  markj
Fixes:          https://cgit.freebsd.org/src/commit/?id=97d152698f48 ("acpi: Use sleep types defined in sys/power.h")
Event:          AsiaBSDCon 2026
Sponsored by:   The FreeBSD Foundation
66447abae8bb5d2e7b09a72bdea95033d9b1867a Aymeric Wibo 2026-03-21 03:15:03

debug: classified in 03-filenames_plain1 by 'sys/dev/'

acpi_spmc: Simplify constraint freeing
We don't need to check for NULL before calling free().

Sponsored by:   The FreeBSD Foundation
a87bde85232e60771691649fd5718a6de5453e59 Aymeric Wibo 2026-03-21 05:19:21

debug: classified in 03-filenames_plain1 by 'sys/dev/'

amd64: revert back struct trapframe to the pre-FRED definition
Trying to use the grown struct trapframe for IDT case broke in cases
where code supposed that hardware consumed sizeof(struct trapframe) of
the stack space when delivering interrupt or exception.  In particular,
this was broken for #NM/#DB/#MC.  Naive attempt of using IDT-trapframe
size for stack consumption caused later problems with larger C type.

Instead of pretending that IDT event delivery pushed two never-accessed
doubleword to the stack, keep it honest and provide separate type for
the FRED interrupt frame, i.e. struct trapframe_fred.

Convert between trapframe_fred and trapframe can be done by trivial pointer
arithmetic.

Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
1ba29614c4ce5e261ade0bd7def94079b7b9647a Konstantin Belousov 2026-03-21 22:26:48

debug: classified in 03-filenames_plain1 by 'sys/x86/'

hwpstate_amd: Refactor the cpufreq code by using delegation pattenr
We separate the code of CPPC and legacy pstate driver to make it easier
to read.

Reviewed by:    olce
Approved by:    markj (mentor)
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55604
191f47bcd65097599a962b46ae293e5ebe4e5b67 ShengYi Hung 2026-02-24 07:22:52

debug: classified in 03-filenames_plain1 by 'sys/x86/'

Networking

Network-related commands, library, and kernel.

rss_config: Add option to enable rss udp hashing
Added optional system tunable parameter to enable
4-tuple rss udp hashing.

Signed-off-by: bigJ <bigj@solanavibestation.com>
Reviewed by: adrian, pouria
Pull Request: https://github.com/freebsd/freebsd-src/pull/2057
283ef95d1677b873903f8b8fa077fbfa3a5e0036 bigJ 2026-03-01 20:14:49

debug: classified in 03-filenames_plain1 by 'sys/net/'

ifnet: Fix decreasing the vnet interface count
It should be decreased only when the interface has been successfully
removed from the "active" list.

This prevents vnet_if_return() from potential OOB writes to the
allocated memory "pending".

Reviewed by:    kp, pouria
Fixes:          https://cgit.freebsd.org/src/commit/?id=a779388f8bb3 if: Protect V_ifnet in vnet_if_return()
MFC after:      3 days
Differential Revision:  https://reviews.freebsd.org/D55873
8065ff63c0e5c3bb4abb02f55b20cb47bb51d1a7 Zhenlei Huang 2026-03-16 16:20:08

debug: classified in 03-filenames_plain1 by 'sys/net/'

ifnet: Remove unreachable code
The ioctls SIOCSIFVNET and SIOCSIFRVNET are for userland only. For
SIOCSIFVNET, if_vmove_loan(), the interface is obtained from current
VNET. For SIOCSIFRVNET, if_vmove_reclaim(), a valid child prison is
held before getting the interface. In both cases the VNET of the
obtained interfaces is stable, so there's no need to check it.

No functional change intended.

Reviewed by:    glebius, jamie (for #jails)
MFC after:      2 weeks
Differential Revision:  https://reviews.freebsd.org/D55828
e0731059af912a27d0f842959218946b1daaa7d1 Zhenlei Huang 2026-03-16 17:03:05

debug: classified in 03-filenames_plain1 by 'sys/net/'

if_bridge(4): don't sleep under epoch(9) in destruction
bridge tries to run callout_drain(9) twice under epoch
during destruction.
once for bridge_timer, which is not required to be under epoch.
second time for the BSTP callout, which is already disabled
earlier inside bridge_delete_member.

Reviewed by: glebius, zlei
MFC after: 2 weeks
Differential Revision: https://reviews.freebsd.org/D55876
a8b9a05d3cad3bdcb9008232c9172a1aeffbe9fd Pouria Mousavizadeh Tehrani 2026-03-16 12:53:45

debug: classified in 03-filenames_plain1 by 'sys/net/'

ndp: don't send unsolicited NA for multicast address
During link-layer address change event, don't send unsolicited
NA for multicast addresses.

Reviewed by: adrian, zlei
Differential Revision: https://reviews.freebsd.org/D55885
7b9bb32d1cc6779139780baed983129b53a7f36e Pouria Mousavizadeh Tehrani 2026-03-16 20:52:32

debug: classified in 03-filenames_plain1 by 'sys/netinet6/'

in_var.h: fixup comments that mention use by ifmcstat(8)
85cf26c6ee09f0210999881ac3306d333aaea5a3 Gleb Smirnoff 2026-03-18 19:36:07

debug: classified in 03-filenames_plain1 by 'sys/netinet/'

ecn(9): Update ecn tunneling functions to RFC 6040
Update ECN tunneling functions from obsolete RFC 3168 to
newer RFC 6040.
Also, add ECN_COMPLETE to support dangerous packet reporting
without causing extra costs to existing caller functions.
Finally, return values are specified as macro to reduce
confusion, considering extra return values for ECN_WARN
and ECN_ALARM were added.

Reviewed By: glebius, tuexen
Differential Revision: https://reviews.freebsd.org/D53516
32a462ba9cdc8a927c1aba5d9bff9d16d367d7da Pouria Mousavizadeh Tehrani 2026-03-19 10:18:34

debug: classified in 03-filenames_plain1 by '['sys/netinet/', 'sys/netinet6/']'

ndp: Accept multiple queued ND for non-GRAND NAs
Multiple delayed NAs on the same ifa can occur simultaneously.
Therefore:
* Differentiate between GRAND and solicited replies.
* Cancel previous pending GRAND NA for same ifa.
* Reuse ndq memory for GRAND.
* Free non-GRAND replies immediately.
* Don't limit non-GRAND NAs.

Reviewed by: glebius
Differential Revision: https://reviews.freebsd.org/D55905
15ebee7c2ed34d2dad8457d6595010ea4ed7e1f2 Pouria Mousavizadeh Tehrani 2026-03-17 20:09:42

debug: classified in 03-filenames_plain1 by 'sys/netinet6/'

bridge(4): Remove epoch_enter during destruction
bridge doesn't require to enter epoch during destruction.

Reviewed by: zlei, glebius
Differential Revision: https://reviews.freebsd.org/D55935
17920f8335106487968d7928d01b34300756ea00 Pouria Mousavizadeh Tehrani 2026-03-19 11:18:42

debug: classified in 03-filenames_plain1 by 'sys/net/'

ip6_input: Remove unused check for IPv4-compatible IPv6
IPv4-compatible IPv6 addresses are deprecated by RFC 4291.
No functional change intended.

Reviewed by: glebius, emaste
Differential Revision: https://reviews.freebsd.org/D55387
56dddebc55494fdf75eeb914cc9e345d0d762f8c Pouria Mousavizadeh Tehrani 2026-03-19 18:15:10

debug: classified in 03-filenames_plain1 by 'sys/netinet6/'

tcp: remove extraneous code
The tcp_close() will perform both actions.

Reviewed by:            pouria, tuexen, rrs
Differential Revision:  https://reviews.freebsd.org/D55965
0798ad802350d449641fb91409860f5c12045581 Gleb Smirnoff 2026-03-20 16:54:54

debug: classified in 03-filenames_plain1 by 'sys/netinet/'

tcp/rack: don't call call tcp_state_change() before tcp_close()
Reviewed by:          tuexen, rrs
Differential Revision:  https://reviews.freebsd.org/D55969
03b7b779a80557fe769bc00e1b06f4d116df958a Gleb Smirnoff 2026-03-20 16:55:04

debug: classified in 03-filenames_plain1 by 'sys/netinet/'

System administration

Stuff in man section 8 (other than networking).

pmcstat: Implement PMC_CAP_SYSWIDE
Implement the PMC_CAP_SYSWIDE capability flag in the same manner as the
PMC_CAP_DOMWIDE flag.  This flag was previously introduced along side
the domain wide flag, but is yet to be used anywhere.

Reviewed by:    mhorne
Sponsored by:   Netflix
Pull Request:   https://github.com/freebsd/freebsd-src/pull/2075
209d9fbe50c181701bafb16a16dca8c959bbe8ae Ali Mashtizadeh 2026-03-16 23:39:15

debug: classified in 04-filenames_plain2 by 'usr.sbin/'

ifmcstat: remove libkvm(3) code
It has been broken and disabled for over 10 years.  Remove mentions of the
kvm(3) from the manual page.
ad0e698e642e46ba6f1f25d9a151e8e975ec6356 Gleb Smirnoff 2026-03-18 19:30:14

debug: classified in 04-filenames_plain2 by 'usr.sbin/'

nanobsd: embedded: Calculate FAT type and scheme
Determine the FAT (MS-DOS) type (FAT32, FAT16, or FAT12) and partition
scheme (fat32lba or fat16b) based on partition size.

Accept any (NetBSD) strsuftoll(3)-compatible string, as the value will
be fed to makefs(8) "-s" in a future commit.

NANO_SLICE_FAT_SIZEs defined in sectors (ending with an "s") will not be
supported.  As a workaround, the letter "b" (blocks) may be used.

Reviewed by:    imp
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D54975
68f5e5b1244d1285f0ec5ea3f88ff63f2c9554dd Jose Luis Duran 2026-03-19 17:12:26

debug: classified in 05-summary-prefix by 'nanobsd:'

nanobsd: embedded: Remove mtools dependency
Rely on makefs -t msdos to create the MS-DOS partition and remove the
dependency on filesystems/mtools.

Note that NANO_SLICE_FAT_SIZEs defined in sectors (ending with an "s")
are no longer supported, as a workaround the letter "b" (blocks) may be
used instead.

Reviewed by:    imp
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D54976
5de9a54c76cf4ce423685531f3d9ec256a31b1b6 Jose Luis Duran 2026-03-19 17:12:51

debug: classified in 05-summary-prefix by 'nanobsd:'

Commit group #0: nanobsd
nanobsd: embedded: Fix more regressions from last cleanup

Commit c99bb5747f5e changed "()" grouping into "{}", but in these cases
we chdir and depended on the subshell not changing the directory for the
caller.  Restore the old behavior.  While things appear to work without
this change, the previous code was intentionally structured this way.

Reviewed by:    imp
Fixes:          https://cgit.freebsd.org/src/commit/?id=c99bb5747f5e ("nanobsd: minor formatting cleanup")
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D54978
60f8d36f7eedf397a8ec21ce58cb33a26f1aa4fc Jose Luis Duran 2026-03-19 17:13:59

debug: classified in 05-summary-prefix by 'nanobsd:'


nanobsd: Minor cleanup

No functional change intended.

Reviewed by:    imp
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D54979
5902c1834d82737137152eeaf8b60f1cd6652fad Jose Luis Duran 2026-03-19 17:14:24

debug: classified in 05-summary-prefix by 'nanobsd:'


nanobsd: embedded: Time stamp the code image

While there is a function nano_makefs() that already takes care of this
issue, we are not yet ready to consume it.

Just add the time stamp and FFS options to makefs.  This is done
primarily to use UFS2 (UFS version 2).  If the user needs further
customization, the variable NANO_MAKEFS can be overridden.  Timestamping
takes care of making the images bit-for-bit identical.

Reviewed by:    imp
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D54980
894992e7860596ce27961771fc00e52812da91f1 Jose Luis Duran 2026-03-19 17:14:36

debug: classified in 05-summary-prefix by 'nanobsd:'

"Pending" is more correct than "Missing"
Pointed out by: Alex "the PS/2 guy"
a0170dbd4e1abba2b1975ebb37f6051a936c7f9a Poul-Henning Kamp 2026-03-20 10:32:30

debug: classified in 03-filenames_plain1 by 'sbin/'

loader(8): embedded MD should be the most preferred currdev
A loader built with MD_IMAGE_SIZE is almost always meant for use with
its embedded image and should try that as currdev before anything else.
Recent changes (d69fc3a9dc71, 784150fd2535) seem to have relaxed the ZFS
code's search for a rootfs and exposed this problem.

Reviewed by:    imp, tsoome
MFC after:      1 week
Sponsored by:   Chelsio Communications
Differential Revision:  https://reviews.freebsd.org/D55979
0661997cea165e951e4e215e6aed41596d8b1d52 Navdeep Parhar 2026-03-20 00:39:17

debug: classified in 03-filenames_plain1 by 'stand/'

newfs: Don't combine GEOM journaling with SU
GEOM journaling shouldn't be used at the same time as soft updates, so
don't enable soft updates if GEOM journaling has been requested, and
error out if both are explicitly requested.

MFC after:      1 week
PR:             https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=293896
Reviewed by:    mckusick
Differential Revision:  https://reviews.freebsd.org/D55999
e30fcdaae2e68458da83d5420e6034c5f384e5f2 Dag-Erling Smørgrav 2026-03-21 07:21:28

debug: classified in 03-filenames_plain1 by 'sbin/'

tunefs: Don't combine GEOM journaling with SU
GEOM journaling shouldn't be used at the same time as soft updates, so
don't enable one if the other is already in use.

MFC after:      1 week
PR:             https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=293896
Reviewed by:    mckusick
Differential Revision:  https://reviews.freebsd.org/D56002
b1f72dd2a9a5e69a310b9e76b55f16cff433b8da Dag-Erling Smørgrav 2026-03-21 07:21:33

debug: classified in 03-filenames_plain1 by 'sbin/'

pfctl: parser must not ignore error from pfctl_optimize_ruleset()
Ignoring the error may cause pfctl(8) to load inconsistent ruleset
preventing pf(4) to enforce desired policy.

Issue reported and fix suggested by berts _from_ fastmail _dot_ com

'Looks good.' @deraadt

MFC after:      1 week
Obtained from:  OpenBSD, sashan <sashan@openbsd.org>, 9fd28a8cca
Sponsored by:   Rubicon Communications, LLC ("Netgate")
343ace42f82a629374af4dc3a72da5f46f2c3feb Kristof Provost 2026-03-22 02:50:47

debug: classified in 03-filenames_plain1 by 'sbin/'

Libraries

realpath: Improve prev_len logic
* Save prev_len after having checked for and appended a trailing slash,
  not before.  This requires us to back up if we end up returning a
  partial result, but previously we would sometimes return a partial
  result with a trailing slash and sometimes without.

* Replace strlcat() with a faster strlcpy() since we know exactly how
  far into the buffer we are.

MFC after:      1 week
Sponsored by:   Klara, Inc.
Reviewed by:    kevans
Differential Revision:  https://reviews.freebsd.org/D55914
99d295e471bc362a7927047c89472e1ee2d0da6b Dag-Erling Smørgrav 2026-03-19 01:26:16

debug: classified in 04-filenames_plain2 by 'lib/'

Filesystems

nfs_nfsdserv.c: Fix handling of archive flag for mkdir
An NFSv4.1/4.2 client can set/clear the archive, hidden
and system flags when creating non-regular files, such
as directories.

Without this patch, the setting of va_flags causes an
EPERM failure, since they are specified for VOP_MKDIR(),
VOP_MKNOD() and VOP_SYMLINK().

This patch sets va_flags == VNOVAL for the above VOP_xxx()
calls and then sets/clears the flags after creation,
which fixes the problem.

This bug only affects the Windows NFSv4.1/4.2 client.

PR:     https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=293691
Tested by:      Dan Shelton <dan.f.shelton@gmail.com>
MFC after:      2 weeks
6580d040861dfbf6c630a93cbf41f2a2c7e7b327 Rick Macklem 2026-03-16 23:22:37

debug: classified in 03-filenames_plain1 by 'sys/fs/'

zfs: merge openzfs/zfs@3ee08abd2
Notable upstream pull request merges:
 #17000 -multiple cmd/zfs: support creating parents with canmount=no
 #17926 b481a8bbb Make zpool status dedup table support raw bytes -p output
 #18238 -multiple Report space metrics per allocation class
 #18240 5dad9459d Add --no-preserve-encryption flag
 #18257 1eace5906 libzfs: use mount_setattr for selective remount including
                  legacy mounts
 #18259 1e2c94a04 More consistent use of TREE_* macros in AVL comparators
 #18262 c58b8b7dc Fix check for .cfi_negate_ra_state on aarch64
 #18264 f109c7bb9 Add the --file-layout (-f) option to zdb(8)
 #18268 304de7f19 libzfs: handle EDOM error in zpool_create
 #18275 753f1e1e2 zstream: add a drop_record subcommand
 #18276 0f90a797d Fix vdev_rebuild_range() tx commit
 #18277 1e1d64d66 Fix log vdev removal issues
 #18278 06b0abfe6 Fix the send --exclude option to work with encryption
 #18281 e73ada771 libzpool: lift zfs_file ops out to separate source file
 #18284 d97945776 zstream: consolidate shared code
 #18285 -multiple Separate SIMD compile checks for userspace and kernel
 #18288 c5905b2cb Implement lzc_send_progress
 #18289 -multiple L2ARC: Add depth cap and write budget fairness for
                  persistent markers
 #18290 d45c8d648 FreeBSD: Improve dmesg kernel message prefix
 #18294 b403040c4 draid: fix data corruption after disk clear
 #18296 -multiple libzfs: mnttab cleanup
 #18300 d35951b18 zpool clear: remove undocumented rewind flags
 #18301 ae7fcd5f9 fix libzfs diff mem leak in an error path
 #18303 65165df12 zilstat: add man page
 #18314 7f65e04ab libzfs: scrub: only include start and end nv pairs if
                  needed for scrub
 #18315 -multiple Sync ZVOLs block cloning conditions with file systems
 #18330 f80338fac zarcsummary: add man page
 #18337 f259a47c7 zpool-iostat.8: clarify first report shows per-second
                  averages

Obtained from:  OpenZFS
OpenZFS commit: 3ee08abd2fcef3123188e9ad61a9cd80b9b7831c
80aae8a3f8aa70712930664572be9e6885dc0be7 Martin Matuska 2026-03-19 20:25:34

debug: classified in 05-summary-prefix by 'zfs:'

Kernel

Kernel stuff (other than networking, filesystems, and drivers).

queue.h: Reorder STAILQ_INSERT_TAIL
The current implementation briefly violates the tail invariant.  This
is not usually an issue, but if an insert is in flight when a panic
occurs, we may then trip the invariant while dumping core.

MFC after:      1 week
Sponsored by:   Klara, Inc.
Sponsored by:   NetApp, Inc.
Reviewed by:    obiwac, olce, jhb
Differential Revision:  https://reviews.freebsd.org/D55819
aa15df4597053c0e95a15b2a7036296999cd562a Dag-Erling Smørgrav 2026-03-16 20:36:56

debug: classified in 04-filenames_plain2 by 'sys/'

vm_fault: expand KASSERT message in vm_fault_populate_cleanup
Include index values and object pointer in the diagnostic
to improve debugging of pindex mismatches.

No functional change.

Signed-off-by: Isa Isoux <isa@isoux.org>
Reviewed by: kib, pouria
Pull Request: https://github.com/freebsd/freebsd-src/pull/2038
83d7a4966f08f34a699da649bd4f714b450df39b isoux 2026-02-20 19:54:35

debug: classified in 04-filenames_plain2 by 'sys/'

LinuxKPI: Clear the sbuf at the start of each call to seq_read
Each invocation of seq_read invokes the seq_file.show callback which
writes into the sbuf.  Then it invokes sbuf_finish before copying the
data into the caller's buffer.  Without this, a second call to
seq_read on the same file would try to append data to a finished sbuf.

Reviewed by:    bz
Sponsored by:   AFRL, DARPA
c181c8f5ca707962359e636ca5aa536e60147eee John Baldwin 2026-03-17 16:05:17

debug: classified in 04-filenames_plain2 by 'sys/'

LinuxKPI: Use simple_read_from_buffer in simple_attr_read and seq_read
Reviewed by:  bz
Sponsored by:   AFRL, DARPA
Differential Revision:  https://reviews.freebsd.org/D55879
58d74d7b0ca9bdf3aacfbe014bd00387f87b9be0 John Baldwin 2026-03-17 16:05:30

debug: classified in 04-filenames_plain2 by 'sys/'

lindebugfs: Pass user buffer pointers to the read/write file operations
The Linux file_operations API expects the read and write operations
to take a single user buffer pointer (along with the length and the
file offset as an in/out parameter).

However, the debugfs_fill function was violating this part of the
contract as it was passing down kernel pointers instead.  An earlier
commit (5668c22a13c6befa9b8486387d38457c40ce7af4) hacked around this
by modifying simple_read_from_buffer() to treat its user pointer
argument as a kernel pointer instead.  However, other commits keep
tripping over this same API mismatch
(e.g. 78e25e65bf381303c8bdac9a713ab7b26a854b8c passes a kernel pointer
to copy_from_user in fops_str_write).

Instead, change debugfs_fill to use the "raw" pseudofs mode where the
uio is passed down to directly to the fill callback rather than an
sbuf.  debufs_fill now iterates over the iovec in the uio similar to
the implementation of uiomove invoking the read or write operation on
each user pointer.

This also fixes a tiny bug where the initial file offset from
uio_offset was ignored.  Instead, the operations were always invoked
with a file offset of 0.

As part of this, revert the the changes to simple_read_from_buffer()
from commit 5668c22a13c6befa9b8486387d38457c40ce7af4.

Also as part of this, the simple_attr_read/write methods and seq_read
now also need to accept and handle user pointers (also matching the
API in Linux).

For simple_attr_write*(), copy the user buffer into a kernel buffer
before parsing.  Also, do not permit writes at an offset as it's
unclear what the semantics for those would even be (perhaps you would
write out the formatted value into a buffer first and then allow the
copy_from_user to overwrite/extend that buffer and then re-parse the
integer value?).  The old handling of *ppos for writes was definitely
wrong before and only worked for an offset of 0 anyway.

Reviewed by:    bz
Sponsored by:   AFRL, DARPA
Differential Revision:  https://reviews.freebsd.org/D55833
2cf15144daf7ec44cdcd9bf3ef007939b79c361e John Baldwin 2026-03-17 19:45:34

debug: classified in 04-filenames_plain2 by 'sys/'

LinuxKPI: Fix simple_read_from_buffer for zero-size and off-the-end reads
I noticed that the buf_size < 0 check can never be true (it's a
size_t) and decided to check for this condition by an alternate
expression, and I also noticed that a read_size of 0 would incorrectly
return -EFAULT.  Instead, return success for both of these cases as
reading beyond the EOF of a normal file also returns EOF, not EINVAL.

Reviewed by:    bz
Sponsored by:   AFRL, DARPA
Differential Revision:  https://reviews.freebsd.org/D55845
2353fa1aca553883141a7b5d0aa54312a4610412 John Baldwin 2026-03-17 19:49:01

debug: classified in 04-filenames_plain2 by 'sys/'

Delete error-check code that can never happen.
Near the top of kern_mmap() that implements the mmap(2) system call,
it sets

        prot = PROT_EXTRACT(prot);

with

So prot can only be the three PROT_ flags.

The following test of the user's mmap(2) parameters (near line 275
in vm/vm_mmap.c):

        if (prot != PROT_NONE &&
            (prot & ~(PROT_READ | PROT_WRITE | PROT_EXEC)) != 0) {
                return (EXTERROR(EINVAL, "invalid prot %#jx", prot));
        }

can never fail. This commit deletes it.

No functional change intended.

Reviewed by:  kib
MFC-after:    1 week
Sponsored by: Netflix
51446d33c6fbc27ce21f54ebb4c27caace48c3be Kirk McKusick 2026-03-19 00:45:23

debug: classified in 04-filenames_plain2 by 'sys/'

Provide more precise error explanations for mmap(2) EINVAL errors.
Reviewed by:  kib
Differential Revision: https://reviews.freebsd.org/D55888
MFC-after:    1 week
Sponsored by: Netflix
dad6e6fc1ea4b737e9f1661ebd30da5d551e3d4a Kirk McKusick 2026-03-19 00:52:10

debug: classified in 04-filenames_plain2 by 'sys/'

timerfd: Fix interval callout scheduling
When a timerfd interval callout misses its scheduled activation time, a
differential is calculated based on the actual activation time and the
scheduled activation time. This differential is divided by the timerfd's
interval time and the quotient is added to the timerfd's counter.

Before this change, the next callout was scheduled to activate at:
scheduled activation time + timerfd interval.

This change fixes the scheduling of the next callout to activate at:
actual activation time + timerfd interval - remainder.

Reviewed by:            markj
Differential Revision:  https://reviews.freebsd.org/D55790
MFC after:              2 weeks
85c0f1a87da1fd1eb3e646e86f70e630c48da91a Jake Freeland 2026-03-20 06:33:03

debug: classified in 04-filenames_plain2 by 'sys/'

sys/time: Add saturating sbt conversions
When converting from timespec to sbintime, the timespec's 64-bit tv_sec
component is shifted to the left 32 bits, causing any information in the
upper 32 bits to be lost.

This data loss during conversion can turn timespecs with very large
tv_sec counters into sbintimes that represent much smaller time
durations.

Add tstosbt_sat() and tvtosbt_sat(), which are saturating versions of
tstosbt and tvtosbt. With these routines, any overflow resulting from
the conversion is clamped to [-SBT_MAX - 1, SBT_MAX].

Reviewed by:            imp, markj
Differential Revision:  https://reviews.freebsd.org/D55791
MFC after:              2 weeks
e3799530b3ba38567f8052b9e107884609fc71ea Jake Freeland 2026-03-20 06:33:20

debug: classified in 04-filenames_plain2 by 'sys/'

Commit group #1: timerfd
timerfd: Use saturating sbintime conversions

Some timerfd consumers set expirations with timespec tv_sec components
larger than 2^31 - 1. In such cases, converting that timespec to
sbintime results in data loss or sign flip, yielding a shorter
expiration than desired.

To avoid this problem, use saturating timespec-to-sbintime conversion
functions. These will clamp the converted sbintime to SBT_MAX under
circumstances where the normal conversion functions would overflow.

Saturating conversions still result in data loss, but the consequences
are less severe, causing problems only after SBT_MAX (~68 years) of
system uptime elapses.

Reviewed by:            imp
Differential Revision:  https://reviews.freebsd.org/D55792
MFC after:              2 weeks
0e8f351be7935729bf67dc1b7aa4d178cf154931 Jake Freeland 2026-03-20 06:33:38

debug: classified in 04-filenames_plain2 by 'sys/'


timerfd: Wake up on discontinuous jump

If a discontinous realtime clock change occurs and sets any TFD_JUMPED
bits on the timerfd, then wake up waiting readers. This fixes failures
from the timerfd_root__clock_change_notification test case.

MFC after: 2 weeks
b11fba41265ae132acfb05587a6dbf60334d3279 Jake Freeland 2026-03-20 06:33:54

debug: classified in 04-filenames_plain2 by 'sys/'


timerfd: Suppress kqueue readability after jump read

Do not report EVFILT_READ after reading a discontinuous clock jump.
This makes the kqueue filter consistent with Linux epoll behavior
and timerfd_poll(), which already checks tfd_jumped != TFD_READ before
reporting POLLIN.

MFC after: 2 weeks
33345b8834859cf1ad7f1256f3a34b4a7c83e8e8 Jake Freeland 2026-03-20 06:34:15

debug: classified in 04-filenames_plain2 by 'sys/'

cam (scsi): silence "Medium not present" SCSI sense logging for removable media
Change SS_FATAL to SS_FAIL for SCSI sense code 0x3A (Medium not present)
to suppress console spam when card readers or other removable media
devices have no media inserted.

The error is still returned to callers (ENXIO), but no longer prints to
dmesg during boot/probe.

Verified with Apple SD Card Reader - reduced boot messages from 4 to 2.

Reviewed by:    emaste, imp
Differential Revision: https://reviews.freebsd.org/D55287
3d218b6289cf4675abdeef17a4489e71f8e1935e Abdelkader Boudih 2026-03-20 15:28:42

debug: classified in 04-filenames_plain2 by 'sys/'

sys/param.h: bump __FreeBSD_version for amd64 struct trapframe size change
Requested by: jhb
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
6275cd73aca7f31cbb3b9da2d031f6664814d58c Konstantin Belousov 2026-03-19 16:03:14

debug: classified in 04-filenames_plain2 by 'sys/'

kernel: Be clearer about what ZSTDIO is for
ZSTDIO is not just for core dumps, and it is now required by ZFS, so
move it (and GZIO, which is still just for dumps) to a new “Compression
support” section in GENERIC, and add them both to MINIMAL.

MFC after:      1 week
Reviewed by:    imp
Differential Revision:  https://reviews.freebsd.org/D55940
092687a031064dc08ac198648c6393cc50b06cee Dag-Erling Smørgrav 2026-03-21 07:21:24

debug: classified in 04-filenames_plain2 by 'sys/'

sbuf: make assertion message a lot more useable
Saying that we are called with an (un)finished or corrupted sbuf
is like saying "error" (though [un]finished is an extra hint).

Add the pointer to the sbuf so one could easily check it,
add the flags we are checking so one could see quickly about
a possible state mismatch.

Given we already dereference the pointer in the KASSERT there is no
extra harm adding it to the message.

Found while:    testing lindebugfs changes
Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
Reviewed by:    jhb
Differential Revision: https://reviews.freebsd.org/D55919
2ce06d25431a6c96ef5719165cb73e138a0ed89c Bjoern A. Zeeb 2026-03-18 14:43:15

debug: classified in 04-filenames_plain2 by 'sys/'

LinuxKPI: add supporting #includes
Compiling drm-kmod on !X86 does not include asm/smp.h which includes
preempt.h on FreeBSD.  In order to compile drm-kmod on other
architectures add the secondary #includes for preempt.h to
spinlock.h and hardirq.h (which now also gets included from highmem.h)
to connect the #include chain.

Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
PR:             https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=279864
Reviewed by:    jhibbits, emaste
Differential Revision: https://reviews.freebsd.org/D55974
1d18872c2519d7ca726ddc49735180ab1d8916e0 Bjoern A. Zeeb 2026-03-19 20:29:29

debug: classified in 04-filenames_plain2 by 'sys/'

Build system

Commit group #2: ecn.9: Add ecn(9) manual
ecn.9: Add ecn(9) manual

Add ecn manual for ip_ecn tunneling functions.

Reviewed by: pauamma_gundo.com, tuexen
Differential Revision: https://reviews.freebsd.org/D53517
ba4298b055642969d30389c5c92dd4d61a124fb6 Pouria Mousavizadeh Tehrani 2026-03-19 10:25:53

debug: classified in 02-filenames_wildcards by '.*Makefile'


ecn.9: Replace non-ASCII characters

Reported by:    maxim
Fixes:          https://cgit.freebsd.org/src/commit/?id=ba4298b05564 ("ecn.9: Add ecn(9) manual")
1c1b494264fad5718e39b9cfaafe4f9626ee885b Pouria Mousavizadeh Tehrani 2026-03-19 17:20:47

debug: classified in 02-filenames_wildcards by '.*\.[1-9]'

debug: moved to build because 'Need to be grouped with ba4298b055642969d30389c5c92dd4d61a124fb6'

ath11k: update module Makefile after vendor import of v6.19[-rc6]
Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
09cacabd8ca0cc89c8d46b2f4c1dcdd6bb1e1cab Bjoern A. Zeeb 2026-03-12 20:24:39

debug: classified in 02-filenames_wildcards by '.*Makefile'

ath12k: update module Makefile after vendor import of v6.19
Sponsored by: The FreeBSD Foundation
MFC after:      3 days
03ba27c194ca5937478502cb52a0eda8146f9be1 Bjoern A. Zeeb 2026-03-12 15:47:55

debug: classified in 02-filenames_wildcards by '.*Makefile'

pkg-serve(8): serve pkg repositories over TCP via inetd (8)
Reviewed by:  manu, bdrewery (previous version)
Differential Revision:  https://reviews.freebsd.org/D55895
b42e852e89cb04cceb6e0226d6a08cab13fb6e90 Baptiste Daroussin 2026-03-17 11:02:28

debug: Commit manually moved from "unknown" to "build".

build: Boostrap LLVM_BINUTILS for cross-tools
Reported by:  vexeduxr, jrtc27
Reviewed by:    imp
Sponsored by:   The FreeBSD Foundation
Pull request:   https://github.com/freebsd/freebsd-src/pull/2084
Differential Revision: https://reviews.freebsd.org/D55923
17494c6e6b7d5e2be34d2469566a59bbd9dceb8a Ed Maste 2026-03-18 15:09:53

debug: classified in 03-filenames_plain1 by '['Makefile', 'share/mk/', 'tools/build/']'

dwcotg.4: Initial manual page
Create visibility in apropos and the Hardware Release Notes.

MFC after:              3 days
Reviewed by:            pauamma, ray
Differential Revision:  https://reviews.freebsd.org/D53287
8475cd93fb6db65a02afe435f16306bc18e96ec9 Alexander Ziaee 2026-03-20 14:42:33

debug: classified in 02-filenames_wildcards by '.*Makefile'

krb5: append to LDFLAGS instead of replacing
Sponsored by: Netflix
Reviewed by:    imp
Differential Revision:  https://reviews.freebsd.org/D55335
632ddb864ee89c275ff5f8f9079522dec33c0d3c Chuck Silvers 2026-03-20 17:19:35

debug: classified in 02-filenames_wildcards by '.*Makefile'

Makefile.inc1: Don't force LLVM_BINUTILS off for cross-tools
Because of this setting we were still using ELF Tool Chain tools for
buildworld.  The sets of binary utilities are largely equivalent and
this went unnoticed after commit 1cae7121c667 ("Enable LLVM_BINUTILS
by default").

This was discovered recently because ELF Tool Chain objcopy produces
standalone debug files without phdrs and this caused an issue with a
3rd party ELF parser [1].  Remove the forced setting so that we use
LLVM's binutils to build the system.

[1] https://sourceware.org/bugzilla/show_bug.cgi?id=33876

Re-commit after fixing a bootstrapping issue with LLVM binutils (in
17494c6e6b7d "build: Boostrap LLVM_BINUTILS for cross-tools").

Reviewed by:    imp, jhb
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55650
e296211fd59b6e4e0df38281a6d587b7d025f011 Ed Maste 2026-03-04 15:06:26

debug: classified in 02-filenames_wildcards by '.*Makefile'

EC2: Add clibs-lib32 pkg to small/builder images
The FreeBSD-clang package on amd64 contains libclang_rt.asan-i386.so,
which links to the 32-bit version of libgcc_s.so.1.  It is not clear
if that file belongs in FreeBSD-clang or if it should be placed into
a different package.

For unknown reasons, pkg *sometimes* recognizes this and decides that
it needs to install a package to supply libgcc_s.so.1:32.

In particular, when we initially install the VM with 'pkg install
[long list of FreeBSD-* packages]', pkg does not recognize that it
wants this; but the *next* time 'pkg install' runs, it decides that
it needs libgcc_s.so.1:32 -- even though that particular library is
not needed by the particular package we're trying to install -- and
goes looking for it... and ends up picking gcc12-devel as a provider.

Later in the EC2 image building process, we run 'pkg autoremove' (which
was added during 15.0 to get rid of the "bogus dependencies" which were
added while installing other packages) and pkg is once again confused:
It decides that gcc12-devel is an automatic port which is not required
by anything else, but upon determining that it should be removed it
then determines that FreeBSD-clang depends upon a port which is being
removed and deletes FreeBSD-clang as well.

It's not clear what is breaking in pkg, but as a temporary workaround
add the FreeBSD-clibs-lib32 package to the "small" and "builder" EC2
image flavours in order to satisfy the libgcc_s.so.1 demand.

This commit should be reverted if libclang_rt.asan-i386.so moves out
of FreeBSD-clang, (i.e. if it becomes possible to install a 32-bit-free
amd64 system) or when the pkg issue is resolved (i.e. pkg consistently
recognizes the shared library dependency and installs clibs-lib32
automatically as a FreeBSD-clang dependency).

MFC after:      3 days
Sponsored by:   Amazon
Differential Revision:  https://reviews.freebsd.org/D55978
cfe0b7d37e552d78762c029f5b15e0f36d9d0d38 Colin Percival 2026-03-20 00:24:55

debug: classified in 02-filenames_wildcards by 'release/.*'

EC2: Remove stale comment
MFC after:    3 days
Sponsored by:   Amazon
118699732de1ec99b06d5d73ee61b1b74842c1de Colin Percival 2026-03-21 16:06:37

debug: classified in 02-filenames_wildcards by 'release/.*'

release.sh: document user-overriddable functions
This helps others attempting to customize the behavior of `release.sh`.

MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D55450 (as part of a larger change)
b24fc79095c640620a643a11fa2f4f833326bfed Enji Cooper 2026-03-22 02:45:57

debug: classified in 02-filenames_wildcards by 'release/.*'

release.sh: add chroot cleanup routine
The chroot_cleanup routine handles any cleanup needed post-chroot_setup,
etc. This consists of purely tearing down `${CHROOTDIR}/dev` today, but
might involve additional steps, as needed for custom functions. This
allows end-users to override the various chroot functions without having
to modify code in main() or replicate the unmount procedure in an
equivalent routine setup via the trap builtin.

This change modifies the /dev unmount process to use `umount -f` instead
of `umount`. The latter can result in failures if resources are still
mounted or are running post-build, whereas the former will clean up any
resources still in use by processes running in the chroot at time of
build. Moreover, the `chroot_cleanup` routine is now called when the
script is killed with `SIGINT` and `SIGTERM`, as well as at `EXIT`,
better ensuring that the script's resources are cleaned up in relatively common
scenarios that can be detected/handled.

MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D55450 (as part of a larger change)
60baee1fa4848ac969522e03d2c6f273f334edb7 Enji Cooper 2026-03-22 02:57:25

debug: classified in 02-filenames_wildcards by 'release/.*'

Internal organizational stuff

-- no commits in this category this week --

Testing

Commit group #3: tests/netinet: provide test for raw_ip.c:rip_input()
tests/netinet: provide test for raw_ip.c:rip_input()

The test creates differently bound SOCK_RAW sockets and sends different
probe packets.  There is expected results matrix that every probe is
checked against.
c1481c9f4a425db7295332be87f837bfb7d127df Gleb Smirnoff 2026-03-17 22:15:43

debug: classified in 02b-filenames_wildcards2 by 'tests\/.*'


tests/netinet/raw: fix ssize_t printf(3) format

Fixes:  https://cgit.freebsd.org/src/commit/?id=c1481c9f4a425db7295332be87f837bfb7d127df
cc6672235c3bbd12fd6006934ba328c5a85f2c3c Gleb Smirnoff 2026-03-18 18:51:42

debug: classified in 02b-filenames_wildcards2 by 'tests\/.*'

timerfd: Add tests
Take Jan Kokemuller's timerfd tests from the epoll-shim project,
stripping out code that isn't directly related to FreeBSD.

Reviewed by:            markj
Differential Revision:  https://reviews.freebsd.org/D55789
MFC after:              2 weeks
834c1ba793d900b791e19ff449b1e0b96fb494a0 Jake Freeland 2026-03-20 06:31:30

debug: classified in 02b-filenames_wildcards2 by 'tests\/.*'

libc: Fix cxa_thread_atexit{,nothr} test.
After patch 9d26b82, we don't provide recursive call protection anymore.
Therefore, to pass the test, we adjust the testcase by protecting on
caller and the testcase is to make sure the dtors is properly handled.

Reported by:    siva
Reviewed by:    kib
Approved by:    markj (mentor)
Fixes:  https://cgit.freebsd.org/src/commit/?id=9d26b82826d9 ("libc: Fix dtor order in __cxa_thread_atexit")
MFC after:      2 weeks
Sponsored by:   The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55893
c25976f0a9a3a102ce47b45c19b2c93e8069433b ShengYi Hung 2026-03-17 14:53:08

debug: classified in 03-filenames_plain1 by 'lib/libc/tests/'

pf tests: verify first-match-wins for nat rules
Sponsored by: Orange Business Services
0b0d34fd2f40e06e4600441b15b26b1cc1941c9f Kristof Provost 2026-03-20 03:16:57

debug: classified in 02b-filenames_wildcards2 by 'tests\/.*'

pfctl tests: test rdr-to and nat-to in one rule
OpenBSD fixed this separately (in their 6a338f3f70). We appear to not
have had this bug, but test for it anyway.

Sponsored by:   Rubicon Communications, LLC ("Netgate")
434e1c3d84135d1c3a6e578fdfa4b508f0914494 Kristof Provost 2026-03-22 06:20:48

debug: classified in 02b-filenames_wildcards2 by 'sbin/.*/tests/.*'

Style, typos, and comments

These could go in other categories, but it's more clear if they're here instead.

crypto_request.9: Fix typo on crypto_initreq arguments
The function signature of `crypto_initreq()` was
incorrectly documented.

Signed-off-by:  Zixu Wu <zx@bv3.dev>
Reviewed by:    ziaee, pouria
Pull Request:   https://github.com/freebsd/freebsd-src/pull/2077
fed90174ff5eb8dd46c521c67ea0b387f150683b zxbv3 2026-03-15 16:35:30

debug: classified in 01-style by '[tT]ypo'

nanobsd: embedded: Remove stray comment
Remove an outdated comment about NanoBSD not being able to remove the
firstboot sentinel file.

It was fixed in cb51e2bc3db7 ("rc: Allow the removal of
firstboot_sentinel on read-only file systems").

Reviewed by:    imp
MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D54977
21970f278028464f053fa15d45321cfa727c488a Jose Luis Duran 2026-03-19 17:13:29

debug: classified in 01-style by '[rR]emove stray'

Contrib code

tcpdump: Update to 4.99.6
e6083790f217ba7f89cd2957922bd45e35466359 Joseph Mingrone 2026-03-16 02:22:18

debug: Commit manually moved from "unknown" to "contrib".

ath11k: update Atheros/QCA's ath11k driver
This version is based on
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
24d479d26b25bce5faea3ddd9fa8f3a6c3129ea7 ( tag: v6.19-rc6 ).

Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
187d8a3ce55a4e2d41fbe61465d5ff4ac0fc6bd5 Bjoern A. Zeeb 2026-03-19 23:30:11

debug: classified in 03-filenames_plain1 by 'sys/contrib'

Commit group #4: ath12k: update Atheros/QCA's ath12k driver
ath12k: update Atheros/QCA's ath12k driver

This version is based on
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
05f7e89ab9731565d8a62e3b5d1ec206485eeb0b ( tag: v6.19 ).

Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
a96550206e4bde15bf615ff2127b80404a7ec41f Bjoern A. Zeeb 2026-03-19 23:33:40

debug: classified in 03-filenames_plain1 by 'sys/contrib'


ath11k: restore module Makefile

During the subtree merge and checking out the updated version of ath12k
parts of the previous ath11k merge were accidentally undone.
Retore the ath11k Makefile as well after 3c4eef5d838b restored the
driver bits.

Fixes:          https://cgit.freebsd.org/src/commit/?id=a96550206e4b ("ath12k: update Atheros/QCA's ath12k ..")
Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
f9795615415074b23faf8e5d937c2ef31045d3d0 Bjoern A. Zeeb 2026-03-20 00:17:41

debug: classified in 02-filenames_wildcards by '.*Makefile'

debug: moved to contrib because 'Need to be grouped with a96550206e4bde15bf615ff2127b80404a7ec41f'

ath11k: reduce diff to upstream Atheros/QCA's ath11k driver
It seems that over the time of merging and only partly working
on making it compile again a few mis-merges happened.
Reduce diff to the v6.19 upstream version so that we only have
additions to the driver (usually guarded by #ifdef __FreeBSD__).

Sponsored by:   The FreeBSD Foundation
MFC after:      3 days
3c4eef5d838b906e8dc30e29ca98b2c4025e2bb2 Bjoern A. Zeeb 2026-03-19 23:54:21

debug: classified in 03-filenames_plain1 by 'sys/contrib'

Reverted commits

Commit group #5: revert-pair-libcrypto
libcrypto: compile all PIC objects with -DOPENSSL_PIC

This change modifies the libcrypto PIC objects to always compile with
`-DOPENSSL_PIC` to restore parity with the upstream build process. This
ensures that `-DOPENSSL_PIC` is used whenever building the auxiliary
shared objects. In this case, just the legacy provider (we no longer
distribute the fips provider).

MFC after:              2 weeks
Differential Revision:  https://reviews.freebsd.org/D44896
14b9955e57cc28b61e785165b9effcbe620edb46 Enji Cooper 2026-03-19 23:56:41

debug: classified in 00-reverts by 'This reverts commit \b([0-9a-fA-F]{40})\b'


Revert "libcrypto: compile all PIC objects with -DOPENSSL_PIC"

This commit broke the build with some build options.

Some validation needs to be done to confirm that moving the preprocessor
argument to `secure/lib/libcrypto/Makefile.inc` works without breaking
the build, but revert for now until a `tinderbox` run can be done with
the change.

PR:             https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=293934
Reported by:    Jenkins, Trond Endrestøl

This reverts commit 14b9955e57cc28b61e785165b9effcbe620edb46.
67b918e03475e780854a43fe4eb7c8e95f4deb29 Enji Cooper 2026-03-20 20:08:09

debug: classified in 00-reverts by 'This reverts commit \b([0-9a-fA-F]{40})\b'


libcrypto: compile all PIC objects with -DOPENSSL_PIC -fPIC

This change modifies the libcrypto PIC objects to always compile with
`-DOPENSSL_PIC -fPIC` to restore parity with the upstream build process.
This ensures that the legacy provider is built with parity to the
upstream legacy provider.

MFC after:              12 days
Tested with:            `make check` (legacy provider), `make universe`
Fixes:                  https://cgit.freebsd.org/src/commit/?id=14b9955e
Differential Revision:  https://reviews.freebsd.org/D44896
3797fe720a37ff9fb5b20546494ef1c4a6c01541 Enji Cooper 2026-03-22 00:39:16

debug: classified in 02-filenames_wildcards by '.*Makefile'

debug: moved to reverts because 'Need to be grouped with 14b9955e57cc28b61e785165b9effcbe620edb46'

Revert "vmimage.subr: pkg autoremove after pkg install"
This reverts commit 6a13aeac3c1f98db7cf156f24a4d6bc8d3c321f6.

The "bogus dependencies being installed" issue was traced down to pkg
confusion surrounding libclang_rt.asan-i386.so linking to a 32-bit
libgcc_s.so.1, and a more minimal workaround of "install clibs-lib32"
has been applied, so this hack is no longer required.

MFC after:      3 days
Sponsored by:   Amazon
4b29bf721ef09c399f3e4a4ab5ca9f549c5b1550 Colin Percival 2026-03-21 16:00:15

debug: classified in 00-reverts by 'This reverts commit \b([0-9a-fA-F]{40})\b'

Unclassified commits

Not classified automatically, and waiting for manual attention.

-- no commits in this category this week --

Technical notes

Dates:

Automatic grouping:

Automatic categories:

Source code:


Generated with commits-periodical 0.20 at 2026-04-13 18:39:30+00:00.

This work is supported by Tarsnap Backup Inc.

Alternate version: 2026-03-16 (release)