Commit Graph

22267 Commits

Author SHA1 Message Date
Warner Losh
2a63c3be15 Remove $FreeBSD$: one-line .c comment pattern
Remove /^/[*/]\s*\$FreeBSD\$.*\n/
2023-08-16 11:54:29 -06:00
Warner Losh
42b388439b Remove $FreeBSD$: one-line .h pattern
Remove /^\s*\*+\s*\$FreeBSD\$.*$\n/
2023-08-16 11:54:23 -06:00
Warner Losh
b3e7694832 Remove $FreeBSD$: two-line .h pattern
Remove /^\s*\*\n \*\s+\$FreeBSD\$$\n/
2023-08-16 11:54:16 -06:00
Simon J. Gerraty
93ac817fae local.dirdeps.mk ensure tools/build is built if needed
If MK_host_egacy is yes, we need it built, make sure that happens.

Reviewed by:	stevek
2023-08-16 08:31:11 -07:00
Li-Wen Hsu
962c2a4925
release(7): Bump date after introducing VMFSLIST in 32ae9a6b39
Sponsored by:	The FreeBSD Foundation
2023-08-12 12:39:53 +08:00
Alan Somers
ec54a31423 ixl.4: update link to intel-nvmupdate ports
MFC after:	2 weeks
Sponsored by:	Axcient
Reviewed by:	pkubaj
Differential Revision: https://reviews.freebsd.org/D41288
2023-08-10 08:59:19 -06:00
Enji Cooper
28f6c2f292 Import GoogleTest 1.14.0
GoogleTest 1.14.0 now requires C++14 to build. Change
`googletest.test.inc.mk` to reflect this requirement.

Adjust the build integration logic to handle the new version of
GoogleTest (add/remove headers/sources as needed).

Tighten down warnings via `CXXFLAGS.clang` instead of ignoring all
warnings. Some new warnings snuck in after I did my last round of fix
submissions upstream.

Also address some overlinking added in the previous version import by
removing superfluous libraries.

===============================

Expect WhenDynamicCastToTest.AmbiguousCast to fail

This change reapplies the expected failure from 1.10.0.

Ref: https://github.com/google/googletest/issues/2172

MFC after:	2 weeks
Reviewed by:	asomers, emaste
Differential Revision:	https://reviews.freebsd.org/D41399

Merge commit '8ef491440fcaec96f899d73e08873426c78583a4' into googletest-v1.14.0-import
2023-08-10 02:32:33 -07:00
Colin Percival
32ae9a6b39 release: Build UFS and ZFS VM images
A new option 'VMFSLIST' controls the list of filesystems for which VM
images will be built; the default is to build both UFS and ZFS.

The vm-install target installs these as ${OSRELEASE}-${FS}.${FORMAT},
e.g. FreeBSD-14.0-CURRENT-amd64-zfs.vmdk.  For backwards compatibility,
the ${VMFS} image is linked to the previously used ${OSRELEASE}.${FORMAT}
name.

Cloudware building will be updated in a later commit.

Reviewed by:	gjb
Reviewed by:	emaste, markj (previous version)
Sponsored by:	https://www.patreon.com/cperciva
Differential Revision:	https://reviews.freebsd.org/D41340
2023-08-09 15:44:54 -07:00
Marius Strobl
8f5dbc22e5 arswitch(4): Remove support for AR{7240,9340} found in MIPS SoCs only
With the general removal of MIPS support there's no longer a need to
support these integrated switches.

Approved by:	adrian
Differential Revision:	https://reviews.freebsd.org/D41394
2023-08-09 18:22:13 +02:00
Marius Strobl
077ef5b445 ath(4): Remove MIPS SoC build glue and AR9130 from FreeBSD HAL
All of these are obsoleted by the general removal of MIPS support.

Actually, corresponding to the removed AH_SUPPORT_x, there is more
superfluous support sprinkled across the HAL source. However, that
code is left in place for now in order to ease a sync to NetBSD.

Reviewed by:	emaste (w/ man page fix)
Approved by:	adrian
Differential Revision:	https://reviews.freebsd.org/D41355
2023-08-09 17:44:46 +02:00
Marius Strobl
9cb4ee9a64 man4: Remove stale MLINK to ath_pci.4
Reported by:	Jose Luis Duran
Fixes:	37c8ee8847 ath(4): Remove MIPS AHB frontend and join PCI one w/ main support again
2023-08-09 14:35:25 +02:00
Marius Strobl
37c8ee8847 ath(4): Remove MIPS AHB frontend and join PCI one w/ main support again
Following the removal of general MIPS support, there's no longer a need
to have the AHB bus-frontend in place, which according to Linux sources
also isn't used with any non-MIPS SoCs. For simplicity, PCI bus support
is only made conditional on the main one again, i. e. device ath_pci is
removed, and built into the main module, i. e. if_ath_pci.ko obsoleted,
respectively.
Effectively, this reverts the following commits and associated changes:
dba9c85977
e849bb3ecb

Approved by:	adrian
Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D41354
2023-08-08 22:30:13 +02:00
Stephen J. Kiernan
458e0c1b66 local.sys.dirdeps.mk: Allow CROSS_TARGET_FLAGS to be overridden
Use ?= when setting CROSS_TARGET_FLAGS so we do not override it
if another file already has set it.

Reviewed by:	sjg
Obtained from:	Juniper Networks, Inc.
2023-08-08 16:11:27 -04:00
Robert Clausecker
66f5f4bffe share/man/man7/simd.7: document amd64/strchrnul SIMD implementaionts
While we are at it, remove mention of x86-64-v3 and v4 variants of
strlen(3) which were omitted when D40693 landed.

Sponsored by:	The FreeBSD Foundation
Approved by:	mjg
Differential Revision: https://reviews.freebsd.org/D41333
2023-08-06 16:05:09 +02:00
Vladimir Kondratyev
f1d955be2a hidraw(4): Implement HIDRAW_GET_DEVICEINFO ioctl
In commit c77bfaa750 uhid(4) gained support for ioctl from
USB_GET_DEVICEINFO. This is used in libraries like libfido2 to
retrieve information about a device.

This commit adds binary compatible version to hidraw(4).

PR:		264843
MFC after:	1 month
Requested by:	grembo
2023-08-06 14:51:08 +03:00
Vladimir Kondratyev
12f5f11477 hidraw(4): Fix ioctl names in man page. 2023-08-06 14:51:08 +03:00
Yuri Pankov
b306c604df locale: update to CLDR 43 and Unicode 15
Reviewed by:	bapt
Differential Revision:	https://reviews.freebsd.org/D41151
2023-08-04 01:47:16 +02:00
Robert Clausecker
0588819779 share/man/man7: document libc simd usage in new man page simd(7)
This documents SIMD usage in libc for all architectures with
specific details on the new amd64 SIMD dispatch framework.

Sponsored by:	The FreeBSD Foundation
Approved by:	kib
Reviewed by:	imp
Differential Revision:	https://reviews.freebsd.org/D40693
2023-08-04 01:54:44 +03:00
Kevin Bowling
1b01772f01 em(4): remove reference to CNVi
I misread the newer PCH datasheet, these are still refered to as PCH.
2023-08-03 13:26:28 -07:00
Kevin Bowling
56b9145cd0 em(4): correct a typo 2023-08-03 12:51:12 -07:00
Kevin Bowling
42ce724d80 em(4): Update and expand on hardware support 2023-08-03 12:49:42 -07:00
Kevin Bowling
7bcdbacf84 em(4): add link to lem(4) 2023-08-03 12:49:12 -07:00
Mitchell Horne
84f9f2c5cf intro(9): rewrite from scratch
This page has existed as a placeholder since its creation in 1995. It
does not provide a useful introduction to the content in this section.

Reimagine it as a top-level overview page containing brief descriptions
and links to existing pages in section 9. It is roughly organized into
sub-sections, grouped by topic or subsystem. In other words, the page is
meant to function as a map to other content.

There is a balance to be found here between providing as many links as
possible and keeping the page concise and searchable. In general the aim
is to reference pages which provide the best entry point to a particular
topic. For example, a link is given to locking(9), but not to the
specific lock pages such as mutex(9) or rwlock(9).

NetBSD has done something similar with their intro(9), so some
inspiration has been taken from there, although their content doesn't
align that closely with what we have.

I have done a thorough review of our existing pages and formed these
subsections around them, but they are meant to evolve.

PR:		270481
Reviewed by:	imp, emaste
MFC after:	3 weeks
Relnotes:	yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D41104
2023-08-03 11:07:41 -03:00
Mitchell Horne
d441ec1c21 g_bio(9): add link to bio(9)
This page documents 'struct bio', so this can be helpful with finding or
referencing it.

Reviewed by:	imp, markj
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D41252
2023-08-03 11:07:31 -03:00
Domagoj Stolfa
6de0222840 dtrace: Add WITH_DTRACE_ASAN
See commit 4ae6991228.  This version of
the commit avoids inadvertently changing SHLIBDIR for libdtrace.so.
2023-08-02 09:15:08 -04:00
Ed Maste
77f6be4484 retire SHARED_TOOLCHAIN knob
Toolchain components were historically statically linked.  They became
normal dynamically linked executables in commit 6ab18ea64d.  There is
no need to keep a special case build option for the toolchain; users who
want statically linked toolchain (or any other) components can use the
existing NO_SHARED knob.

Reviewed by:	dim, sjg
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D41266
2023-08-01 20:13:22 -04:00
John Baldwin
21ef3591b6 build.7: Document several toolchain make variables.
Document CROSS_TOOLCHAIN, UNIVERSE_TOOLCHAIN, and USE_GCC_TOOLCHAINS.

Differential Revision:	https://reviews.freebsd.org/D40778
2023-08-01 14:01:58 -07:00
Mark Johnston
5cdaac92e1 dtrace: Revert the addition of WITH_DTRACE_ASAN
The follow-up fix triggers a lib32 build failure, revert everything
until the problem is addressed.
2023-08-01 13:03:10 -04:00
Ed Maste
391e1f23b3 src.conf.5: regen after armv6 demotion
Fixes: 98d03dca9a ("universe: Demote armv6 to an extra architecture.")
Sponsored by:	The FreeBSD Foundation
2023-08-01 11:20:15 -04:00
Pau Amma
258c6d5e9b filemon(4): Better error checking in code example
Discussed with:	dim
Reviewed by:	markj
Differential Revision:	https://reviews.freebsd.org/D38367
2023-08-01 11:30:38 -03:00
Jessica Clarke
2d01ce7f85 mk: Install bsd.compat.pre.mk
Reported by:	dchagin
Fixes:		5d6cb793d0 ("bsd.compat.mk Extract _ALL_LIBCOMPATS and add related variables")
2023-07-28 17:52:38 +01:00
Warner Losh
98d03dca9a universe: Demote armv6 to an extra architecture.
Per discussions over how to lighten the load of armv6, move it to an
extra arch. You can still build TARGET_ARCH=armv6 if you desire, but
it won't be built as part of 'make universe' without -DEXTRA_TARGETS.

Sponsored by:		Netflix
2023-07-27 22:30:41 -06:00
Val Packett
da6620e495 mk: fix unnecessary library relinking with incremental builds
Initial libs such as csu are always built (.PHONY), and their
installation to WORLDTMP was causing all the subsequent libraries to
be considered out-of-date even when in reality they were not. Use
install -C more consistently everywhere to avoid unnecessarily
updating the mtimes in WORLDTMP, fixing this problem.

This cut down my no-change buildworld time from 30 to 15 seconds.

Fixes: https://lists.freebsd.org/pipermail/freebsd-current/2016-May/061481.html
TODO.1

Reviewed by: sjg
Sponsored by: https://www.patreon.com/valpackett
Differential Revision:  https://reviews.freebsd.org/D39980
2023-07-27 14:55:16 -07:00
Domagoj Stolfa
4ae6991228 dtrace: Add WITH_DTRACE_ASAN
This option is a blanket for all the DTrace-related software. The option
when enabled passes in -fsanitize=address -fsanitize=undeifned, enabling
ASAN and UBSAN in the following components:

 - libdtrace
 - dtrace(1)
 - lockstat(1)
 - plockstat(1)

The option defaults to "no" and is intended as a developer aid.

Reviewed by:	markj
Differential Revision:	https://reviews.freebsd.org/D41157
2023-07-27 16:07:34 -04:00
Jose Luis Duran
81a7ce4404 src.conf.5: Regen
Regenerate makeman after enabling the building of lib32 on arm64.

Fixes: a1b6757313 ("arm64 lib32: enable building of lib32 on arm64")
Pull Request: https://github.com/freebsd/freebsd-src/pull/804
2023-07-27 14:02:14 -04:00
Jessica Clarke
87177389b7 bsd.lib.mk: Automatically generate libcompat TAGS
Note that the pattern for matching is made slightly more specific, so as
to permit libcompats where one is a prefix of another (e.g. CheriBSD has
lib64 and lib64c).

Reviewed by:	brooks, jhb, emaste
Differential Revision:	https://reviews.freebsd.org/D41185
2023-07-27 05:10:46 +01:00
Jessica Clarke
5d6cb793d0 bsd.compat.mk Extract _ALL_LIBCOMPATS and add related variables
Adding these to a new bsd.compat.pre.mk will allow other parts of the
tree to iterate over the set of possible libcompats (upper and/or lower)
rather than having to hard-code the list.

Reviewed by:	brooks, jhb, emaste
Differential Revision:	https://reviews.freebsd.org/D41178
2023-07-27 05:10:43 +01:00
Marius Strobl
4ef1c6f75d base: Remove support for the VTOC8 partitioning scheme
The removal of the sparc64 support in February 2020 obsoleted the
VTOC8 partitioning scheme as no other FreeBSD platform makes use
of it. Moreover, the code is bitrotting as nothing defines e. g.
LOADER_VTOC8_SUPPORT any more and, thus, should go now, too. With
this change, the following commits are reverted as far as VTOC8
is concerned and parts haven't already previously been deleted
along with prior sparc64 removals:
094fcb157d
a7d366e958
ba8d50d08b

The alignment example d9711c28ef
added to the VTOC8 section of gpart.8 is folded into the MBR one.

This should finally conclude the deorbit of sparc64-specific bits.

        We had joy, we had fun
        we ran Unix on a Sun.
        But that source and the song
        of FreeBSD have all gone.

Credits to Michael Bueker for the original "Unix on a Sun" and Rod
McKuen for the "Seasons in the Sun" lyrics.
2023-07-26 13:16:12 +02:00
Shivank Garg
215bab7924 mac_ipacl: new MAC policy module to limit jail/vnet IP configuration
The mac_ipacl policy module enables fine-grained control over IP address
configuration within VNET jails from the base system.
It allows the root user to define rules governing IP addresses for
jails and their interfaces using the sysctl interface.

Requested by:	multiple
Sponsored by:	Google, Inc. (GSoC 2019)
MFC after:	2 months
Reviewed by:	bz, dch (both earlier versions)
Differential Revision: https://reviews.freebsd.org/D20967
2023-07-26 00:07:57 +00:00
Mike Karels
a1b6757313 arm64 lib32: enable building of lib32 on arm64
Enable LIB32 option on aarch64, defaulting to YES; it had defaulted
to "broken".  Add required variables for how to compile lib32 on
arm.  Use /usr/include/arm for armv7 (32-bit) headers, analogous to
/usr/include/i386 on amd64.  Omit libomp from lib32; it is not
supported on armv7.

Reviewed by:	jrtc27
Differential Revision:	https://reviews.freebsd.org/D40945
2023-07-25 18:59:52 -05:00
Jessica Clarke
7f9318a022 bsd.linker.mk: Use :C not :S for regex
Whilst ^ and $ are supported with C, those are special cases, and
general regex syntax like groups and alternations are not. Use the
correct modifier so we get a version number out that's not 0 (which is
what happens when it can't be parsed by the later code).

Fixes:		c4177f5b41 ("bsd.linker.mk: Handle Xcode 15 linker identification")
MFC after:	1 week
2023-07-24 01:50:55 +01:00
Jessica Clarke
c4177f5b41 bsd.linker.mk: Handle Xcode 15 linker identification
The upcoming Xcode 15 introduces a new linker (called ld-prime or ld-new
in some documentation) to replace the classic ld64, which we need to
handle.

Previously, the linker would identify itself as:

  @(#)PROGRAM:ld  PROJECT:ld64-<version>

Now, there are two cases. When the classic ld64 is in use, it identifies
itself as:

  @(#)PROGRAM:ld-classic  PROJECT:ld64-<version>

When the new linker is in use, it identifies itself as:

  @(#)PROGRAM:ld  PROJECT:dyld-<version>

Thus, tweak the detection to allow a -classic suffix in the PROGRAM
string and to allow a dyld- prefix instead of an ld64- prefix on the
version number in the PROJECT string.

MFC after:	1 week
2023-07-24 01:34:17 +01:00
Kristof Provost
47d0c1fe7d pf.conf.5: document SCTP support
Mention SCTP in the pf.conf.5

Reviewed by:	tuexen
MFC after:	3 weeks
Sponsored by:	Orange Business Services
Differential Revision:	https://reviews.freebsd.org/D40870
2023-07-21 12:32:19 +02:00
John Baldwin
92053e4f8a share/mk: Pass -znoexecstack to ld.bfd when linking libraries and programs.
lld assumes -znoexecstack by default whereas ld.bfd still defaults to
-zexecstack in the absence of .note.GNU-stack annotations.  Adding the
flags centrally avoids having to patch various libraries in the tree
as one-offs (e.g. OpenSSL 3 is the current thing generating new
warnings with ld.bfd).

Reviewed by:	emaste
Differential Revision:	https://reviews.freebsd.org/D41120
2023-07-20 16:37:46 -07:00
Minsoo Choo
0c3eaa06b3 Remove perforce tools and references
Perforce has been retired since 2019 (commit feea78990c), so there is
no need anymore to keep perforce tools.  Plus, there is no need to
mention perforce admin.

Reviewed by:	emaste, Olivier Certner
Differential Revision:	https://reviews.freebsd.org/D41106
2023-07-20 13:33:39 -04:00
Mateusz Piotrowski
9e850513da style.Makefile.5: Wordsmith .PATH description
MFC after:	3 days
Fixes:	1ac5586c6d style.Makefile.5: Do not require $FreeBSD$ SCM IDs
2023-07-17 15:06:02 +02:00
Mateusz Piotrowski
22faf70d7e style.Makefile.5: Remove $FreeBSD$ from examples
MFC after:	3 days
2023-07-17 15:01:52 +02:00
Mateusz Piotrowski
73fb7a7a73 style.Makefile.5: Stop documenting NO_MAN
NO_MAN has been an error since 2020 according to UPDATING.

PR:		231357
MFC after:	3 days
2023-07-17 14:52:28 +02:00
Doug Rabson
5ac2a874d0 /etc/rc.subr: rename sysctl.conf.d to sysctl.kld.d
This better reflects the intent that this directory is indexed by kld
name and removes a conflict with D32128 which aims to split sysctl.conf.

Reviewed by:	kevans imp
MFC after:	2 weeks
Differential Revision: https://reviews.freebsd.org/D41043
2023-07-15 14:16:08 +01:00
Doug Rabson
09267cc152 /etc/rc.subr: add support for kld sysctl variables
For kernel modules loaded by scripts in /etc/rc.d and
/usr/local/etc/rc.d, if there is a file in /etc/sysctl.conf.d named <kld
name>.conf, then this will be loaded using the sysctl(8) utility. For
instance, sysctl variable changes for the pf kernel module would be
placed in the file /etc/sysctl.conf.d/pf.conf.

PR:		272129
Reviewed by:	imp freebsd_igalic.co
MFC after:	2 weeks
Differential Revision: https://reviews.freebsd.org/D40886
2023-07-14 10:49:47 +01:00