Remove extra slashes that end up in the metalog. These double slashes
can produce an invalid specification file if there are subdirectories
down the hierarchy when sorted.
For example, consider the following metalog excerpt:
./base/aaa type=dir
./base//aaa/bbb type=dir
If sorted, would turn out:
./base//aaa/bbb type=dir
./base/aaa type=dir
Apparently missing the ./base/aaa directory in the specification.
Luckily here are no subdirectories.
Reviewed by: imp, emaste
Approved by: emaste (mentor)
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D48779
(cherry picked from commit bccaf0262dcab84be49c42cc6b7a81c279c44b62)
Remove an extra slash that ends up in the metalog. This double slash
can produce an invalid specification file if there are subdirectories
down the hierarchy when sorted.
For example, consider the following metalog excerpt:
./base/aaa type=dir
./base//aaa/bbb type=dir
If sorted, would turn out:
./base//aaa/bbb type=dir
./base/aaa type=dir
Apparently missing the ./base/aaa directory in the specification.
Luckily here are no subdirectories.
Reviewed by: imp, emaste
Approved by: emaste (mentor)
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D48778
(cherry picked from commit 841856570e7b623c4f1283939936ffa005d2fcf4)
ETSI had one 160Mhz band in regdomain but the other two were missing.
Add them. I am always confused that the bands use the center frequency
of the 20Mhz edge channels rather than the actual edges so it seems we
are only configuring 140Mhz instead of 160Mhz.
We will have to go through the entire regdomain file one
day and make sure to verify all the power levels.
Sponsored by: The FreeSBD Foundation
Reviewed by: adrian
Differential Revision: https://reviews.freebsd.org/D48356
(cherry picked from commit a3a308f0f29b14d522c56dd88231e27fdf206104)
Standardize the definition of a UFS dinode
Differential Revision: https://reviews.freebsd.org/D48472
(cherry picked from commit 1111a44301da39d7b7459c784230e1405e8980f8)
(cherry picked from commit aa90fbed151de512ab6e59f75df009533a15751f)
(cherry picked from commit 256389eaf158acaf67f0530764be8af68edee78c)
(cherry picked from commit 6cd973d903c8f214d84daf91eb75047631bf1618)
(cherry picked from commit e1ebda4458bbaf7d85fb803e20f3afc5441f24d9)
These tests create a linked list with one entry for every group on the
running system. On a system with about 30,000 groups, the test took 69
seconds to run, and crashed Kyua with the below error:
kyua: E: string or blob too big (sqlite op: sqlite3_bind_blob) (sqlite db: /root/.kyua/store/results.usr_tests.20241231-203317-570235.db).
Fix the test by limiting it to operating on the first 1024 groups.
Apply the same change to getpw_test and getserv_test too, which are
vulnerable to the same problem.
Sponsored by: ConnectWise
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D48275
(cherry picked from commit d11904b350214943dedb64c7121d4602799d7afd)
len is unsigned (it is size_t), so cannot be negative.
Sponsored by: The FreeBSD Foundation
(cherry picked from commit fab411c4fd5224e3dd44e0eb288d60b27480e2d1)
We previously claimed that non-page-aligned addresses would return
EINVAL, but the address is in fact rounded down to the page boundary.
Reported by: Harald Eilertsen <haraldei@anduin.net>
Reviewed by: brooks
Sponsored by: The FreeBSD Foundation
Fixes: dabee6fecc ("kern_descrip.c: add fdshare()/fdcopy()")
Differential Revision: https://reviews.freebsd.org/D48465
(cherry picked from commit 9e36aaf0c24cf158e83c69c1d2312c000c3c36f3)
Regroup assignments tweaking preprocessor defines/undefs, and separately
those about include directories.
Re-order include directories a bit more logically, and remove redundant
ones.
Separate logical groups by blank lines.
Build artifacts have been verified to stay the same when produced with
an external LLVM 18 toolchain.
MFC after: 1 month
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D48070
(cherry picked from commit 618c97b87b7124cdfb10d2f33a213c3302c8a98b)
libder will be used in upcoming ECC support in the pkg(7) bootstrap to
read DER-encoded keys and signatures.
(cherry picked from commit f59bb61e1eb4d1e4fc3c60cc14779d0668267cb2)
When a hotplug callback has been registered, and the program using
libusb is calling libusb_exit then the thread handler is set to
NO_THREAD which result in the variable controlling the loop the be set
to 0, it does a last pass through device available without having done
a scan, which result in a sigbus after it tried to unregister all the
devices.
directly break the loop instead and cleanup the list of devices
this fixes the tests with LGPLed libusb's hotplugtest program
MFC After: 3 days
Reviewed by: kevans
Differential Revision: https://reviews.freebsd.org/D48298
(cherry picked from commit ba5834b8e11fd002a663d083a464e397e76cb3a9)
This reverts commit caab831338f4eeaa7455e981478be9fd414b7969, because
some new unresolved issues came up in bug 271087:
Some programs depend on these symbols, when they are compiled for armv6
or armv7. Closes#1560 (slightly changed due to sorting of the symbols).
PR: 271087
Reported by: mmel
MFC after: immediately
(cherry picked from commit b662ca1d6cd82044c6cb79075e1830b97594bef3)
Some programs depend on these symbols, when they are compiled for armv6
or armv7. Closes#1560 (slightly changed due to sorting of the symbols).
PR: 271087
Reported by: fuz
Submitted by: jfc@mit.edu
MFC after: 1 week
(cherry picked from commit caab831338f4eeaa7455e981478be9fd414b7969)
This matches the man page for qsort_s().
PR: 281828
Signed-off-by: Graham Percival <gperciva@tarsnap.com>
Sponsored by: Tarsnap Backup Inc.
(cherry picked from commit d0a3fd34a05794bc5cbf48709001a78e9f85169a)
- Add some missing .Pp macros after the end of literal blocks and some
lists to ensure there is a blank line before the following text.
- Use an indent of Ds for nested lists to reduce excessive indentation and
make the bodies of the nested list items easier to read.
- Various and sundry rewordings and clarifications.
Reviewed by: kib, emaste
Differential Revision: https://reviews.freebsd.org/D47782
(cherry picked from commit 8277c790179304159c2e4dcb1d99552518d5be8e)
These were reported by `mandoc -T lint` as
ERROR: skipping unknown macro
When these pages were rendered with `man`, the "unknown macro" meant
that the entire line was omitted from the output.
Obvious typos in:
lib/libsys/swapon.2
lib/libsys/procctl.2
share/man/man9/firmware.9
lib/libcasper/services/cap_net/cap_net.3: 'mode' describes a function
argument.
lib/libsys/statfs.2: there's no .Tm command ("trademark?"), and
.Tn ("tradename") is deprecated, so remove the macro entirely.
usr.sbin/mfiutil/mfiutil.8: man was interpreting '/dev/' as a macro
(which it didn't recognize).
share/man/man4/qat.4: same issue as above, but with '0'. In this case,
given the context of the previous line, rewriting as "Value '0'"
seemed more appropriate.
usr.sbin/mlx5tool/mlx5tool.8: typo in .Xr
Signed-off-by: Graham Percival <gperciva@tarsnap.com>
Sponsored by: Tarsnap Backup Inc.
Reviewed by: concussious, imp
Pull Request: https://github.com/freebsd/freebsd-src/pull/1417
(cherry picked from commit 2878d99dfcfbdd7a415a7f31cf95fbd53fc8e581)
This change updates the version of expat referenced from 2.6.0 to 2.6.3,
correcting documentation post-ffd294a1f4c23863c3e515d16dce31d5509bcb01.
Bump .Dd for the change.
MFC with: ffd294a1f4c23863c3e515d16dce31d5509bcb01
Differential Revision: https://reviews.freebsd.org/D46865
(cherry picked from commit ba23ab2168ffabc2c5e647a1a37ab9a8fb482bb8)
The day-of-week calculation used the raw year value without adjusting
for TM_YEAR_BASE, so it was off by one for 300 years out of every 400;
it just happened to be correct for 1901 through 2000. It also used a
loop where a simple addition would have sufficed.
While here, simplify our version of Gauss's algorithm, and document
that we assume the Gregorian calendar.
MFC after: 1 week
PR: 282916
Reviewed by: imp, allanjude, philip
Differential Revision: https://reviews.freebsd.org/D47977
(cherry picked from commit 4285e024baa80f81d13cdcc016fdf0721fe57862)
OpenZFS release 2.2.7
Notable upstream pull request merges:
#15457022bf8637 Increase L2ARC write rate and headroom
#155271ba5b2ef8 freebsd: remove __FBSDID macro use
#157929e7af55e8 Add custom debug printing for your asserts
#15793a1ea40af8 libzfs: use zfs_strerror() in place of strerror()
#16181 -multiple zdb/ztest: improve and harmonise crash output
#16208e5e4957a5 Allow block cloning to be interrupted by a signal
#16210ba4e582a6 FreeBSD: Add const qualifier to members of struct
opensolaris_utsname
#16225a6198f34b Simplify issig()
#1633525ec9a903 zdb: fix BRT dump
#16364cf80a803d zvol: ensure device minors are properly cleaned up
#16404384b53be8 FreeBSD: Add missing memory reclamation accounting
#16492 -multiple Split "shared" userspace & kernel code into separate files
#16496f1694496a zfs_file: rename zfs_file_fallocate to zfs_file_deallocate
#16511bc0d89bfc Fix an uninitialized data access
#165292dc8529d9 Fix handling of DNS names with '-' in them for sharenfs
#1653930ea44296 zfs_log: add flex array fields to log record structs
#16546098789216 Evicting too many bytes from MFU metadata
#1655154278533a Reduce and handle EAGAIN errors on AIO label reads
#1655484ad1d536 FreeBSD: restore zfs_znode_update_vfs()
#1656521c40e6d9 FreeBSD: Sync taskq_cancel_id() returns with Linux
#1656748482bb2f Properly release key in spa_keystore_dsl_key_hold_dd()
#16584e8f4592a1 Avoid computing strlen() inside loops
#16605acc8a3186 ARC: Cache arc_c value during arc_evict()
#16650fc60e0c6e freebsd: Use compiler.h from FreeBSD's base's linuxkpi
#16667b32b35cea zdb: show bp in uberblock dump
#166841f5e1b919 Pack dmu_buf_impl_t by 16 bytes
#1668873b3e8ace Fix gcc uninitialized warning in FreeBSD zio_crypt.c
#16690727506c94 On the first vdev open ignore impossible ashift hints
#16692d83cd5307 zdb: add extra -T flag to show histograms of BRT refcounts
#1669382ab837a0 Fix gcc unused value warning in FreeBSD simd.h
#167402bba6e3c5 BRT: Don't call brt_pending_remove() on holes/embedded
#16801299da6ace Fix race in libzfs_run_process_impl
Obtained from: OpenZFS
OpenZFS commit: e269af1b3c
OpenZFS tag: zfs-2.2.7
When replacing a disk, a child process is forked to run a script called
zfs_prepare_disk (which can be useful for disk firmware update or health
check). The parent than calls waitpid and checks the child error/status
code.
However, the _reap_children thread (created from zed_exec_process to
manage zedlets) also waits for all children with the same PGID and can
stole the signal, causing the replace operation to be aborted.
As waitpid returns -1, the parent incorrectly assume that the child
process had an error or was killed. This, in turn, leaves the newly
added disk in REMOVED or UNAVAIL status rather than completing the
replace process.
This patch changes the PGID of the child process execuing the
prepare script, shielding it from the _reap_children thread.
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Reviewed-by: Tony Hutter <hutter2@llnl.gov>
Signed-off-by: Gionatan Danti <g.danti@assyoma.it>
Closes#16801
Moved from libsys to libc for stable/14.
Reviewed by: kib
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D47556
(cherry picked from commit 36887e04947fedfebb9b648fadd0dd6cc03142ea)
With this patch, it is possible to call fchmod() on a unix socket prior
to binding it to the filesystem namespace, so that the mode is set
atomically. Without this, one has to call chmod() after bind(), leaving
a window where threads can connect to the socket with the default mode.
After bind(), fchmod() reverts to failing with EINVAL.
This interface is copied from Linux.
The behaviour of fstat() is unmodified, i.e., it continues to return the
mode as set by soo_stat().
PR: 282393
Reviewed by: kib
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D47361
(cherry picked from commit bfd03046d18776ea70785ca1ef36dfc60822de3b)