toolchain: Correct LLVM_BINUTILS pkg pkg dependency
The LLVM binutils are in the clang package.
Reported by: jlduran
Fixes: c4f08d46c7f7 ("llvm-*: Move all LLVM_BINUTILS symlinks to toolchain package")
tests/carp: Rework unicast_v4
For unicast tests, it is sufficient to use wait_for_carp() to verify
the setup is sane. Additional sanity checks are not necessarily
required but can serve purpose for redundancy.
For some unclear reason routed(8) is advertising route to carp BACKUP.
That makes the test flaky. Also routed(8) is marked deprecated and may
be removed from base in the future. Let's just add static route entry
manually for additional sanity checks.
Other noticeable changes:
1. Add atf_check to configuration steps to prevent potential failure
on setup. That helps diagnosing on failure.
2. Shorten the names of jails to improve readability.
3. Prefer `[ifconfig|route|sysctl] -j` over `jexec [ifconfig|route|sysctl]`
to make the lines shorter.
PR: 294817
[4 lines not shown]
blocklistd: Fix RFC1918 typo
The address in the configuration file example was intended to be from
the 192.168.0.0/16 range of IPv4 private addresses (RFC1918).
Reported on mastodon.social at
https://mastodon.social/@asmodai/116316630762241486.
Fix submitted upstream by emaste@. Fixing locally first.
Reviewed by: emaste
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D56773
bsd.endian.mk: Optimize the handling of big/little endian determination.
Add variables to contain lists of MACHINE_ARCH values to use
to determine little or big endian.
Only error out about not being able to determine endianess if
TARGET_ENDIANNESS is empty and not cross-compiling.
Reviewed by: sjg
Obtained from: Hewlett Packard Enterprise Development LP
Differential Revision: https://reviews.freebsd.org/D44629
nfsd: Get rid of NFSD_VNET macros
When the nfsd was vnet'd, the VNET macros were hidden
behind macros that had the NFSD_ prefix on them.
This was done because, at the time, it was thought
that something other than vnet might be used for this.
That has not happened and probably will not happen,
so this patch replaces these obscuring macros with
the regular vnet ones.
There should be no semantics change caused by
this commit.
Discussed with: bz, glebius
MFC after: 1 month
libzpool: force inlining of xxhash after removing xxhash.c
libzpool had a number of undefined symbols related to xxhash after
xxhash.c was removed from the build.
Fixes: 8a62a2a5659d ("zfs: merge openzfs/zfs at f8e5af53e")
Reviewed by: jhb
Differential Revision: https://reviews.freebsd.org/D56770
nfscl: Fix handling of gssd upcalls for the NFS client
Without this patch, all upcalls to the gssd daemon are
done in vnet0 (outside of any vnet jail). This does
not work well, because a user principal's credential
cache can be within the jail (/tmp/krb5cc_NNN in the
jail's namespace).
This patch modifies the client so that RPCs done
from within vnet jails does an upcall to a gssd
daemon running within the vnet jail. It required
that the cache of uid->credential shorthands in
the rpcsec_gss be vnet'd.
The situation is still less than ideal and sec=krb5[ip]
mounts that are visible within vnet jails is still
not something I would recommend, but it can work ok
with this patch.
[6 lines not shown]
ctl_ioctl_frontend: Reject out-of-range initiator IDs
Various places in CTL assume that initiator IDs are not larger than
CTL_MAX_INIT_PER_PORT. Other IDs such as lun IDs are validated in
places such as ctl_scsiio_precheck, but initiator IDs submitted by
userland were not previously validated.
PR: 291059
Reported by: Hans Rosenfeld <rosenfeld at grumpf.hope-2000.org>
Reviewed by: asomers
Sponsored by: Chelsio Communications
Differential Revision: https://reviews.freebsd.org/D56628
ping: fix listing test cases when scapy is not installed
The ATF-python test program was attempting to list test cases that
require scapy. But it attempted to import the scapy module before the
test cases had been listed, resulting in an ImportError that kyua
interpreted as a test program crash.
Fix this behavior by handling that ImportError well enough to list test
cases, but not run them. If scapy isn't present, Kyua will refuse to
run the test cases. But it needs to be able to list them in order to
know to skip them.
Sponsored by: ConnectWise
MFC after: 2 weeks
Reviewed by: maxim
Differential Revision: https://reviews.freebsd.org/D56765
lib/msun: Replaced pattern to force exception in _num families
Replaced the old pattern of using a ternary to force addition
(raising exceptions for sNaN's) with a new one using a volatile
variable. The _mag_num family was already implemented with this pattern
PR: 294719
Reviewed by: fuz, kargl
MFC after: 1 month
ping: use CLOCK_REALTIME for ICMP Originate Timestamp
RFC 792 defines the ICMP Originate Timestamp field as milliseconds
since midnight UTC. However, ping(8) currently derives this value
from CLOCK_MONOTONIC, which represents time since an unspecified
starting point and is not related to UTC.
The issue was introduced by commit 1ad76f1b6047, which replaced
gettimeofday(2) with clock_gettime(CLOCK_MONOTONIC) for timekeeping
in ping(8).
Fix this by using CLOCK_REALTIME when generating the ICMP originate
timestamp.
Before:
$ ping -Mt -c1 127.0.0.1
ICMP_TSTAMP
PING 127.0.0.1 (127.0.0.1): 56 data bytes
[15 lines not shown]
llvm-*: Move all LLVM_BINUTILS symlinks to toolchain package
Some of the LLVM binary utilities were included in the Clang package
(because they did not set an explicit PACKAGE).
Add a new Makefile under clang/toolchain to create the symlinks and man
links for ar, c++filt, nm, and so on (without the llvm-* prefix) when
LLVM_BINUTILS is enabled (as it is by default).
PR: 293610
Reviewed by: bapt, ivy, brooks
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55692
powerpc: refactor dmamap setup; free dmamap in error paths
* refactor the dmamap allocation / setup path for future code changes
to align with arm64 busdma code;
* free the dmamap allocation if the dma segment list can't be allocated;
* free the dmamap allocation during the busdma dmamem allocation path
if the actual memory allocation itself fails.
Locally tested:
* POWER9 ppc64le native boot, Raptor Engineering Blackbird
* POWER8 ppc6le, IBM POWER S822LC
https://reviews.freebsd.org/D56244
powerpc: busdma declaration shuffling
Shuffle some of the declarations around to match other implementations.
Expected to be a no-op.
Differential Revision: https://reviews.freebsd.org/D56243
powerpc: use local flags for bounce buffers instead of common flags
Migrate to using local flags for bounce buffers instead of the
common flag field.
Differential Revision: https://reviews.freebsd.org/D56208
powerpc: add in some busdma domain setup
* Implement the basic tag domain set routine
* Set the domain to the parent domain if provided
This is just plumbing for eventual work to re-allocate things into
the currently configured domain.
Differential Revision: https://reviews.freebsd.org/D55315
powerpc: create a tag with the parents implementation if supplied
If a parent tag is supplied then use its implementation.
Differential Revision: https://reviews.freebsd.org/D55314
powerpc: initial straight port of busdma_machdep.c -> busdma_bounce.c
This is a straight port of the code and doesn't yet handle
different implementations (which will be in a subsequent commit.)
Locally tested:
* G5 SMP (2x PPC970mp)
* power8 / power9 pseries QEMU VM
* power8 powernv
Differential Revision: https://reviews.freebsd.org/D55313
namei: Preserve ABI root for absolute symlinks before fallback
D40479 changed namei() so that an absolute symlink target
encountered during an ABI-root lookup restarts from the native root.
This helps the native fallback case, but it also makes successful
lookups inside an ABI root escape that root while following absolute
symlinks.
Only switch absolute symlink lookup to the native root after namei()
is already in the restarted/native fallback pass.
Do not mark the lookup as restarted merely because an absolute
symlink was encountered while still resolving inside the ABI root.
This preserves the intended native fallback behavior while keeping
absolute symlinks within a successfully resolved ABI-root path in
the ABI namespace.
Signed-off-by: Ricardo Branco <rbranco at suse.de>
PR: 289739
[3 lines not shown]
Revert 00bee6fcd77f, which partially reverted libc++ commit aa7f377c965c
After base 966fb94cb357, this revert is no longer necessary: stdint.h
will unconditionally define macros such as `SIZE_MAX`, `UINT64_C`, and
others.
Submitted by: Nikolas Klauser <nikolasklauser at berlin.de>
MFC after: 1 month
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D56746
Define stdint.h macros unconditionally
Similar to glibc, define all the stdint.h macros such as `SIZE_MAX`,
`UINT64_C`, etc unconditionally. I.e. no longer check whether
`__STDC_CONSTANT_MACROS` or `__STDC_LIMIT_MACROS` are defined. See also
<https://sourceware.org/bugzilla/show_bug.cgi?id=15366>.
This is part of reverting base 00bee6fcd77f, which reverted an upstream
libc++ commit that eliminated libc++'s stdint.h wrapper header.
Submitted by: Nikolas Klauser <nikolasklauser at berlin.de>
MFC after: 1 week
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D56746
tail(1): Fix -r (reverse) to work on pseudo filesystems
Pseudo filesystems (e.g., procfs) advertise a zero file size.
Fix reverse() to handle such a case similarly as forward() so
that '-r' works on pseudo filesystems.
Signed-off-by: Aaron LI <aly at aaronly.me>
Reviewed by: pouria, Ricardo Branco <rbranco at suse.de>, des
Fixes: 1fb3caee7 ("tail: Do not trust st_size if it equals zero.")
Pull-Request: https://github.com/freebsd/freebsd-src/pull/2080
(cherry picked from commit 4feeca3193c316c18472cd40f215446fda3bd739)
tail(1): Fix -r (reverse) to work on pseudo filesystems
Pseudo filesystems (e.g., procfs) advertise a zero file size.
Fix reverse() to handle such a case similarly as forward() so
that '-r' works on pseudo filesystems.
Signed-off-by: Aaron LI <aly at aaronly.me>
Reviewed by: pouria, Ricardo Branco <rbranco at suse.de>, des
Fixes: 1fb3caee7 ("tail: Do not trust st_size if it equals zero.")
Pull-Request: https://github.com/freebsd/freebsd-src/pull/2080
(cherry picked from commit 4feeca3193c316c18472cd40f215446fda3bd739)