Commit graph

22564 commits

Author SHA1 Message Date
Warner Losh dcb621efd6 loader: Mark BEARSSL broken on powerpc
When BEARSSL is enabled, we pull in libsecureboot, which has EFI
dependencies which don't exist on powerpc. This needs to be detangled,
but until then mark it as broken.

Sponsored by:		Netflix
2024-02-22 10:08:12 -07:00
Ed Maste 9dd5023e95 iwm.4: add iwlwifi cross-reference
iwlwifi(4) supports a superset of the devices supported by iwm(4).  The
latter may be retired in the future (if there is no reason to prefer it
for the set of devices supported by both).

Sponsored by:	The FreeBSD Foundation
2024-02-20 11:47:51 -05:00
Brooks Davis 99ea675731 lib{c,sys}: move auxargs more firmly into libsys
Continue to filter the public interface (elf_aux_info()), but entierly
relocate the private interfaces (_elf_aux_info(),
__init_elf_aux_vector(), and __elf_aux_vector) to libsys.

This ensures that rtld updates the correct (only) copy of
__elf_aux_vector.  After 968a18975a
updates were confused and __getosreldate was failing, causing
the system to fall back to compat compat12 syscalls in some cases.

Return to explicitly linking libc to libsys and link libthr with libc
and libsys (in that order).

Reviewed by:	kib
Differential Revision:	https://reviews.freebsd.org/D43910
2024-02-19 22:44:08 +00:00
Bojan Novković 849599e28a committers-src: Add bnovkov@ with markj@ and jhb@ as mentors
Add mentorship information for bnovkov@.

Approved by:  markj (mentor)
Differential Revision: https://reviews.freebsd.org/D43963
2024-02-19 16:55:31 +01:00
Warner Losh 63e9c97664 loader: Add new option WITH_LOADER_BIOS_TEXTONLY
This option will omit all the graphics support, the teken terminal
library, video mode support, etc and support a simple, basic, text-only
video console for the x86 BIOS boot loader. It uses the FreeBSD 12
version of vidconsole.c. It defaults to NO.

Sponsored by:		Netflix
Differential Revision:	https://reviews.freebsd.org/D43912
2024-02-17 23:29:07 -07:00
Dimitry Andric 73ff7384e0 Optionally create full debuginfo for llvm-related executables
Commit de6feefdb7 limited the amount of debuginfo generated for clang
and other llvm-related executables. This was done to save disk space and
memory during building, but it makes debugging any of these executables
much harder.

Add a new src.conf(5) setting, WITH_LLVM_FULL_DEBUGINFO, to generate
full debuginfo instead. This is off by default, but could for example be
enabled for release builds or snapshots, so llvm executables are easier
to debug.

Reviewed by:	emaste
MFC after:	1 week
Differential Revision: https://reviews.freebsd.org/D43839
2024-02-17 00:15:32 +01:00
Ed Maste 2c5ff9118c rights.4: Remove sentence implying that rights are a mask
Capability rights passed to cap_rights_* are (now) not simple bitmaks
and cannot be ORed together in general (although it will work for
certain subsets of rights).

Remove sentence that implied rights are masks.  We already have the
sentence "The complete list of capability rights is provided below" so
listing the rights without an introductory sentence seems fine.

PR:		277057
2024-02-15 10:00:52 -05:00
Christopher Davidson bbd29c4394 wlan(4) - remove an(4) reference
Fixes: 663b174b5b ("an: Remove driver")
Pull request: https://github.com/freebsd/freebsd-src/pull/1120
2024-02-14 09:11:00 -05:00
Edward Tomasz Napierala b4b61ead7e dot.profile: handle symlinked $HOME
Reapply 4cea05a273:

    Make sh(1) recognize the default $HOME.  By default /home
    is a symlink; without this change, when you log in, sh(1)
    won't realize the current directory (eg '/usr/home/test')
    is the same as $HOME ('/home/test').

/home is no longer a symlink by default, but new users may be added on
systems that started out with an earlier version of FreeBSD (and still
have /home as a symlink) or admins may do so.

This test is not particularly expensive, so just restore it.

Suggested by:	danfe, brooks
2024-02-13 13:24:22 -05:00
Ho-Kun Lin dcde2454bc
Grammar fix in share/doc/IPv6/IMPLEMENTATION
Event:		Advanced UNIX Programming Course (Fall’23) at NTHU
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1003
2024-02-13 15:16:01 +08:00
Assume-Zhan 0789c3bd2c
share/examples/sound: Fix spelling "controller"
Event:		Advanced UNIX Programming Course (Fall’23) at NTHU.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/994
2024-02-13 14:18:04 +08:00
YuZhong-Chen edc7b46ebe
Fix typo in share/examples/sunrpc/dir/rls.c
Event:		Advanced UNIX Programming Course (Fall’23) at NTHU.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/974
2024-02-13 12:36:58 +08:00
YuZhong-Chen ee40f9e860
Fix typo in share/examples/sound/ossinit.h
Event:		Advanced UNIX Programming Course (Fall’23) at NTHU.
Pull Request:	https://github.com/freebsd/freebsd-src/pull/974
2024-02-13 12:36:05 +08:00
Ed Maste f1bd7311fb style.lua.9: remove mention of $FreeBSD$
Also restore a comment line in an example which previously started with
-- $FreeBSD$ but was removed in 6ef644f588.  The example shows the of
a module require statement block following the license header.
2024-02-12 10:38:40 -05:00
Collin Funk fd1066bed6 .profile: Don't bother checking for /home symlink
Since FreeBSD 14.0, user directories are created directly under /home.
This check should no longer be needed.

This reverts commit 4cea05a273.

Signed-off-by: Collin Funk <collin.funk1@gmail.com>
Pull-request: https://github.com/freebsd/freebsd-src/pull/1102
2024-02-12 09:24:49 -05:00
Christos Margiolis 5960ab73d8 snd_uaudio.4: document sysctls
Sponsored by:	The FreeBSD Foundation
MFC after:	2 weeks
Reviewed by:	dev_submerge.ch
Differential Revision:	https://reviews.freebsd.org/D43649
2024-02-12 13:07:51 +02:00
Christos Margiolis dcc47cd49e snd_uaudio.4: remove useless .Tn macro
Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks
Reviewed by:	emaste
Differential Revision:	https://reviews.freebsd.org/D43651
2024-02-12 13:07:51 +02:00
Simon J. Gerraty 41f9823eda rc.subr.8 note when DebugOn will be called 2024-02-10 12:31:10 -08:00
Jessica Clarke 89c3cc20d6 committers-src: Extremely belatedly add myself 2024-02-10 06:07:14 +00:00
Simon J. Gerraty aa3b7a2fbc /etc/rc add trace debug and verify
Debugging boot issues can be helped by
logging each rc.d script as it is run
and being able to selectively enable/disable set -x
debug.sh provides an elaborate framework for debugging shell scripts.

For secure systems, we want to be paranoid about what we read
during boot.

dot()	simply reads (.) arg file if it exists
vdot()	if mac_veriexec is active, ignore unverified files
	otherwise behaves much the same as dot()
safe_dot()  in safe_eval.sh allows reading an untrusted file;
	limiting the input to simple variable assignments.

In load_rc_config allow caller to provide an option to indicate how to
handle its arg:
	-v use vdot()
	-s use sdot() which will try to use vdot() and fallback to safe_dot()
	The default is to read using dot()

rc_run_scripts()
	encapsulate the running of rc.d scripts
	so that we can easily call it more than twice.

We vdot local.rc.subr to pick up extensions (like
run_rc_scripts_final) and overrides.

We also allow rc.subr.local or rc.conf to set rc_config_xtra
eg (rc_config_xtra=XXX for historic compatibility)

rc use set -o verify around the reading in of rc.subr
This has no effect if mac_veriexec is not active, but if it is; ensures
rc.subr has not been tampered with.

Reviewed by:	imp
Sponsored by:	Juniper Networks, Inc.
Differential Revision:	https://reviews.freebsd.org/D43671
2024-02-09 09:15:58 -08:00
Gleb Smirnoff 0bd8eb3e08 unix: retire LOCAL_CONNWAIT
This socket option was added in 6a2989fd54 together with LOCAL_CREDS.
Both options originate from NetBSD.  The LOCAL_CREDS seems to be used by
some software and is covered by our test suite.

The main problem with LOCAL_CONNWAIT is that it doesn't work as
documented. A basic test shows that connect(2) indeed blocks, but
accept(2) on the other side does not wake it up.  Indeed, I don't see what
code in the accept(2) path would go into the peer socket of a unix/stream
listener's child and would make wakeup(&so->so_timeo).  I tried the test
even on a FreeBSD 6.4-RELEASE and it produced the same results as on
CURRENT.

The other thing that puzzles me is why that option would be useful even if
it worked? Because on unix/stream you can send(2) immediately after
connect(2) and that would put data on the peer receive buffer even before
listener had done accept(2). In other words, one side can do connect(2)
then send(2), only after the remote side would make accept(2) and the
remote would see the data sent before the accept(2).  Again this
undocumented feature of unix(4) is present on all versions from FreeBSD 6
to CURRENT.

Reviewed by:		markj
Differential Revision:	https://reviews.freebsd.org/D43708
2024-02-08 09:00:41 -08:00
Mark Johnston f5b549d098 kmsan: Update kmsan.9 to note arm64 support
MFC after:	2 weeks
Sponsored by:	Klara, Inc.
Sponsored by:	Juniper Networks, Inc.
2024-02-08 11:35:11 -05:00
Martin Matuska a4e5e0106a zfs: merge openzfs/zfs@229b9f4ed
Notable upstream pull request merges:
 #15769 082338875 Add 'zpool status -e' flag to see unhealthy vdevs
 #15804 a0d3fe72b libzdb: Initial breakout of libzdb
 #15847 229b9f4ed LUA: Backport CVE-2020-24370's patch

Obtained from:	OpenZFS
OpenZFS commit:	229b9f4ed0
2024-02-08 16:51:08 +01:00
Brooks Davis 49076f376a libc: don't directly link libsys
It is sufficent to add it as a filter.

Reported by:	kib
Reviewed by:	kib
Differential Revision:	https://reviews.freebsd.org/D43781
2024-02-07 19:50:47 +00:00
Konstantin Belousov 3747af1699 Revert "hier.7: add /lib/casper directory"
This reverts commit 407345752d.
No longer needed since helpers are moved to /lib.

Reviewed by:	emaste
Sponsored by:	The FreeBSD Foundation
MFC after:	3 days
Differential revision:	https://reviews.freebsd.org/D43758
2024-02-06 19:27:50 +02:00
Brooks Davis 0d4f7723bc libc: link libsys as a auxiliary filter library
At runtime, when rtld loads libc it will also load libsys.  For each
symbol that is present in both, the libsys one will override the libc
one.  It continues to be the case that program need only link against
libc (usually implicitly).  The linkage to libsys is automatic.

Reviewed by:	kib, emaste, imp
Pull Request:	https://github.com/freebsd/freebsd-src/pull/908
2024-02-05 20:34:56 +00:00
Brooks Davis e9d961055a libsys: plumb in to build
libsys provides the FreeBSD kernel interface (auxargs, system calls,
vdso).  It can be linked directly for programs using a non-standard
libc and will later be linked as a filter library to libc providing
the actual system call implementation.

Reviewed by:	kib, emaste, imp
Pull Request:	https://github.com/freebsd/freebsd-src/pull/908
2024-02-05 20:34:56 +00:00
Minsoo Choo a67e5e7c98 pmap: Reflect 1f1b228 in man page
Fixes:	1f1b2286fd ("pmap: Convert boolean_t to bool.")
Differential Revision: https://reviews.freebsd.org/D43729
2024-02-03 20:10:22 -05:00
Minsoo Choo f846c5b346 pmap: Reflect commit 1f1b228 in man page
Reviewed by:	mhorne
Fixes:		1f1b2286fd ("pmap: Convert boolean_t to bool.")
Differential Revision:	https://reviews.freebsd.org/D43722
2024-02-03 14:07:44 -05:00
Alexander Ziaee 7bd6cbbf69 vt.4: explain console fonts
Add explaination about console fonts, how to convert them, which subset
of things support them and how to use them.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1063
2024-02-02 21:21:45 -07:00
Graham Perrin 521013e7e8 urndis(4): retrospective, address for hselasky
PR:		273530
Fixes:		08c9016bc6 Add a manpage for the urndis driver.
Signed-off-by:	Graham Perrin <grahamperrin@gmail.com>
Reviewed-by:	imp, zlei
Pull-request:	https://github.com/freebsd/freebsd-src/pull/834
2024-02-02 21:05:26 -07:00
Ricardo Branco b75fa3a2de procfs: Add self & exe symlinks like NetBSD does
NetBSD calls "curproc" "self" and "exe" "file" for proc. Reduce
gratuitous differnces by including them as well.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/976
2024-02-02 18:34:59 -07:00
Jessica Clarke fbae308319 bsd.subdir.mk: Drop broken optimisation for realinstall parallelisation
Not all of the tree is happy for realinstall to be done in parallel. In
particular, Makefile.inc1 uses .WAIT to force etc to be installed after
earlier subdirectories, since etc calls into share/man's makedb to run
makewhatis on the tree and needs all manpages to have been installed.
Also, libexec/Makefile doesn't set SUBDIR_PARALLEL, and the link from
ld-elf32.1 to ld-elf.1 relies on rtld-elf having been installed before
rtld-elf32, otherwise creating the link will fail.

In general, core behavioural differences like this between NO_ROOT and
"normal" builds are also dangerous and confusing.

If this optimisation is deemed important, it should be reintroduced in a
more limited and robust manner that doesn't break the above situations.
Until then value correctness over slight efficiency gains on high core
count machines, the same machines where you're more likely to encounter
issues from this optimisation.

This reverts commits cd19ecdbdc ("Similar to r296013 for NO_ROOT,
force SUBDIR_PARALLEL for buildworld WORLDTMP staging.") and
b9c6f31681 ("Add more STANDALONE_SUBDIR_TARGETS.").

Found by:	CheriBSD Jenkins
Reviewed by:	bdrewery, brooks
Fixes:		cd19ecdbdc ("Similar to r296013 for NO_ROOT, force SUBDIR_PARALLEL for buildworld WORLDTMP staging.")
Fixes:		b9c6f31681 ("Add more STANDALONE_SUBDIR_TARGETS.")
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D43705
2024-02-02 21:17:23 +00:00
Lexi Winter 4339f1e667 share/examples/IPv6/USAGE: remove
This document dates from the KAME days and, among other things,
references the 'prefix' command which has not existed for a long time.
Since IPv6 configuration is now documented in the Handbook, remove this
obsolete file.

Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1094
2024-02-02 08:30:18 -07:00
Graham Perrin 712fd5ac91 intro.9: minor changes
A correction: 'and' -> 'an'. Plus, several tweaks for brevity or
clarity.

Reviewed by:	mhorne
MFC after:	3 days
Pull Request:	https://github.com/freebsd/freebsd-src/pull/813
2024-01-31 14:31:32 -04:00
Jessica Clarke 41eb4a4ca2 share/man: Add mandoc.db files to METALOG
Otherwise these are omitted for -DNO_ROOT builds, whether for disk
images or dist tarballs.

Reviewed by:	brooks, emaste
Differential Revision:	https://reviews.freebsd.org/D43676
2024-01-30 22:17:34 +00:00
Florian Walpen 6c892b79de snd_hdspe(4): Per device sysctl for sample rate.
Some hardware setups require a specific sample rate due to devices being
connected to digital ports (AES, S/PDIF, ADAT). Add a per device sysctl
"sample_rate" to let the user override sample rate requests from the pcm
infrastructure, when needed.

Differential Revision:	https://reviews.freebsd.org/D43659
2024-01-30 15:07:57 +00:00
Zsolt Udvari 7aa4e4eb36 Add uzsolt@ to committers
Committer's Guide, steps for new committers, step 5.

Approved by:	bofh (mentor), diizzy (mentor)
Differential Revision:	https://reviews.freebsd.org/D43630
2024-01-30 08:44:14 +01:00
Warner Losh a26b96a930 style(9): Note larger divergence than implied
Times have changed, and we've diverged somewhat from the original style
guide, while still keeping much of the flavor and flair of its spirit as
the C language has evolved over the last 30 years since 4.4 was
released.

Sponsored by:		Netflix
2024-01-29 16:59:10 -07:00
Minsoo Choo bea67504c6 style(9): Remove $FreeBSD$ recommendation.
Now that stable/12 is now EOL, there's no reason to do this. They've
been proactively removed from the tree.

Reviewed by:	imp, lwhsu
Differential Revision:	https://reviews.freebsd.org/D43641
2024-01-29 16:59:10 -07:00
Florian Walpen fb87726303 snd_hdspe(4): Per device sysctl for period.
Let the user choose a period (interrupt cadence in samples), in the
official RME drivers this setting is available as "Buffer Size".
Override the period propagated through blocksize by pcm channel latency
settings (see sound(4)), since these are unreliable and differ between
playback and recording channels.

Differential Revision: https://reviews.freebsd.org/D43527
2024-01-28 20:20:26 +00:00
Gleb Smirnoff 5fc3104ae7 callout: retire callout_async_drain()
This function was used only in TCP before 446ccdd08e.  It was born in
pain in 2016 to plug different complex panics in TCP timers.  It wasn't
warmly accepted in phabricator by all of the reviewers and my recollection
of overall agreement was that "if you need this KPI, then you'd better fix
your code to not need it".  However, the function served its duty well all
the way to FreeBSD 14.  But now that TCP doesn't need it anymore, let's
retire it to reduce complexity of callout code and also to avoid its
further use.

Reviewed by:		jhb, markj, kib, rrs
Differential Revision:	https://reviews.freebsd.org/D43546
2024-01-24 09:33:27 -08:00
Gordon Bergling ad92f3d9d0 meta2deps.py: Fix a typo in a source code comment
- s/follwing/following/

MFC after:	3 days
2024-01-22 22:00:36 +01:00
Warner Losh bf531bcc5f altq: Remove stale driver references
Remove xr to an(4) and npe(4) since they no longer exist in the tree.

Sponsored by:		Netflix
2024-01-21 10:01:45 -07:00
Warner Losh 5a1af07a04 firmware(9): Update example
Update the example to include a firmware module in the kernel from npe
to iwn. Npe was deleted 6 years ago so makes a poor example of how to
embed firmware in the kernel.

Sponsored by:		Netflix
2024-01-21 09:20:53 -07:00
Gordon Bergling bce295fcbe PCI_IOV_INIT.9: Fix a typo in the manual page
- s/infrastucture/infrastructure/

MFC after:	3 days
2024-01-20 20:20:32 +01:00
Gabriel M. Dutra 1abc64bfbd committers-ports.dot: add myself (dutra) as a new ports committer
Add entries about new ports committer (dutra)
Update Mentor and Mentee Information

Approved by:	dbaio(mentor), garga(mentor)
Differential Revision:	https://reviews.freebsd.org/D43502
2024-01-18 18:02:19 -03:00
Christos Margiolis 6b6914c1e2 subr_bus: introduce device_set_descf() and modify allocation logic
device_set_descf() is a printf-like version of device_set_desc().

Allocation code has been transferred from device_set_desc_internal() to
device_set_desc_copy() and device_set_descf() to avoid complicating
device_set_desc_internal(). The "copy" argument in
device_set_desc_internal() has been replaced with a flag which is set
when the description string has been allocated with M_BUS.

Sponsored by:	The FreeBSD Foundation
MFC after:	2 weeks
Reviewed by:	imp, markj
Differential Revision:	https://reviews.freebsd.org/D43370
2024-01-16 18:49:15 +02:00
Christos Margiolis ebc9b69c77 pcm.4: mention snd_uaudio auto-load
Sponsored by:	The FreeBSD Foundation
MFC after:	2 weeks
Reviewed by:	imp
Differential Revision:	https://reviews.freebsd.org/D43397
2024-01-16 18:49:02 +02:00
Kristof Provost baf9b6d042 pf: allow pflow to be activated per rule
Only generate ipfix/netflow reports (through pflow) for the rules where
this is enabled. Reports can also be enabled globally through 'set
state-default pflow'.

Obtained from:	OpenBSD
Sponsored by:	Rubicon Communications, LLC ("Netgate")
Differential Revision:	https://reviews.freebsd.org/D43108
2024-01-16 09:45:54 +01:00