Commit Graph

24613 Commits

Author SHA1 Message Date
Ed Maste
5654b42142 libusb: claim to be version 1.0.16
We are not 100% compatible with 1.0.16, but implement some
functionality from that version that is required by certain ports.

PR:		277799
PR:		279555 (exp-run)
Event:		Kitchener-Waterloo Hackathon 202406
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D45514
2024-06-28 12:18:34 -04:00
Alexander Ziaee
088cc7d221 man filesystems: fix more xrefs after move to s4
Fixes: 1a720cbec5
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1282
2024-06-27 18:32:05 -06:00
Ryan Libby
07cc7ea738 libmsun: remove duplicates after cdefs.h added inline to __always_inline
Reviewed by:	kib, olce
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D45712
2024-06-25 10:40:14 -07:00
Andrew Turner
8521ea135f Revert "WIP: Switch to compiler-rt sync on armv7"
This reverts commit 940cf92c07.

This wasn't ready to be committed
2024-06-25 09:37:38 +00:00
Andrew Turner
940cf92c07 WIP: Switch to compiler-rt sync on armv7 2024-06-25 09:07:19 +00:00
Ryan Libby
012e32c665 libthr: move __always_inline to canonical position
Ahead of including inline in __always_inline, move __always_inline to
where inline goes.

Reviewed by:	imp, kib, olce
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D45710
2024-06-24 10:05:58 -07:00
David E. O'Brien
5bcc33d1e0 ppoll(2) was actually added in 10.2 2024-06-23 16:13:28 -07:00
David E. O'Brien
3dd248798d procctl(2) actually appeared in 9.3 2024-06-23 16:13:28 -07:00
Gordon Bergling
16c3d7e1fa erf.3: Add a STANDARDS section
Add a STANDARDS section for the erf(3) manual page.

PR:	273413
Reviewed by:	pauamma_gundo.com
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D44140
2024-06-23 12:50:47 +02:00
Warner Losh
fa1e8538d1 math.h: Remove support for old gcc versions
Remove support for old gcc versions by unconditionally defining
__MATH_BUILTIN_RELOPS and __MATH_BUILTIN_CONSTANTS. Per kib's request,
don't #undef those so it's easier to understand what the builtins are
doing.

Reviewed by:		brooks
Differential Revision:	https://reviews.freebsd.org/D45655
Sponsored by:		Netflix
2024-06-20 20:41:09 -06:00
Baptiste Daroussin
e402155e1a ncurses: reinstantiate bsd specific code
This fixes ncurses 6.5 badly reading termcap
2024-06-20 20:27:15 +02:00
Baptiste Daroussin
21817992b3 ncurses: vendor import version 6.5 2024-06-20 13:26:22 +02:00
Andrew Turner
6eeedf35c3 libc: Replace armv6 with armv7 in a comment
Armv6 is being removed from the treem and the comment applies to armv7.

Reviewed by:	manu, imp, emaste
Sponsored by:	Arm Ltd
Differential Revision:	https://reviews.freebsd.org/D45645
2024-06-20 09:26:22 +00:00
Brooks Davis
42c545c5f8 libsys: sort Symbol.map
Fixes:		7448408656 Make __libsys_interposing_slot libsys only
2024-06-19 23:08:05 +01:00
Brooks Davis
d511e97c54 libsysdecode: support rfork(RFSPAWN)
Match the "U" in RFSPAWN's value (1U<<31) (and "u" for completeness).
Reject kernel-only RFPPWAIT to avoid a duplicate entry.

Reviewed by:	imp, markj
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D45597
2024-06-19 21:38:31 +01:00
Pedro F. Giffuni
fc3907ce00 fparseln: Update license
Remove 3rd and 4th clauses in christos' license. OK christos.

Obtained from:	NetBSD
2024-06-15 18:30:27 -05:00
Pedro F. Giffuni
9a39435c0b Revert "fparseln: Update NetBSD version strings"
This reverts commit 1a968da448.

I was mistakenly looking at the version strings in the CVS attic
but the function was moved to libc/stdio where it matches the
current string.
2024-06-15 17:46:56 -05:00
Pedro F. Giffuni
1a968da448 fparseln: Update NetBSD version strings
The correponding changes (mostly ANSIfication) were done long ago locally.
No functional change.

Obtained from:	NetBSD (libutil CVS Attic)
2024-06-15 15:32:06 -05:00
Andrew Turner
b8a496dfb6 lib: Remove __ARM_ARCH checks that are always true
Reviewed by:	imp
Differential Revision:	https://reviews.freebsd.org/D45559
2024-06-12 11:49:05 +00:00
Ed Maste
e77ad954bb Revert "libm: fma: correct zero sign with small inputs"
This change introduced a test failure, so revert until that can be
addressed.

This reverts commit 888796ade2.

PR:		277783
Reported by:	rlibby
Sponsored by:	The FreeBSD Foundation
2024-06-11 21:36:12 -04:00
Ed Maste
92927b8bcf msun: update Clang bug reference in fma test
LLVM bugzilla bug 8100 became issue #8472 with the migration to GitHub.

https://github.com/llvm/llvm-project/issues/8472
2024-06-11 20:29:27 -04:00
Ryan Libby
e754909cb0 virstor: remove relation between chunk size and MAXPHYS
There's no reason why the virstor chunk size needs to relate to MAXPHYS.
Remove it.  Instead, just make sure that the chunk size is a multiple of
the sector size.

Reviewed by:	imp
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D45518
2024-06-10 17:38:17 -07:00
Ryan Libby
a2fda816eb virstor: write large maps in chunks during label
During the initial label of a virstor device, write out the allocation
map in chunks if it is large (> 1 MB) in order to avoid large mallocs.

Even though the kernel virstor geom may still do a large malloc to
represent the allocation map, this may still be useful to avoid a
ulimit.

Reviewed by:	markj
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D45517
2024-06-10 17:36:20 -07:00
Mark Johnston
da925fcebf libc/tests: Further refine the condition for installing h_raw
See 8164d511d6 ("libc/tests: Fix installation without MK_TOOLCHAIN")
for some background.  Here we should really be testing MK_CLANG instead,
since that's what gates compilation of libclang_rt.

Fixes:	8164d511d6 ("libc/tests: Fix installation without MK_TOOLCHAIN")
2024-06-09 10:08:31 -04:00
Ed Maste
888796ade2 libm: fma: correct zero sign with small inputs
PR:		277783
Reported by:	Victor Stinner
Submitted by:	kargl
MFC after:	1 week
Differential Revision: https://reviews.freebsd.org/D44433
2024-06-08 11:55:36 -04:00
Kristof Provost
ba2a920786 pf: convert DIOCBEGINADDRS to netlink 2024-06-08 04:46:43 +02:00
Kristof Provost
d9ab899931 pf: migrate DIOCGETLIMIT/DIOCSETLIMIT to netlink
Event:		Kitchener-Waterloo Hackathon 202406
2024-06-07 20:59:02 +02:00
Dapeng Gao
7cae020b9c Simplify signal handling code in libthr by removing use of SYS_sigreturn
The use of SYS_sigreturn is unnecessary here.

If handle_signal is called when a signal is delivered, it can just
return normally back to sigcode which will call sigreturn anyway.

In case handle_signal is called by check_deferred_signal, using
setcontext is better than SYS_sigreturn because that is the correct
system call to pair with the earlier getcontext.

Reviewed by:	imp, kib
Differential Revision:	https://reviews.freebsd.org/D44893
2024-06-06 15:48:39 -06:00
Kristof Provost
30bad751e8 pf: convert DIOCGETTIMEOUT/DIOCSETTIMEOUT to netlink 2024-06-06 20:46:18 +02:00
Andreas Kempe
230efeda08 libusbhid: add missing include guards
PR:		265136
2024-06-06 10:09:05 -04:00
Enji Cooper
77c04f3eb1 radlib: fix a memory leak in is_valid_request
Call `HMAC_CTX_free` if returning early from `is_valid_request` when
processing `Message-Authenticator` tags.

Reported by:	Coverity
MFC after:	1 week
Fixes: 8d5c781306 ("libradius: Fix input validation bugs")
Differential Revision:	https://reviews.freebsd.org/D45488
2024-06-04 19:40:55 -07:00
Warner Losh
623d432b15 typo: Fix side -> size since it matters to the meaning...
batch side doesn't make sense, but batch size does. Fix.

Sponsored by:		Netflix
2024-06-04 10:59:01 -06:00
Kristof Provost
c36c90a2cc pf: convert DIOCSETDEBUG to netlink
Sponsored by:	Rubicon Communications, LLC ("Netgate")
2024-06-04 14:59:59 +02:00
Kristof Provost
71d3c7041d pf: convert DIOCNATLOOK to netlink
Sponsored by:	Rubicon Communications, LLC ("Netgate")
2024-06-04 14:59:58 +02:00
Kristof Provost
9dbbe68bc5 pf: convert DIOCCLRSTATUS to netlink
Sponsored by:	Rubicon Communications, LLC ("Netgate")
2024-06-04 14:59:58 +02:00
Xin LI
3b35e7ee8d MFV: xz 5.6.2.
MFC after:	4 weeks
2024-06-03 18:14:43 -07:00
Mariusz Zaborski
bb421be6c1 libutil: move ftime to libutil
It seems that there are still some applications that use ftime(3)
(for example, science/siconos and sysutils/lcdproc). The issue
is that we don't build libcompat as a shared library anymore.
The easiest solution is to move it to libutil, until we
deprecate it for good.

This solution was proposed by kib@ in
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=257789.

PR:		257789
MFC after:	1 month
Reviewed by:	kib (ages ago)
Differential Revision:	https://reviews.freebsd.org/D39994
2024-05-29 14:36:09 +02:00
Kristof Provost
cd2054d48b libpfctl: add pfctl_get_rule_h()
Add a handle variant of pfctl_get_rule(). This converts us from using
the nvlist variant to the netlink variant, and also moves us closer to a
world where all libpfctl functions take the handle.

While here have pfctl use the new function.

Sponsored by:	Rubicon Communications, LLC ("Netgate")
2024-05-28 22:27:22 +02:00
Mark Johnston
8164d511d6 libc/tests: Fix installation without MK_TOOLCHAIN
There is some exotic conditional logic here to avoid building a
particular test if a certain UBSAN library isn't present in the
toolchain sysroot.  This causes build failures for me when doing an
"installworld WITHOUT_TOOLCHAIN=", which I do frequently during tests.

I believe the problem is that SYSROOT is unset during installworld, so
the build sees the host's copy of libclang_rt.ubsan_standalone.a and
then tries to install a binary that wasn't built during buildworld.  Try
to make the check a bit less fragile.

Reviewed by:	dim
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D45035
2024-05-28 08:24:43 -04:00
Mariusz Zaborski
e24ff5c99b libcapsicum: cache more time zone information
The functions like gmtime(3) expect to cache a GMT time zone. Some
sandboxed programs (like last(1)) use the gmtime(3) function.
In case of last(1), this function fails to load a proper time zone
because it is called after entering the capability mode.

_open () at _open.S:4
0x00000008011bc5a8 in tzloadbody (name=0x8018b9580 "/usr/share/zoneinfo/Etc/UTC", sp=0x801870140,
tzload (name=<optimized out>, sp=0x801870140, doextend=true)
0x00000008011bb8ba in gmtload (sp=0x801870140) at /usr/src/contrib/tzcode/localtime.c:1456
gmtcheck () at /usr/src/contrib/tzcode/localtime.c:1581
0x000000080111f85a in _libc_once (once_control=0x80127c550, init_routine=0x0)
_once (once_control=0x80127c550, init_routine=0x0) at /usr/src/lib/libc/gen/_once_stub.c:63
0x00000008011bb9d0 in gmtime_r (timep=0x7fffffffe3a8, tmp=0x80127c568)
gmtime (timep=timep@entry=0x7fffffffe3a8) at /usr/src/contrib/tzcode/localtime.c:1865
0x0000000001024cd4 in printentry (bp=bp@entry=0x8018b4800, tt=tt@entry=0x80186a0a0)
0x00000000010245ae in doentry (bp=0x8018b4800)
0x00000000010243a7 in main (argc=1, argv=<optimized out>)

This time zone is not loaded by the tzset(3) function. Because of
that, extend the caph_cache_tzdata(3) function to also include the
GMT time zone. There is no other way to cache this data than
calling gmtime(3) once.

MFC after:	5 days
Reviewed by:	emaste, markj
Differential Revision:	https://reviews.freebsd.org/D45297
2024-05-27 13:17:34 +02:00
Andre Albsmeier
cca0ce62f3 pam_xdg: pam_get_item can return NULL
Fix pam_xdg as pam_get_item can return NULL, this happens when pressing
control + C in xdm for example.

MFC after:	1 week
PR:		279268
2024-05-27 08:33:14 +02:00
Warner Losh
364c014d9b cross-tools: fts has different types for cmp routine
fts has different types for its compare rotuine. Other systems, not
4.4BSD based, have a non-const version. Before we tested against
__GLIBC__, but now we test against __linux__ because that's Linux's API
and musl doesn't define __GLIBC__.

In addition, link against libftl on this platform since musl doesn't
include ftl routines in libc, but rather in libftl.

Co-authored-by:		Val Packett <val@packett.cool>
Sponsored by:		Netflix
Pull Request:		https://github.com/freebsd/freebsd-src/pull/1066
Reviewed by:		val_packett.cool
Differential Revision:	https://reviews.freebsd.org/D45349
2024-05-26 11:38:30 -06:00
Ed Maste
61639bb3fc libc: move NIS xdr_* symbols from rpc's to yp's Symbol.map
To fix WITHOUT_NIS build.  Building yp_xdr.c is gated by MK_NIS.

PR:		279270
Reported by:	peterj
Reported by:	matteo
Reported by:	Michael Dexter's Build Option Survey run
Reviewed by:	brooks
Sponsored by:	The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D45347
2024-05-24 16:47:37 -04:00
Dimitry Andric
3a0793336e Merge llvm-project release/18.x llvmorg-18.1.6-0-g1118c2e05e67
This updates llvm, clang, compiler-rt, libc++, libunwind, lld, lldb and
openmp to llvm-project release/18.x llvmorg-18.1.6-0-g1118c2e05e67.

PR:		276104
MFC after:	3 days
2024-05-24 17:58:04 +02:00
Ricardo Branco
ddbfb544c6 mqueuefs: Relax restriction that path must begin with a slash
This is needed to support Linux implementation which discards the leading slash when calling mq_open(2)

Reviewed by: imp, kib
Pull Request: https://github.com/freebsd/freebsd-src/pull/1248
2024-05-23 13:40:46 -06:00
Tom Hukins
2ce32ab21a Fix "version introduced" in two manual pages
Signed-off-by: Tom Hukins <tom@FreeBSD.org>
Reviewed by: imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1252
2024-05-23 10:30:32 -06:00
Brooks Davis
fcc5fa091e libcompiler_rt: gcc13 doesn't support _Float16 on arm
Don't set CRT_COMMON_F16_ARCH for arm as it's not supported by gcc13.

Differential Revision:	https://reviews.freebsd.org/D45234
2024-05-23 17:27:37 +01:00
Brooks Davis
6729e8a40b libpmc: remove tautological assert
gcc13 whines about this assert than an unsigned integer is >= 0.

Reviewed by:	luporl
Fixes:		b48a2770d4 powerpc64: add Power8 and Power9 PMCs
Differential Revision:	https://reviews.freebsd.org/D45232
2024-05-23 17:27:37 +01:00
Christos Margiolis
1ab62c8d06 mixer.3: Fix mandoc -Tlint warnings
Sponsored by:	The FreeBSD Foundation
MFC after:	1 day
Reviewed by:	emaste
Differential Revision:	https://reviews.freebsd.org/D45290
2024-05-23 02:57:49 +02:00
Christos Margiolis
67c89b21b9 mixer(3): Implement mixer_get_path() function
This is better than hardcoding device paths in mixer applications.

Sponsored by:	The FreeBSD Foundation
MFC after:	1 day
Reviewed by:	dev_submerge.ch
Differential Revision:	https://reviews.freebsd.org/D45275
2024-05-23 02:57:36 +02:00