sigqueue: In capability mode, only allow signalling self
This is copied from the check in kern_kill.
Reviewed by: markj, oshogbo
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D57244
divert: Avoid using atomic_(load|store)_(acq|rel)_16
It's not implemented on some arches. Use a plain int to count the
number of sockets in a divert lbgroup.
Reported by: Jenkins
Fixes: 895a0ae67fe2 ("divert: Define semantics for SO_REUSEPORT_LB on divert sockets")
amd64: Drop segment descriptor details from trap messsages
Segment descriptor contents are fixed on amd64 and not very interesting
compared to the other values that are displayed.
While here, include both the thread and process details of the current
thread and drop redundant output of the trap number.
Reviewed by: kib
Differential Revision: https://reviews.freebsd.org/D56989
nlist.3: Replace a.out(5) Xref with elf(5)
ELF support was added to nlist() in 1997, and a.out support was removed
in 2020. The man page was not updated for either of these changes.
Fixes: 77909f597881 ("Initial elf nlist support, ...")
Fixes: 86cfa7e70b2b ("nlist: retire long-obsolete aout support")
Sponsored by: The FreeBSD Foundation
(cherry picked from commit 876a17321c896427d70de94101df4d888a19189b)
struct nlist is documented in both a.out(5) and stab(5), so add an Xref
to the latter.
(cherry picked from commit 762e451b318c8cbfddbcaaa92a218e8b45306eb9)
nlist.3: Clarify which symbol table is used
nlist() requires section headers, and currently fetches symbol names
only from SHT_SYMTAB,
Reviewed by: kib
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D57065
(cherry picked from commit cd6bf930eafe850dc631feeaf8332832601f4225)
nlist.3: Add discouraged use notice
It is a relic from a.out days and is poorly specified. Although ELF
support was added to nlist, there are better ways to access ELF data.
Reviewed by: kib
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D57078
(cherry picked from commit 94b7a335683abcbcd76e8b67d37e21271d81590c)
unbound: Tweak freebsd-configure script
Regenerating the configure script is optional and can introduce noise
if the installed versions of autoconf, automake, and libtool do not
match those used upstream. Tweak our script slightly so it will skip
this step if libtoolize is not found.
(cherry picked from commit cd69bc03cf67b958e08206d49562903c57b5bd28)
unbound: Tweak freebsd-configure script
Regenerating the configure script is optional and can introduce noise
if the installed versions of autoconf, automake, and libtool do not
match those used upstream. Tweak our script slightly so it will skip
this step if libtoolize is not found.
(cherry picked from commit cd69bc03cf67b958e08206d49562903c57b5bd28)
divert: Define semantics for SO_REUSEPORT_LB on divert sockets
Allow SO_REUSEPORT_LB to be set on divert sockets. If set, then bind()
will add the socket to a "load-balancing group". When a divert-to rule
matches a port with an associated group, the corresponding state ID is
used to select a specific socket from the group. Packets without an
associated state are simply forwarded to the first socket in the group.
For now I only pass a state ID from pf, as I couldn't see a useful
identifier on the ipfw side.
This implementation is simple but has a caveat, that being that if
sockets are added to the group while flows are being processed, the size
of the group will change and this changes the mapping of state IDs to
sockets. So, to get a consistent mapping, the divert socket application
must bind all of its sockets before any traffic is diverted by the
firewall.
Reviewed by: glebius
MFC after: 1 month
[3 lines not shown]
bhyve/virtio-scsi: Support multiple backends
In order to support multiple backends for virtio-scsi, we should isolate
the core of virtio-scsi from the backend-specific code. The existing
interface to CTL will become the new "CTL" backend for virtio-scsi.
Care has been taken to keep compatibility with previous configurations:
The first backend linked (CTL) will be the default backend if none is
specified, and it does provide a default configuration if no further
options such as targets are explicitly configured.
Reviewed by: markj
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D53223
bhyve/virtio-scsi: Make all I/O processing parameters configurable
This includes:
- seg_max, the number of segments allowed in a single command
- {ctl,evt,req}_ringsz, the number of descriptors in a queue
- thr_per_q, the number of processing threads per request queue
- num_queues, the number of request queues
Reviewed by: markj
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D54073