7233 Commits
Author SHA1 Message Date
Maxim Sobolev afe1dec742 tests: add UFS synchronous write durability tests
Check that once fsync(2), fdatasync(2), or a write(2) with O_SYNC or
O_DSYNC returns, the new data, the file size and every block pointer
leading to the data are on disk.  The cases append a block, fill a hole,
append the first block that needs an indirect block and append below an
existing indirect block.  Two more append after another write left a
new direct block unsynced, which with soft updates cuts the size and the
later pointers of an inode written meanwhile.  With O_SYNC and O_DSYNC
on soft updates, those also check that the open already made the
unsynced block durable.
Each case runs on UFS without soft updates, with soft updates and with
SU+J.

The file systems live on md(4) and the checks read the inode, the
indirect block and the data block straight from the device with libufs
right after the synchronous call returns.  There is no cache in front
of the disk device, so this shows what would survive a crash at that
moment without having to crash anything.

Sponsored by:   Sippy Software, Inc.
Reviewed by:    pho
Tested by:      pho
Differential Revision:  https://reviews.freebsd.org/D60134
MFC after:      1 month
2026-10-12 21:28:32 -07:00
Devin Teske 3fe5961a0b Add sysconf(8) and libbsdconf(3)
Complete the native configuration trinity: sysctl(8) for live kernel
state, sysrc(8) for rc.conf(5), and sysconf(8) for the remaining base
configuration -- loader.conf(5), sysctl.conf(5), and the make.conf(5)
family -- atop libbsdconf(3).

libbsdconf resurrects figpar as a unified reader/writer.  Callbacks own
semantics; statements may span multiple lines via backslash continuation;
non-seekable input is spooled; writes are atomic (mkstemp, fsync, rename)
with mode/owner preservation.  Format descriptors name each target, its
files, and quoting rules without private parsers.  Multi-file targets
follow boot sourcing order; loader chases loader_conf_files as the boot
loader does.

sysconf(8) is the operator-facing tool: name / name=value on a required
target, sysrc-style list edits, make append and list-strike where they
belong, jail/altroot, and a capsicum sandbox for read-only use.

Sysctl writes validate against the running kernel first -- unknown and
read-only OIDs, CTLFLAG_TUN (pointing at the loader target), and CTLTYPE
range checks -- so a typo or overflow does not land in sysctl.conf.

Make and src treat WITH_/WITHOUT_ as presence knobs (as bsd.mkopt.mk /
src.conf(5) do) and warn on the WITH_*=no form that does not disable the
option, so a bad assignment is caught before an /usr/src build surfaces
it.

The rc target passes through to sysrc(8).

Defaults querying (-d/-D/-A) mirrors sysrc for dumps and descriptions on
targets that have a defaults file; named reads already see defaults, and
-A only widens dump scope.

Manuals are split pkg(8)-style (bsdconf/put/format; sysconf plus
per-target pages).  ATF coverage exercises the frontend.

Co-authored-by:	Faraz Vahedi <[email protected]>
Reviewed by:	fuz, kfv
Differential Revision:	https://reviews.freebsd.org/D58066
2026-09-16 14:28:14 -07:00
Jaeyoon Choi 8895b1348f ufshci: install the ioctl header
The passthrough ioctl has a userland ABI header, but nothing installed
it. A program that wanted to use the ioctl had to copy the headers out
of the source tree by hand.

Install ufshci.h and ufshci_ioctl.h under /usr/include/dev/ufshci, the
way nvme installs nvme.h. The ioctl header pulls in ufshci.h, so both
go. Add the directory to the include mtree so installworld creates it.

Reviewed by:	imp (mentor)
Sponsored by:	Samsung Electronics
Differential Revision:	https://reviews.freebsd.org/D59560
2026-09-15 01:44:34 +00:00
Nick Price b3f7a438bb fdescfs: descend through /dev/fd/N when mounted linrdlnk
Linux resolves a path below /proc/self/fd/N in the directory the
descriptor names, and linprocfs makes /proc/<pid>/fd a symlink to
/dev/fd.  Under linrdlnk the fdescfs node carries only VV_READLINK,
which namei will not walk through, so such a path fails with ENOTDIR.

Return the underlying vnode from fdesc_lookup for a non-final component,
or a trailing slash, reusing the machinery the nodup option already
uses.  The last component is untouched, so open("/dev/fd/N") keeps its
dup(2) semantic; a descriptor with no vnode behind it, such as a pipe,
yields ENOTDIR.

Add ATF coverage for traversal, descriptor reuse, and preservation of
last-component and mount-option semantics.

Approved by:    adrian (mentor)
Reviewed by:	kib, adrian
Differential Revision:	https://reviews.freebsd.org/D59393

Signed-off-by: Nick Price <[email protected]>
2026-09-12 15:18:49 -07:00
Dag-Erling Smørgrav 4ec3ca55f9 hastd: Add rudimentary tests
Test that we can start and stop hastd with an empty configuration.

Reviewed by:	kevans
Differential Revision:	https://reviews.freebsd.org/D59345
2026-09-05 17:44:35 +02:00
voidanix 48efb6c4eb 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.

While at it, fix zonectl's report of write pointer LBAs for zones that
should have none, remove its forced debug flags and allow the geom(8)
shared subroutines to detect host-managed drives.

ATF-sh tests for gzoned(8) and zonectl(8) (dogfooded by gzoned(8)) are
included, featuring helpers (see zoned_subr.sh) for testing zoned
storage support in other components or GEOM classes.

Reviewed by:	asomers, fuz, ken
Sponsored by:	Google Summer of Code 2026
Pull Request:	https://github.com/freebsd/freebsd-src/pull/2326
2026-09-03 12:27:00 -06:00
Xin LI bbaf254293 fsck_msdosfs: add tests for lost cluster chain repair accounting
Add an ATF test suite covering Phase 3 ("Checking for Lost Files")
error accounting.  Test images are created using newfs_msdos(8),
and lost cluster chains are injected directly into FAT copies at
offsets derived from the BPB.  The LOST.DIR directory required by
reconnect() is constructed similarly: a root directory entry with
ATTR_DIRECTORY set and its first cluster pointing to a zero-filled
cluster containing "." and ".." entries.

The lost_chain_cleared and corrupted_lost_chain_reconnected test
cases provide regression coverage for the preceding commit:
 - lost_chain_cleared verifies that clearing a lost chain (the fallback
   taken when LOST.DIR is absent) exits with status 0 rather than 8
   (unrecovered error).
 - corrupted_lost_chain_reconnected verifies that FAT modifications
   from a chain truncated by checkchain() prior to reconnection are
   written back to disk, requiring "Update FATs? yes" and ensuring a
   clean second pass.

Additionally, lost_chain_left_alone, lost_chain_preen, and
corrupted_lost_chain_left_alone cover scenarios that must continue to
report unrecovered errors: read-only mode (-n), which performs no
repairs and leaves the image byte-for-byte unchanged, and preen mode
(-p), which attempts reconnection but does not clear lost chains.

MFC after:      1 week
2026-09-02 19:16:22 -07:00
Kyle Evans c45bdb39fe rc: add a backlight service to save/restore backlight levels
The default on my laptop is annoyingly bright, and this is a useful
feature to mitigate that.  The backlight script is largely a copy of the
mixer service which provides the same value for mixers, but this one is
specifically dependant on kld to allow DRM drivers a chance to attach.

Note that it's off by default to avoid interference with DEs, and
document the capability in backlight(8).  Set backlight_enable=YES in
rc.conf(5) to enable save/restore.

Relnotes:	maybe
Reviewed by:	bapt, ivy, manu, ziaee
Differential Revision:	https://reviews.freebsd.org/D59296
2026-09-01 22:51:41 -05:00
Devin Teske af25f24762 truss: add -t to select which system calls are reported
truss reports every system call a process makes, which for anything
larger than a toy program buries the calls of interest.  Add -t, taking
a comma-separated expression naming the system calls to report.

A term is the name of a system call, which may contain the fnmatch(3)
wildcards; a system call number in decimal; or "@group" naming a group
of related system calls.  A term prefixed with '!' excludes what that
one term matches rather than including it, and applies to no other
term.  An expression whose terms are all negated subtracts from the set
of every system call; any other expression selects from an empty one.
Terms apply in order and the last one to match a system call decides
whether it is reported.  Repeating -t appends, so "-t a -t b" and
"-t a,b" are equivalent.  An empty term is ignored, so an empty
expression filters nothing and a stray comma is not an error.

    truss -t @file,@net fetch https://www.freebsd.org/
    truss -t '!@memory' make buildworld
    truss -t '@desc,!@read,!@write' -p 34
    truss -c -t 'readlink*' /bin/ls
    truss -t 3,4 cat file

A number selects the system call with that number in the ABI of the
traced process, so "-t 3" selects read(2) from a native process but
close() from a Linux one.

Thirteen groups are provided to start with: @all, @creds, @desc, @file,
@ipc, @memory, @net, @none, @proc, @read, @signal, @time and @write.
These were derived by working through sys/kern/syscalls.master; the
audit event in that file is too sparse to drive the grouping by itself
(316 distinct events over 509 live system calls, 111 of them AUE_NULL),
so the groups are curated, but they are curated as patterns rather than
as name lists.  A family sharing a naming convention is written as one
pattern -- "extattr_*_file", "__acl_*_fd", "sctp_*" -- so system calls
added later join the right group without further change here.

A group's member list is an expression in exactly the form -t accepts,
so a group can say anything a user can say on the command line: a
member may be a pattern, a number or another group, and may be negated.
@desc is built from @read and @write without repeating them, and @none
is the single member "!*".  Keeping the two languages identical means a
group defined from a -t expression supplied elsewhere needs no
translation to become a member list.  Adding a group is a member list
plus one entry in syscall_groups[].

"truss -t" with no expression prints the groups and exits.

Matching is done against the name truss displays and against that name
with any compatibility or ABI prefix removed, so @file selects
compat11.stat, freebsd32_stat and linux_newstat as well as stat.

A name or pattern matching no system call of any ABI truss understands
is reported with a warning, since it is almost always a typo, but it is
kept and simply never matches.  sysdecode(3) is the oracle: it names
every system call of every such ABI whether or not that ABI's module is
loaded, and names them exactly as truss reports them.  Numbers are not
checked this way.  A process may issue any number the kernel can hold,
whether or not a system call is implemented behind it; one that is not
returns ENOSYS, which truss reports like any other result.  Only a
number too large to be one at all is rejected.

A system call excluded by -t is not decoded, so the filter also removes
the cost of formatting arguments that would never be printed, and it is
left out of the -c summary.

The option letter is the one truss on System V Release 4 and SunOS uses
for this feature, "-t [!]syscall,...", and which truss(1) already names
as its model.  The syntax is deliberately not bug-compatible with it:
there '!' is sticky for the remainder of a list, and a second -t
discards the first when the first began with '!'.

usr.bin/truss/tests is new, so etc/mtree/BSD.tests.dist gains an entry.

Without -t the behaviour is unchanged.

MFC after:	2 weeks
Reviewed by:	fuz
Differential Revision:	https://reviews.freebsd.org/D59275
2026-09-01 14:28:05 -07:00
Devin Teske aab7bd4d99 mtree: usr: add missing bsdconfig datetime directories
8cfe06ee44 installs into 085.datetime and share/bsdconfig/datetime,
but those paths were not in BSD.usr.dist. In-place installworld then
fails when install(1) cannot create the destination.

Fixes:	8cfe06ee44 ("bsdconfig: add datetime module for live system clock")
2026-08-16 07:26:46 -07:00
Abdelkader Boudih 5f74217c05 coreboot: Add coreboot firmware table driver
Nexus-attached driver that discovers and parses coreboot's LBIO tables
from physical memory. Exposes firmware metadata (version, build info,
mainboard, serial config, TSC frequency, CBMEM entries) via sysctl
hw.coreboot.*, the firmware console ring buffer via /dev/coreboot_console,
and structured CBMEM entry access via /dev/cbmem ioctl interface.

Tested on:
- Qotom Q535G6 (Kabylake)
- Intel NUC D54250WYK (Haswell)
- Intel NUC D33217GKE (Ivy Bridge)
- Dell 3100 2-in-1 (Gabbiter)
- Dell 3100 (Fleex)
- Lenovo IdeaPad 320s
- Lenovo ThinkPad T480
- HP Chromebook 11 G4
- HP Chromebook 11 G5
- HP Chromebook 11 G6 EE
- HP Chromebook 14 G4
- HP Chromebook 14 G5
- HP Chromebook x360 11 G1 EE
- HP Chromebook x360 11 G2 EE
- HP Chromebook x360 14 G1
- Acer C720
- Acer Chromebook 11
- Lenovo N22

Reviewed by:	ngie, kib, adrian
Differential Revision:	https://reviews.freebsd.org/D55649
2026-07-29 12:12:41 -07:00
John Baldwin db3afbe5a6 wg(4): Add a test that the driver handles a decryption failure
The test uses a fail point to inject a decryption error in OCF while
sending a ping across the tunnel.  The driver should then fail to
respond to the ping and increment the input error counter on the
interface.

Approved by:	so
Security:	FreeBSD-SA-26:52.if_wg
Security:	CVE-2026-58085
Reviewed by:	markj
Sponsored by:	Chelsio Communications
2026-07-29 17:45:02 +00:00
Alexander Leidinger 2cfd82f747 hwpmc: add regression tests for counting-PMC counter wraparound
Exercise a process-mode counting PMC whose accumulated count crosses,
or already exceeds, the range of the underlying hardware counter.
Before the previous commit, the first context switch after the
hardware counter wrapped panicked INVARIANTS kernels with "negative
increment" and silently corrupted the accumulated count on other
kernels.

The tests need a hardware counting event backed by a counter narrower
than 64 bits and skip where none is available (hwpmc(4) not loaded,
or a VM without a vPMU).

Reviewed by:		adrian
MFC after:		2 weeks
Assisted-by:		Claude Code (Fable 5)
Differential Revision:	https://reviews.freebsd.org/D58341
2026-07-20 12:24:36 +02:00
Dag-Erling Smørgrav 134a4c78d0 Retire the GNU subtree
With GNU diff and cdialog gone, this is now an empty shell.

Reviewed by:	markj
Differential Revision:	https://reviews.freebsd.org/D55425
2026-07-07 08:47:40 +02:00
Dag-Erling Smørgrav 7aa0fb6181 Revert "Retire the GNU subtree"
This reverts commit 9cc87ca23d.
2026-06-29 17:53:48 +02:00
Dag-Erling Smørgrav 9cc87ca23d Retire the GNU subtree
With GNU diff and cdialog gone, this is now an empty shell.

(cherry picked from commit 151dd62e005119dda24b8ff9b14aa5beaaa681ac)
2026-06-29 13:49:23 +00:00
Mark Johnston 8fd4d1c0ff tests: Add pjdfstest integration
Use ATF to wrap the new reimplementation of pjdfstest that came out of
GSOC 2022, now available in the ports tree as filesystems/pjdfstest.

So far I added tests for UFS (with several different option
combinations), tmpfs and ZFS, plus ZFS+nullfs.  All of these create a
memory disk, initialize the filesystem, and point the pjdfstest
executable at it.

In the future it would be good to add tests for at least NFS and p9fs.

Reviewed by:	asomers
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D56605
2026-06-19 15:20:51 +00:00
Konstantin Belousov 0ac9aac81c ntsync: install headers for userspace consumption
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D57038
2026-05-31 20:14:47 +03:00
Olivier Certner ad3d7666e0 BSD.tests.dist: Add the new sys/mac/do directory
Without that, 'make distributeworld' fails ('make buildworld' and 'make
installworld' do not need it).

Fixes:          cba191e291 ("MAC/do: Add basic tests on setting rules")
MFC after:      1 minute
Sponsored by:   The FreeBSD Foundation
2026-05-21 22:32:16 +02:00
Christos Margiolis 6024e3f99a Add audio group
To be initially used by virtual_oss(8) loopback devices.

Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Reviewed by:	emaste
Pull-Request:	https://ron-dev.freebsd.org/FreeBSD/src/pulls/26
2026-05-21 19:32:42 +02:00
Dag-Erling Smørgrav 1dc1b95163 mtree: Remove unused MANSUBDIRs
MFC after:	3 days
Fixes:		809504f331 ("man: Kill off MANSUBDIRs")
Reviewed by:	ziaee
Differential Revision:	https://reviews.freebsd.org/D57029
2026-05-16 18:16:57 +02:00
Dag-Erling Smørgrav 44338ccd12 BSD.root.dist: Correct tag for /etc/sysctl.kld.d
This is only used by rc.subr and belongs in rc, not runtime.

Fixes:		fa6d67cd16 ("BSD.root.dist: Add package tag for all directories")
MFC after:	3 days
Reviewed by:	ivy
Differential Revision:	https://reviews.freebsd.org/D56900
2026-05-09 11:04:25 +02:00
Dimitry Andric 770cf0a5f0 Fixups after llvm-project main llvmorg-21-init-19288-gface93e724f4 merge
Fix various configuration fails, update generated headers, Makefiles, etc.

PR:		292067
MFC after:	1 month
2026-04-25 16:11:52 +02:00
Ali Mashtizadeh 70ae0c4524 i386: Remove perfmon performance monitoring facility
Remove the perfmon performance monitoring facility that was for Intel
Pentium and Pentium Pro processors.

Reviewed by: imp,mhorne,emaste
Pull Request: https://github.com/freebsd/freebsd-src/pull/2155
2026-04-24 10:23:05 -06:00
Pierre Pronchery b8352da33f pkgconf: import into the base system
This introduces the following option:

* MK_PKGCONF: determines if pkgconf and bomtool should be built

The objective is to allow the creation of SBOM information while
building FreeBSD's src tree. The build system cannot rely on the
presence of bomtool (and eventually also spdxtool) in the build
environment, except for having it as part of the src tree directly.

The framework implementing the generation of SBOM files is under review
in D56474.

This will also help simplifying the build, with the introduction of
another framework relying on the availability of pkgconf.

Sponsored by:		Alpha-Omega, The FreeBSD Foundation
Reviewed by:		bapt, philip
Approved by:		philip (mentor)
Differential Revision:	https://reviews.freebsd.org/D56404
2026-04-22 15:42:56 +02:00
Andrew Turner 0ddaa4c86d arm64: Add arm64 SVE tests
Add the tests/sys/arch directory for architecture-specific tests and
use it to add arm64 SVE tests. These test the kernel is managing the
SVE state in a way we expect.

These tests require SVE hardware support to run so will skip when they
can't detect it.

Reviewed by:	markj
Sponsored by:	Arm Ltd
Differential Revision:	https://reviews.freebsd.org/D43311
2026-04-08 15:20:52 +01:00
Dag-Erling Smørgrav 6630c3a736 tunefs: Add tests
MFC after:	1 week
Reviewed by:	ngie
Differential Revision:	https://reviews.freebsd.org/D56034
2026-04-02 13:22:14 +02:00
Dag-Erling Smørgrav 40e8afadc3 pkgbase: Move all of Kyua into the kyua package
Some Kyua directories were improperly tagged as belonging to the tests
package.  Move them to the kyua package, which contains all of the
files found in these directories.

PR:		294129
MFC after:	1 week
Reviewed by:	ivy, emaste
Differential Revision:	https://reviews.freebsd.org/D56159
2026-03-30 16:03:29 +02:00
Dag-Erling Smørgrav 0a6dbf51d8 pkgbase: Move all of ATF into the atf package
Parts of ATF (including the licence and some of the documentation) were
for some reason part of the tests package instead of the atf package.
Moving them to where they logically belong poses no problem since tests
already depends on atf.

PR:		294129
MFC after:	1 week
Reviewed by:	ivy
Differential Revision:	https://reviews.freebsd.org/D56158
2026-03-30 16:03:29 +02:00
Lexi Winter 8ba3ada41d etc/mtree: Restore removed package tags
Following commit 436618a427 which added package tags to mtree,
some of the tags were later removed due to an issue with empty
packages being created.  That problem has been fixed by commit
7965c93e4d, so we can now restore the tags that were removed.

This reverts commit 00352ef6d2.
This reverts commit 1fbdb149aa.
This reverts commit ef2d586d7e.
This reverts commit 2a8a6179eb.

MFC after:	2 weeks (stable/15 only)
Reviewed by:	des, bapt, emaste
Differential Revision:	https://reviews.freebsd.org/D55645
Sponsored by:		https://www.patreon.com/bsdivy
2026-03-27 15:42:36 +00:00
Jose Luis Duran 8d99314a04 mtree: Add missing entries
Add missing mtree directory entries.  Without them, the resulting
worldstage METALOG file would produce an invalid (incomplete) mtree
specification file.

Reviewed by:	ivy
Differential Revision:	https://reviews.freebsd.org/D56013
2026-03-23 06:41:59 +00:00
Baptiste Daroussin b42e852e89 pkg-serve(8): serve pkg repositories over TCP via inetd (8)
Reviewed by:	manu, bdrewery (previous version)
Differential Revision:	https://reviews.freebsd.org/D55895
2026-03-20 13:29:48 +01:00
Dag-Erling Smørgrav 67728a18b9 yes: Add tests
MFC after:	1 week
Sponsored by:	Klara, Inc.
Reviewed by:	kevans
Differential Revision:	https://reviews.freebsd.org/D55802
2026-03-11 04:44:17 +01:00
Dag-Erling Smørgrav d4f6cb7542 build: Move all of lp under LPR option
* Tag related directories with package=lp

* Make the examples/printing directory conditional on MK_LPR

* Make the hosts.lpd(5) manual page conditional on MK_LPR

MFC after:	3 days
2026-02-21 22:25:49 +01:00
Mark Johnston af099eaa5e vmm: Enable unprivileged bhyve
- Add the vmm group.
- Let /dev/vmmctl belong to the vmm group by default, and give group
  write permissions.
- When creating a VM's device files, make them owned by the creating
  process' effective UID.

Reviewed by:	bnovkov
MFC after:	2 months
Sponsored by:	The FreeBSD Foundation
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D54741
2026-02-19 17:16:15 +00:00
Baptiste Daroussin 9a6e77e3db ed: add missing test entry in mtree
Reported by:	olce
2026-02-19 12:56:48 +01:00
Dimitry Andric 212272a437 mtree: stop creating /usr/share/doc/ncurses
In base 68ad2b0d7a the ncurses html documentation was removed, and
entries added to ObsoleteFiles.inc to get rid of /usr/share/doc/ncurses,
but the directory was still being re-created via BSD.usr.dist. Remove it
from there too.

Fixes:		68ad2b0d7a
MFC after:	1 month
2026-02-10 15:34:03 +01:00
Dag-Erling Smørgrav 36ec2b1c10 pwd: Add tests
MFC after:	1 week
Reviewed by:	imp
Differential Revision:	https://reviews.freebsd.org/D55153
2026-02-10 15:29:08 +01:00
Enji Cooper b78806b156 Remove additional libtpool and libuutil-related files
This change removes additional library files and tests orphaned in the
commit referenced below.

MFC with:	8b78d412a
Fixes: 8b78d412a ("zfs: world changes after 89f729dcc merge")
2026-02-03 23:33:04 -08:00
Jose Luis Duran ce8cd5dab3 mtree: debug: Add missing krb5 entries
Reviewed by:	ivy
Differential Revision:	https://reviews.freebsd.org/D54681
2026-01-15 19:26:39 +00:00
Jose Luis Duran b8480379ad mtree: usr: Add missing pkg/triggers entry
Reviewed by:	ivy
Fixes:		ea5e50c298 ("packages: Add a mandoc package")
Differential Revision:	https://reviews.freebsd.org/D54682
2026-01-14 14:29:35 +00:00
Jose Luis Duran 0d9fd06b03 gdb: Add missing mtree debug entry
Reviewed by:	markj
Fixes:		ea675a43f0 ("libexec/kgdb: Add new modules and install them together with debug info")
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D54680
2026-01-14 14:27:51 +00:00
Dag-Erling Smørgrav a678e87f55 unionfs: Support renaming symbolic links
This adds support for renaming a symbolic link found on the lower fs,
which necessitates copying it to the upper fs, as well as basic tests.

MFC after:	1 week
Sponsored by:	Klara, Inc.
Sponsored by:	NetApp, Inc.
Reviewed by:	olce, siderop1_netapp.com, jah
Differential Revision:	https://reviews.freebsd.org/D54229
2025-12-17 23:40:59 +01:00
Emmanuel Vadot 00352ef6d2 etc/mtree/BSD.include.dist: Remove atf tags
When building with WITHOUT_TESTS this result in a FreeBSD-atf-dev
package with only this directory and a dependency on FreeBSD-atf which
doesn't exists.

Reviewed by:	ivy
Differential Revision:	https://reviews.freebsd.org/D54236
Fixes:          436618a427 ("etc/mtree: Add package tags for /usr/include")
Sponsored by:   Beckhoff Automation GMbH & Co. KG
2025-12-16 10:00:58 +01:00
Emmanuel Vadot 1fbdb149aa etc/mtree/BSD.include.dist: Remove bsnmp tags
When building with WITHOUT_BSNMP this result in a FreeBSD-bsnmp-dev
package with only this directory and a dependency on FreeBSD-bsnmp which
doesn't exists.

Reviewed by:	ivy
Differential Revision:	https://reviews.freebsd.org/D54235
Fixes:          436618a427 ("etc/mtree: Add package tags for /usr/include")
Sponsored by:   Beckhoff Automation GMbH & Co. KG
2025-12-16 09:59:58 +01:00
Emmanuel Vadot ef2d586d7e etc/mtree/BSD.include.dist: Remove libmilter-dev
When building with WITHOUT_SENDMAIL this result in a FreeBSD-libmilter-dev
package with only this directory and a dependacy on FreeBSD-libmilter which
doesn't exists.

Differential Revision:	https://reviews.freebsd.org/D54193
Fixes:		436618a427 ("etc/mtree: Add package tags for /usr/include")
Reviewed by:	ivy
Sponsored by:	Beckhoff Automation GMbH & Co. KG
2025-12-12 16:52:19 +01:00
Robert Clausecker 2fb8cbc6ef libc/tests: add stdbit test framework and unit tests
This adds unit tests for all 70 functions in <stdbit.h>.

I'm sorry for the test framework, but it makes it so I don't
have to write 70 unit tests by hand.

Reviewed by:	adrian, des
Approved by:	markj (mentor)
MFC after:	1 month
Differential Revision:	https://reviews.freebsd.org/D53660
2025-11-30 20:21:52 +01:00
Jose Luis Duran 3d91a74638 mtree: Keep mtree files indented with spaces
The mtree tool indents directory entries with 4 spaces.

Reviewed by:	imp
Fixes:		9cab9fde5e ("virtual_oss: Port to base")
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D53979
2025-11-29 00:12:39 +00:00
Colin Percival b05f38262b Add pkgbase signing keys for FreeBSD 15
These keys were generated by cperciva@ using the AWS Key Management
Service.  They will not be used for signing anything other than
FreeBSD 15.x pkgbase repositories.

Keys will be generated for FreeBSD 16 at a later date, and likely in
a different way.

With hat:	re
MFC after:	8 hours (needed in 15.0-RC1)
Differential Revision:	https://reviews.freebsd.org/D53768
2025-11-14 23:58:41 -08:00
Kyle Evans 6a9452c837 lam: fix using stdin more than once
Historically, lam(1) closes stdin once we've hit EOF the first time,
which would stop it from doing anything else on subsequent gatherline()
calls with another openfile.  However, this doesn't seem to be strictly
necessary- the EOF flag on FILEs is quite sticky, so we can assume that
a subsequent fgetc(stdin) will flag EOF properly.

This 'fixes' the below-referenced commit in the sense that it surfaced
this problem as a fatal error, but the issue was pre-existing.  If we
do `lam - -`, then one gatherline() will fclose(stdin) and set `ip->eof`
for *that* openfile, while the next one will then observe that
STDIN_FILENO has been closed and turn it into an EBADF.

Add a few tests that were easy to snipe while I'm here, but I haven't
aimed for anything close to exhaustive because I think re@ would prefer
this fix go in sooner rather than later to land in 15.0.

Minor style adjustment for the previous commit while we're here.

Reported by:	cperciva
Discussed with:	jrtc27
Reviewed by:	des, jlduran
Fixes:	4472fd66d0 ("lam: fail on I/O errors")
MFC after:	3 days (tentative)
Sponsored by:	Klara, Inc.
Differential Revision:	https://reviews.freebsd.org/D53750
2025-11-14 08:36:28 -06:00