x86: change signatures of ipi_{bitmap,swi}_handler() to take pointer
to the frame instead of the frame itself. It is some stretch of the
amd64 ABI, and is not easily fullfilled when handlers are called from C
and not asm. In particular, the struct frame is passed by value but is
modified by callees, with the expectation that the caller will see the
modifications.
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D55679
sys: Don't pass RF_ALLOCATED to bus_alloc_resource*
This is a nop as eventually these flags are passed to rman_reserve_resource
which unconditionally sets RF_ALLOCATED in the new flags for a region.
However, it's really a layering violation to use RF_ALLOCATED in relation
to struct resource objects outside of subr_rman.c as subr_rman.c uses
this flag to manage it's internal tracking of allocated vs free regions.
In addition, don't document this as a valid flag in the manual. I
think the intention here was that if a caller didn't want to pass
RF_ACTIVE or RF_SHAREABLE, they could pass RF_ALLOCATED instead of 0,
but given the layering violation, I think it's best to just pass 0
instead in that case.
NB: The bhnd bus uses RF_ALLOCATED (along with RF_ACTIVE) in a
separate API to manage resource regions that are not struct resource
objects (but a separate wrapper object). It would perhaps be cleaner
if the chipc_retain_region and chipc_release_region functions used
their own flag constants instead of reusing the rman(9) flags.
[3 lines not shown]
devinfo: Support PCI DBSF and ACPI handles for -p
When matching on a name of a device, match on ACPI handles and PCI
selectors in addition to device names. This can be useful for
matching on devices without an attached driver.
For example: devinfo -p pci0:0:31:0
Reviewed by: imp
Sponsored by: Chelsio Communications
Differential Revision: https://reviews.freebsd.org/D55673
iwlwifi: update Intel's mvm/mld drivers
This version is based on
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
05f7e89ab9731565d8a62e3b5d1ec206485eeb0b ( tag: v6.19 ).
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
nvme: Don't active memory space until all BARs are configured
In the current current behavior the 2nd and 3rd BARs can be activated
when they're configured with address zero. This change defers the
activation of all BARs until after they've all been configured with an
address.
This enables FreeBSD on Google Compute Engine C4-LSSD Machines.
Sponsored by: Google
Tested by: NetApp (previous version)
Reviewed by: gallatin, imp
Discussed with: jrtc27 (improved error reporting)
Differential Revision: https://reviews.freebsd.org/D55541
iwx: Re-activate the 32-bit boundary cross check on 64-bit architectures
__SIZEOF_*__ is in bytes, not in bits...
Reported by: brooks
Fixes: 35da55c28dbb ("iwx: Fix 32-bit compilation")
MFC after: 1 minute
MFC to: stable/15
Sponsored by: The FreeBSD Foundation
(cherry picked from commit c1567d49a8320fd23dff9dbce1186f2331538253)
style.9: Encourage style changes when doing significant modifications
The rule of allowing style changes when about half or more of a file (or
group of files), coupled with the advice of avoiding stylistic changes,
could be interpreted as forbidding most style changes, even in heavily
modified functions.
In order to rule out that interpretation and ease transition towards our
prescribed style:
1. Clarify that avoiding stylistic changes concerns only "standalone"
ones.
2. Actually encourage changing the style, and extend the cases where it
is explicitly allowed to do so to any single logical unit as little
as a function, keeping the existing "about half" of modified code as
a rule of thumb.
When point 2 above applies, encourage to commit pure style changes
separately, and to add style-only commits to '.git-blame-ignore-revs'.
[15 lines not shown]
iwx: Re-activate the 32-bit boundary cross check on 64-bit architectures
__SIZEOF_*__ is in bytes, not in bits...
Reported by: brooks
Fixes: 35da55c28dbb ("iwx: Fix 32-bit compilation")
MFC after: 1 minute
MFC to: stable/15
Sponsored by: The FreeBSD Foundation
llvm-cxxfilt: Install as c++filt only with LLVM_BINUTILS
When building WITHOUT_LLVM_BINUTILS /usr/bin/c++filt is the one from
ELF Tool Chain.
PR: 293610
Fixes: 5d757312ad59 ("build: Retire LLVM_CXXFILT option")
Sponsored by: The FreeBSD Foundation
splice: optionally limit worker queues
Add a new tunable/sysctl (kern.ipc.splice.num_wq) which can be used
to limit the number of splice worker queues as a way to limit
splice cpu use.
The default (-1) keeps the current behavior of running one worker
for each core in the system. An administrator can set it to 0 (either
via tunable, or before the first splice call via sysctl) to
effectively disable splice, or some number smaller than the number of
cores to limit splice thread use.
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D55579
Sponsored by: Netflix
usr.bin: Exclude ELF Tool Chain cxxfilt build
when LLVM_BINUTILS is enabled (which is the default).
PR: 293610
Fixes: 5d757312ad59 ("build: Retire LLVM_CXXFILT option")
Sponsored by: The FreeBSD Foundation
rtadvd: add multi pref64 support
Add support for multi pref64 in rtadvd and rtadvctl
Reviewed By: zlei, bz
Differential Revision: https://reviews.freebsd.org/D54636
libc/quad: fix missing closing #endif in Symbol.map
Without this lib32 libc.so.7 would be missing critical symbols,
including malloc / free and all syscall wrappers.
iwlwifi: adjust driver description
Adjust the module driver descriptions for mvm and mld to make it clear
that this is not a driver for Linux but a Linux-based driver for FreeBSD.
Cleanup surroundings.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
iwlwifi: mld: add LINUXKPI_PARAM_PREFIX
Add a LINUXKPI_PARAM_PREFIX to mld to properly export the
power_scheme module_param (sysctl). This is especially needed given
mvm has the same parameter and we need to avoid a clash.
Sponsored by: The FreeBSD Foundation
MFC after: 3 days
iwlwifi: mld: move module_init() to SI_ORDER_SECOND
In FreeBSD the iwlwifi driver is a single kernel module.
As for iwlwifi/mvm we need to make sure the common "iwlwifi drv" code
is initialized before trying to register the mld sub-driver
in order for lists, etc. in the registration code to be initialized.
We do this by using an extended (FreeBSD specific) version of
module_init which overrides the order parameter of the SYSINIT.
Otherwise we can randomly (depending on SYSINIT run order) run into
a NULL pointer deref panic.
Sponsored by: The FreeBSD Foundation
PR: 291120
MFC after: 3 days
Update in preparation for 14.4-RELEASE
- Bump BRANCH to RELEASE
- Add the anticipated RELEASE announcement date
- Set a static __FreeBSD_version
Approved by: re (implicit)
Sponsored by: OpenSats Initiative
lesspipe: Allow zstd to operate on a symlink
By default zstd refuses to operate on symlinks, so for example
`zless /var/crash/vmcore.last.zst` failed to view the uncompressed core
file. Add -f to the zstd command line to allow operation on symlinks.
Reviewed by: delphij
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55101
(cherry picked from commit b4305c90a3be7e1a40b76545b8b761fdbda5c309)
(cherry picked from commit 68125692efacbce537e14ba16ecedff750cccc36)
lesspipe: Allow zstd to operate on a symlink
By default zstd refuses to operate on symlinks, so for example
`zless /var/crash/vmcore.last.zst` failed to view the uncompressed core
file. Add -f to the zstd command line to allow operation on symlinks.
Reviewed by: delphij
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D55101
(cherry picked from commit b4305c90a3be7e1a40b76545b8b761fdbda5c309)
vfs: add VOP_DELAYED_SETSIZE() and related infrastructure
The change generalizes code that was initially developed for nfs client
to handle filesystems that needs to call vnode_pager_setsize() while
only owning the vnode lock shared. Since vnode pager might need to trim
or extend the vnode vm_object' page queue, the vnode lock for the call
must be owned exclusive. This is typical for filesystems with remote
authorative source of file attributes, like nfs/p9/fuse.
Handle the conflict by delaying the vnode_pager_setsize() to the next
vnode locking to avoid relock. But if the next locking request is in
shared mode, lock it exclusively instead, perform the delayed
vnode_pager_setsize() call by doing VOP_DEFAULT_SETSIZE(), and then
downgrade to shared.
Filesystems that opt into the feature must provide the implementation of
VOP_DELAYED_SETSIZE() that actually calls vnode_pager_setsize(), and use
vn_delay_setsize() helper to mark the vnode as requiring the delay call.
[5 lines not shown]