FreeBSD/src 2fb5343sys/netinet tcp_syncache.c

tcp md5: fix accounting of ACK with bad signatures

When processing the ACK of the initial TCP handshake using the
SYN cookie, don't increment the counter for unexpected
signatures (tcps_sig_err_sigopt). The correct
counter (tcps_sig_rcvbadsig) for bad signatures is already
incremented in TCPMD5_INPUT().

Reported by:            Hannes Elfert
Reviewed by:            rscheff
MFC after:              1 week
MFC to:                 stable/14
MFC to:                 stable/15
Differential Revision:  https://reviews.freebsd.org/D59302
DeltaFile
+0-1sys/netinet/tcp_syncache.c
+0-11 files

FreeBSD/src c004384share/man/man4 ix.4, sys/dev/ixgbe ixgbe.h if_ixv.c

ixgbe: Correct Wake-on-LAN configuration

Wake-on-LAN capability was inferred from NVM bits on every MAC even
though 82599 support is board and sometimes port specific.  Private
sysctls formed a second policy interface, and the driver neither
coordinated the controller wake source with PCI PME nor reliably
rebuilt address filters erased by the stop-time reset.

Use the standard ifconfig wake capabilities.  Derive support from the
82599 board and port matrix or the X540-and-newer NVM capability.
Require D3hot PME support, and use the NVM APME bit only to select the
initial magic-packet policy after initializing the LAN function number.

Snapshot requested filters before the terminal stop so shared reset and
PHY code sees the active wake policy.  After reset, restore RAR0, the
multicast table, receive filtering, and the optical laser before arming
WUFC, WUC, and PCI PME.  Remove device wake sources before clearing PCI
PME on detach, resume, and when wake is disabled.  Clear autonomous APM
so ifconfig remains authoritative.

    [18 lines not shown]
DeltaFile
+212-153sys/dev/ixgbe/if_ix.c
+19-1share/man/man4/ix.4
+1-6sys/dev/ixgbe/if_ixv.c
+2-3sys/dev/ixgbe/ixgbe.h
+234-1634 files

FreeBSD/src 5d3e31dsys/netinet tcp_syncache.c

tcp md5: fix accounting for SYN segments with unexpected signature

When receiving a SYN segment with an MD5 option on a listening socket,
which has not enabled TCP MD5 support, increment the counter for
unexpected signatures (tcps_sig_err_sigopt).

Reviewed by:            rscheff
MFC after:              1 week
MFC to:                 stable/14
MFC to:                 stable/15
Differential Revision:  https://reviews.freebsd.org/D59303
DeltaFile
+3-1sys/netinet/tcp_syncache.c
+3-11 files

FreeBSD/src c4df3e3lib/libproc Makefile, share/mk src.libnames.mk

libproc: link against libctf if MK_CTF != no instead of MK_CDDL != no

Logic prior to this change would incorrectly try linking when MK_CDDL != no,
instead of MK_CTF != no, which could result in the library and the tests being
broken if/when MK_CTF == no and MK_CDDL != no (an uncommon, but possible
combination with today's build knobs).

This change updates the conditional to correctly track the value of MK_CTF, which
in turn is properly toggled to no if/when MK_CDDL == no as it's a dependent build
knob.

This [niche] build bug has been present in FreeBSD since 2014.

MFC after:      1 week

(cherry picked from commit f2e6a8b9e50c7552037cb635f17b955ead84a813)
DeltaFile
+1-1share/mk/src.libnames.mk
+1-1lib/libproc/Makefile
+2-22 files

FreeBSD/src 7d87c1blib/libproc Makefile, share/mk src.libnames.mk

libproc: link against libctf if MK_CTF != no instead of MK_CDDL != no

Logic prior to this change would incorrectly try linking when MK_CDDL != no,
instead of MK_CTF != no, which could result in the library and the tests being
broken if/when MK_CTF == no and MK_CDDL != no (an uncommon, but possible
combination with today's build knobs).

This change updates the conditional to correctly track the value of MK_CTF, which
in turn is properly toggled to no if/when MK_CDDL == no as it's a dependent build
knob.

This [niche] build bug has been present in FreeBSD since 2014.

MFC after:      1 week

(cherry picked from commit f2e6a8b9e50c7552037cb635f17b955ead84a813)
DeltaFile
+1-1share/mk/src.libnames.mk
+1-1lib/libproc/Makefile
+2-22 files

FreeBSD/src 46c155blibexec/rc/rc.d dumpon

rc.d/dumpon: minor hardening/tightening up

- Scope local variables properly to each function.
- Quote variables that should be treated as single words.
- Replace `${cmd}; if [ $? -eq 0 ]` with `if ${cmd}` for simplicity.

MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D57899

(cherry picked from commit fc186c24b1e72fa3eba91c166f7a554a5cea5828)
DeltaFile
+8-5libexec/rc/rc.d/dumpon
+8-51 files

FreeBSD/src b82d506libexec/rc/rc.d dumpon

rc.d/dumpon: minor hardening/tightening up

- Scope local variables properly to each function.
- Quote variables that should be treated as single words.
- Replace `${cmd}; if [ $? -eq 0 ]` with `if ${cmd}` for simplicity.

MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D57899

(cherry picked from commit fc186c24b1e72fa3eba91c166f7a554a5cea5828)
DeltaFile
+9-5libexec/rc/rc.d/dumpon
+9-51 files

FreeBSD/src bb0300csys/compat/linuxkpi/common/src linux_firmware.c

linux_firmware: reformat error print-out

This makes it easier to grep for the error message to better understand
the call stack when loading firmware modules fails.

Fix a cosmetic-only style(9) bug while here in the same function related
to another logging message.

MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D58380

(cherry picked from commit a594783bac906ecc4f6528d7d576215f85a21bda)
DeltaFile
+4-3sys/compat/linuxkpi/common/src/linux_firmware.c
+4-31 files

FreeBSD/src 49a0bf4sys/compat/linuxkpi/common/src linux_firmware.c

linux_firmware: reformat error print-out

This makes it easier to grep for the error message to better understand
the call stack when loading firmware modules fails.

Fix a cosmetic-only style(9) bug while here in the same function related
to another logging message.

MFC after:      1 week
Differential Revision:  https://reviews.freebsd.org/D58380

(cherry picked from commit a594783bac906ecc4f6528d7d576215f85a21bda)
DeltaFile
+4-3sys/compat/linuxkpi/common/src/linux_firmware.c
+4-31 files

FreeBSD/src 8c0ae18lib/libc/tests/stdlib/libatexit libatexit.cc

[test] libatexit: leverage __{BEGIN,END}_DECLS

This change converts the longhand form of `extern "C" {` and its
corresponding `}` into `__BEGIN_DECLS` and `__END_DECLS`, respectively.

The new form is much easier to grep for and is a best practice to use in
the FreeBSD tree.

This is meant to be a non-functional change.

MFC after:      1 week

(cherry picked from commit bc81728c00b200297ac556974b5373c804077a17)
DeltaFile
+7-4lib/libc/tests/stdlib/libatexit/libatexit.cc
+7-41 files

FreeBSD/src 10d1f60lib/libc/tests/stdlib/libatexit libatexit.cc

[test] libatexit: leverage __{BEGIN,END}_DECLS

This change converts the longhand form of `extern "C" {` and its
corresponding `}` into `__BEGIN_DECLS` and `__END_DECLS`, respectively.

The new form is much easier to grep for and is a best practice to use in
the FreeBSD tree.

This is meant to be a non-functional change.

MFC after:      1 week

(cherry picked from commit bc81728c00b200297ac556974b5373c804077a17)
DeltaFile
+7-4lib/libc/tests/stdlib/libatexit/libatexit.cc
+7-41 files

FreeBSD/src 59ee4abshare/man/man9 cpuset.9

cpuset(9): correct markup

- Remove `\(em` from .Nm section as it's not valid mandoc markup.
- Remove the section from the .Nm directive (it's handled under the .Dt
  directive).

MFC after:      1 week
Reported by:    make manlint

(cherry picked from commit 5007a5d682d3737fe9b49c4cd69e04d025d209ec)
DeltaFile
+1-2share/man/man9/cpuset.9
+1-21 files

FreeBSD/src e892779share/man/man9 cpuset.9

cpuset(9): correct markup

- Remove `\(em` from .Nm section as it's not valid mandoc markup.
- Remove the section from the .Nm directive (it's handled under the .Dt
  directive).

MFC after:      1 week
Reported by:    make manlint

(cherry picked from commit 5007a5d682d3737fe9b49c4cd69e04d025d209ec)
DeltaFile
+1-2share/man/man9/cpuset.9
+1-21 files

FreeBSD/src fb60889share/man/man9 DB_COMMAND.9

DB_COMMAND(9): correct mdoc markup for .Nm entries

Add missing commas after .Nm entries.

MFC after:      1 week
Reported by:    make manlint

(cherry picked from commit b96a063f61001e60ac282eb3500e703c7c3faf9c)
DeltaFile
+2-2share/man/man9/DB_COMMAND.9
+2-21 files

FreeBSD/src afdf887share/man/man9 DB_COMMAND.9

DB_COMMAND(9): correct mdoc markup for .Nm entries

Add missing commas after .Nm entries.

MFC after:      1 week
Reported by:    make manlint

(cherry picked from commit b96a063f61001e60ac282eb3500e703c7c3faf9c)
DeltaFile
+2-2share/man/man9/DB_COMMAND.9
+2-21 files

FreeBSD/src a151a01contrib/netbsd-tests/lib/libc/c063 t_fchmodat.c t_mkfifoat.c

contrib/netbsd-tests: lib/libc/c063: sync with NetBSD

This change syncs the lib/libc/c063 NetBSD tests with FreeBSD. This does
two things:
- Addresses bogus tautologically true assertions flagged by clang and gcc
  with ATF 0.22+ [1].
- Brings in some new test coverage.

Obtained from:  NetBSD (date tag: `20260818UTC`)
MFC after:      2 weeks
1. https://github.com/freebsd/atf/pull/72

(cherry picked from commit 8109a5c0fba0d015354a69b40e6682d5e8c0f638)
DeltaFile
+89-59contrib/netbsd-tests/lib/libc/c063/t_utimensat.c
+69-4contrib/netbsd-tests/lib/libc/c063/t_faccessat.c
+29-2contrib/netbsd-tests/lib/libc/c063/t_mkfifoat.c
+11-6contrib/netbsd-tests/lib/libc/c063/t_fchmodat.c
+198-714 files

FreeBSD/src 7364167share/man/man9 alq.9

alq(9): add missing .Nm entry for ALQ(9)

MFC after:      1 week
Reported by:    make manlint

(cherry picked from commit 4fa245edc7ad426ebde7a316191b579e62fe795f)
DeltaFile
+1-0share/man/man9/alq.9
+1-01 files

FreeBSD/src 0d7fc3ashare/man/man9 alq.9

alq(9): add missing .Nm entry for ALQ(9)

MFC after:      1 week
Reported by:    make manlint

(cherry picked from commit 4fa245edc7ad426ebde7a316191b579e62fe795f)
DeltaFile
+1-0share/man/man9/alq.9
+1-01 files

FreeBSD/src b853bacshare/man/man9 acl.9

acl(9): fix typo (ACL_ACL -> ACL)

MFC after:      1 week

(cherry picked from commit 9fd963b0a149357b6fbc16ef0b999e6b487e513a)
DeltaFile
+1-1share/man/man9/acl.9
+1-11 files

FreeBSD/src 2ed7da9share/man/man9 acl.9

acl(9): fix typo (ACL_ACL -> ACL)

MFC after:      1 week

(cherry picked from commit 9fd963b0a149357b6fbc16ef0b999e6b487e513a)
DeltaFile
+1-1share/man/man9/acl.9
+1-11 files

FreeBSD/src 20b68f0share/man/man9 atomic.9

atomic(9): add missing .Nm entries

MFC after:      1 week
Reported by:    make manlint

(cherry picked from commit 8eced03c369a6f8aad0013604f790bafd4526848)
DeltaFile
+3-0share/man/man9/atomic.9
+3-01 files

FreeBSD/src b7a2b3dshare/man/man9 atomic.9

atomic(9): add missing .Nm entries

MFC after:      1 week
Reported by:    make manlint

(cherry picked from commit 8eced03c369a6f8aad0013604f790bafd4526848)
DeltaFile
+3-0share/man/man9/atomic.9
+3-01 files

FreeBSD/src 5740717sys/arm64/arm64 pmap.c

arm64 pmap: correct the condition for flushing the icache

Whenever we create a user-space mapping, we always set ATTR_S1_PXN in
the PTE, which blocks execution of user-space code while running in
kernel mode.  However, when seeking to determine whether we need to
perform an icache flush before installing the new PTE, we test whether
sometimes the old PTE or other times the new PTE has ATTR_S1_XN set.
The trouble is that ATTR_S1_XN is defined as the bitwise OR of
ATTR_S1_PXN and ATTR_S1_UXN, and so the test for whether ATTR_S1_XN is
set is satisfied if either of its constituent bits is set, i.e., we
write (l3e & ATTR_S1_XN) != 0.  Consequently, the test is always true.

In practice, I believe that the ill effects of this bug are limited:
In pmap_enter(), in rare circumstances, e.g., wiring a code page, an
unnecessary icache flush will be performed.  In pmap_enter_l2() and
pmap_enter_l3c(), no icache flush will be performed.  However,
typically an icache flush would have already been performed on each of
the constituent base pages.


    [3 lines not shown]
DeltaFile
+4-4sys/arm64/arm64/pmap.c
+4-41 files

FreeBSD/src 1a29676lib/libcasper/libcasper zygote.c libcasper.c

libcasper: reap zombies without requiring waitpid(2)

Reported and tested by: bapt
Reviewed by:    bapt, markj
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D59348
DeltaFile
+1-1lib/libcasper/libcasper/zygote.c
+1-1lib/libcasper/libcasper/libcasper.c
+2-22 files

FreeBSD/src 429cb53sys/dev/ixl if_ixl.c

ixl: Reset VSI statistics after initial sampling

The initial statistics update runs before the PF VSI has obtained its
firmware-assigned statistics counter index.  Discard that provisional
VSI baseline so the first update after initialization records the
correct hardware counter.

Without this reset, subtracting a larger provisional value from a newly
selected counter can be mistaken for a 32-bit wrap and report nearly
UINT32_MAX receive drops immediately after boot.

Reported by:    Daniel Braniss <danny at cs.huji.ac.il>
Tested by:      Daniel Braniss <danny at cs.huji.ac.il>
Obtained from:  Intel ixl 1.14.2
MFC after:      2 weeks
Sponsored by:   BBOX.io
Differential Revision:  https://reviews.freebsd.org/D59336
DeltaFile
+1-0sys/dev/ixl/if_ixl.c
+1-01 files

FreeBSD/src 4099b5c. UPDATING, lib/csu/common crtbrand.S

Update in preparation for 14.5-RELEASE

- Bump BRANCH to RELEASE
- Add the anticipated RELEASE announcement date
- Set a static __FreeBSD_version

Approved by:    re (implicit)
Sponsored by:   OpenSats Initiative
DeltaFile
+3-0UPDATING
+1-1sys/conf/newvers.sh
+1-1lib/csu/common/crtbrand.S
+5-23 files

FreeBSD/src 26164desys/netinet in_fib_algo.c, sys/netinet6 in6_fib_algo.c

route/fib_algo: Free leaked radix_masks in radix_lockless

radix_lockless algorithm creates its own radix tree and
allocates its own radix_masks by directly calling rnh_addaddr().
However, during destruction, it only frees the radix_tree without
freeing its allocated radix_masks.
Fix the leak by calling rn_delete() during radix_destroy().

PR:             297339
Reviewed by:    melifaro
MFC after:      2 weeks
Differential Revision: https://reviews.freebsd.org/D59112

(cherry picked from commit 790817f5a7a640c9ceb5c2ad99135f1a69aeb77d)
DeltaFile
+13-2sys/netinet6/in6_fib_algo.c
+12-1sys/netinet/in_fib_algo.c
+25-32 files

FreeBSD/src e5a9ad7sys/netinet in_fib_algo.c, sys/netinet6 in6_fib_algo.c

route/fib_algo: Free leaked radix_masks in radix_lockless

radix_lockless algorithm creates its own radix tree and
allocates its own radix_masks by directly calling rnh_addaddr().
However, during destruction, it only frees the radix_tree without
freeing its allocated radix_masks.
Fix the leak by calling rn_delete() during radix_destroy().

PR:             297339
Reviewed by:    melifaro
MFC after:      2 weeks
Differential Revision: https://reviews.freebsd.org/D59112

(cherry picked from commit 790817f5a7a640c9ceb5c2ad99135f1a69aeb77d)
DeltaFile
+13-2sys/netinet6/in6_fib_algo.c
+12-1sys/netinet/in_fib_algo.c
+25-32 files

FreeBSD/src 813eb5asys/kern subr_devstat.c

devstat: Fix a kernel stack disclosure

The 16-byte "device_name" field was not zero-filled, so could contain
uninitialized stack data.  Zero the whole struct, as that's the
prevailing pattern for this kind of conversion code, and it's more
robust in the face of future revisions to struct devstat.

Approved by:    re (cperciva)
Reviewed by:    olce, kib
Reported by:    Reo Shiseki
Fixes:          a11d132f6c62 ("devstat: Provide 32-bit compatibility")
MFC after:      3 days
Sponsored by:   The FreeBSD Foundation
Differential Revision:  https://reviews.freebsd.org/D59309

(cherry picked from commit 7cb1a76f88158fb690418336b736e66c238cd4f7)
(cherry picked from commit 6e94e0734b9d3036df8c7d94d827f8eb1119905b)
DeltaFile
+1-0sys/kern/subr_devstat.c
+1-01 files

FreeBSD/src 48efb6clib/geom/zoned gzoned.8 geom_zoned.c, sys/geom/zoned g_zoned.h g_zoned.c

gzoned: Introduce Zoned Storage emulator

gzoned(8) is a new GEOM class that exposes a host-managed zoned device
(similar to ZAC/ZBC drives) on top of regular, non-zoned providers.

The created medium is sliced into equally sized zones, by default
sequential-write-required.  Such zones can be turned into conventional
zones if desired.  The zoned drive's state and configuration is
persistent through metadata at the tail of the backing provider, meaning
the zoned device gets recreated at the provider retaste.  Zone state
changes only mark the table dirty with BIO_FLUSH committing it,
mirroring drives whose zone state is volatile until a cache flush.

The new class tries to emulate real zoned drives by incorporating
per-zone write pointers and support for BIO_ZONE management commands.
Fault emulation through zone conditions (RWP recommended, offline, R/O),
URSWRZ bit toggling and concurrent open zone limits are additional
features useful for testing.


    [11 lines not shown]
DeltaFile
+1,819-0sys/geom/zoned/g_zoned.c
+1,056-0tests/sys/geom/class/zoned/zoned_test.sh
+291-0sys/geom/zoned/g_zoned.h
+289-0lib/geom/zoned/geom_zoned.c
+260-0lib/geom/zoned/gzoned.8
+221-0usr.sbin/zonectl/tests/zonectl_test.sh
+3,936-020 files not shown
+4,142-1526 files