FreeBSD/src 266022bcontrib/openresolv resolvconf.in resolvconf.8.in

contrib/openresolv: MFV openresolv 3.17.4

Reviewed by:    pfg
Approved by:    lwhsu (mentor)
Differential Revision:  https://reviews.freebsd.org/D56269

(cherry picked from commit cb0e3a5fba5fe48607db8c1042bfe6a1164e0db7)
DeltaFile
+770-237contrib/openresolv/resolvconf.in
+141-85contrib/openresolv/resolvconf.8.in
+142-40contrib/openresolv/resolvconf.conf.5.in
+159-0contrib/openresolv/resolvectl.in
+96-0contrib/openresolv/systemd-resolved.in
+57-25contrib/openresolv/libc.in
+1,365-38711 files not shown
+1,514-42717 files

FreeBSD/src f7675fasys/compat/freebsd32 freebsd32_systrace_args.c freebsd32_syscall.h, sys/kern systrace_args.c

Regen
DeltaFile
+26-0sys/kern/systrace_args.c
+26-0sys/compat/freebsd32/freebsd32_systrace_args.c
+6-0sys/sys/sysproto.h
+2-1sys/sys/syscall.h
+2-1sys/compat/freebsd32/freebsd32_syscall.h
+2-1sys/sys/syscall.mk
+64-36 files not shown
+72-312 files

FreeBSD/src 3e8b68clib/libsys pdfork.2 Makefile.sys

pdfork.2: document pdopenpid(2)

Reviewed by:    markj
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+68-0lib/libsys/pdfork.2
+1-0lib/libsys/Makefile.sys
+69-02 files

FreeBSD/src 5a5affdlib/libsys pdfork.2

pdfork.2: clarify that PD_DAEMON acts on current file

Also do not start a new list for each flag item.

Reviewed by:    markj
MFC after:      1 week
Sponsored by:   The FreeBSD Foundation
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+8-2lib/libsys/pdfork.2
+8-21 files

FreeBSD/src 1cced49lib/libsys pdfork.2

pdfork.2: document EINVAL for pdwait(2)

Reviewed by:    markj
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+5-0lib/libsys/pdfork.2
+5-01 files

FreeBSD/src d6ff3bblib/libsys Symbol.sys.map, sys/sys procdesc.h

libsys: export pdopenpid(2)

Reviewed by:    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+1-0sys/sys/procdesc.h
+1-0lib/libsys/Symbol.sys.map
+2-02 files

FreeBSD/src 606061esys/bsm audit_kevents.h, sys/kern sys_procdesc.c syscalls.master

sys: add AUE_PDOPENPID

Reviewed by:    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+10-0sys/security/audit/audit_bsm.c
+3-0sys/kern/sys_procdesc.c
+1-1sys/kern/syscalls.master
+1-0sys/bsm/audit_kevents.h
+15-14 files

FreeBSD/src 5c32aa7sys/kern sys_procdesc.c syscalls.master, sys/sys procdesc.h

kern: add pdopenpid(2)

Reviewed by:    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+102-12sys/kern/sys_procdesc.c
+7-0sys/kern/syscalls.master
+2-0sys/sys/procdesc.h
+111-123 files

FreeBSD/src c0e1201sys/kern sys_procdesc.c, sys/sys procdesc.h file.h

procdesc: make PD_DAEMON per-file

Reviewed by:    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+17-9sys/kern/sys_procdesc.c
+6-1sys/sys/procdesc.h
+1-0sys/sys/file.h
+24-103 files

FreeBSD/src 18b6bb5sys/kern sys_procdesc.c kern_exit.c, sys/sys procdesc.h

procdesc: track count of open files

Introduce pd_fpcount that counts the number of file references to the
procdesc.  Remove the PDF_CLOSED flag, now it is expressed as
pd_fpcount == 0.

Only send SIGKILL and clear pointers when we are closing the last file
referencing procdesc.

This should be nop until the next commit.

Reviewed by:    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+11-6sys/kern/sys_procdesc.c
+2-2sys/kern/kern_exit.c
+3-1sys/sys/procdesc.h
+16-93 files

FreeBSD/src 90b560fsys/kern sys_procdesc.c

sys_procdesc: extract procdesc_destroy()

Reviewed byL    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+9-3sys/kern/sys_procdesc.c
+9-31 files

FreeBSD/src 9747701sys/kern sys_procdesc.c

sys_procdesc: extract pdtofdflags()

Reviewed by:    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+12-7sys/kern/sys_procdesc.c
+12-71 files

FreeBSD/src 599d021sys/kern sys_procdesc.c

sys_procdesc: extract procdesc_alloc()

Reviewed by:    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+24-12sys/kern/sys_procdesc.c
+24-121 files

FreeBSD/src aa1694esys/kern sys_procdesc.c

procdesc_exit(): assert that _exit() was called

Check that the P_WEXIT flag is set.

Requested by:   markj
Reviewed by:    markj
Tested by:      pho
Sponsored by:   The FreeBSD Foundation
MFC after:      1 week
Differential revision:  https://reviews.freebsd.org/D57124
DeltaFile
+1-0sys/kern/sys_procdesc.c
+1-01 files

FreeBSD/src bdbad7bcontrib/openresolv resolvconf.in resolvconf.8.in

contrib/openresolv: MFV openresolv 3.17.4

Reviewed by:    pfg
Approved by:    lwhsu (mentor)
Differential Revision:  https://reviews.freebsd.org/D56269

(cherry picked from commit cb0e3a5fba5fe48607db8c1042bfe6a1164e0db7)
DeltaFile
+770-237contrib/openresolv/resolvconf.in
+141-85contrib/openresolv/resolvconf.8.in
+142-40contrib/openresolv/resolvconf.conf.5.in
+159-0contrib/openresolv/resolvectl.in
+96-0contrib/openresolv/systemd-resolved.in
+57-25contrib/openresolv/libc.in
+1,365-38711 files not shown
+1,514-42717 files

FreeBSD/src d516e52sys/fs/nfs nfs.h, sys/fs/nfsserver nfs_nfsdkrpc.c nfs_nfsdport.c

nfsd: Optionally enable use of M_EXTPG mbufs for read replies

A test site determined that, for a Mellanox NIC which can handle
M_EXTPG mbufs, an improvement of 5-15% for read rate could be
achieved if the read reply was in M_EXTPG mbufs.

A patch that tried to determine if the outbound NIC supported
M_EXTPG mbufs (IFCAP_MEXTPG) did not pass review.
However, it does appear that this can be useful for NFS-over-RDMA.
(Which just happen to use NICs that do support M_EXTPG mbufs.)

As such, this patch enables them is xp_extpg is set to true,
which is never for now, but might be set true for RDMA or
when vfs.nfsd.enable_mextpg is set non-zero. (It is 0 by
default, so this is never enabled by default at this time.)

Tested by:      Greg Becker <becker.greg at att.net>
MFC after:      2 weeks
DeltaFile
+17-1sys/fs/nfsserver/nfs_nfsdkrpc.c
+10-6sys/fs/nfsserver/nfs_nfsdport.c
+5-2sys/fs/nfsserver/nfs_nfsdserv.c
+1-0sys/fs/nfs/nfs.h
+1-0sys/rpc/svc.h
+34-95 files

FreeBSD/src ee5d87asys/netinet raw_ip.c

raw ip: fix race of two connect(2)

The historical design of sockets is that on a re-connect the disconnect is
performed at the socket layer in soconnectat().  Since SMP times this is
known to be racy and the function has appopriate comment.  I missed that
in the recent change.  The pr_connect method should normally expect the
socket to be already disconnected, however should be able to handle a race
where socket is actually connected.  Convert the check that incorrectly
tried to handle normal path of re-connect into check that handles the
race.

Reported by:    markj
Fixes:  ece716c5d34728a170f1dfe1b3389c267d6ddd1e
DeltaFile
+1-2sys/netinet/raw_ip.c
+1-21 files

FreeBSD/src 4dd9e4esys/powerpc/booke pmap_32.c

powerpc/booke(pmap): Flash-invalidate TLB on TID rollover

When the TID rolls over on a given CPU, simply flash-invalidate the
TLB instead of walking the TLB to only invalidate the repurposed TID.
Walking 256 entries is expensive, and we'll likely be inserting a bunch
new ones anyway in the new environment, since 256 really only handles
1MB of storage, so the likelihood of other mappings continuing to exist
in the TLB when their thread owner is scheduled again is very very
small.
DeltaFile
+2-22sys/powerpc/booke/pmap_32.c
+2-221 files

FreeBSD/src dec79d2sys/powerpc/booke pmap.c

powerpc/pmap(booke): Fix TLB TID eviction

Fix tid_set_busy() for when `pmap` is NULL. Obviously a NULL pointer
cannot be correctly used, so I'm not sure how it worked in testing on
64-bit.
DeltaFile
+8-5sys/powerpc/booke/pmap.c
+8-51 files

FreeBSD/src 5f4c87etools/tools/git git-mfc

git-mfc: Allow merging merge commits

In order to merge merge commits (such as vendor imports), we need to
tell git cherry-pick which of the two branches referenced in the commit
is the mainline.  In our case, it is always the first.

Approved by:    markj
DeltaFile
+1-1tools/tools/git/git-mfc
+1-11 files

FreeBSD/src f01c509lib/libsysdecode mktables, sys/netpfil/pf pf_nl.h

pf: revert netlink commands back to enum

Revert pf_nl.h part of 017690e50913 and use new libsysdecode build glue
that parses enums.

Reviewed by:    kp, glebius
Differential Revision:  https://reviews.freebsd.org/D57866
DeltaFile
+52-51sys/netpfil/pf/pf_nl.h
+1-1lib/libsysdecode/mktables
+53-522 files

FreeBSD/src 8b19780lib/libsysdecode mktables

libsysdecode: Teach mktables to handle enums

While here, clean up and simplify the existing code.

MFC after:      1 week
Reviewed by:    glebius, jhb
Differential Revision:  https://reviews.freebsd.org/D57993
DeltaFile
+40-21lib/libsysdecode/mktables
+40-211 files

FreeBSD/src 6a6d6d7cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/scripting tst.sid.ksh tst.uid.ksh

dtrace tests: Fix finding multiple process results

When looking up self process we can use `ps -p $$` directly rather
than grep which may find other processes ending in the expected PID.

Sponsored by:   Dell Inc.
Reviewed by:    markj, vangyzen
Differential Revision: https://reviews.freebsd.org/D58019
DeltaFile
+1-1cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/scripting/tst.sid.ksh
+1-1cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/scripting/tst.uid.ksh
+1-1cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/scripting/tst.euid.ksh
+1-1cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/scripting/tst.egid.ksh
+1-1cddl/contrib/opensolaris/cmd/dtrace/test/tst/common/scripting/tst.gid.ksh
+5-55 files

FreeBSD/src d7d7134lib/libc/posix1e acl_from_text.c

acl_from_text.c: Allow negative uid/gid numbers to be handled

getfacl / acl_to_text() incorrectly prints uid/gid numbers as signed integers.
This causes uid / gid numbers larger than 2G (2147483648) to print as
negative numbers.
The libc acl_from_text() function does not handle negative numbers.
This diff adds a backwards compatiblity fix to allow negative numbers...

Reviewed by:    rmacklem
MFC after:      2 weeks
Differential Revision:  https://reviews.freebsd.org/D57180
DeltaFile
+32-9lib/libc/posix1e/acl_from_text.c
+32-91 files

FreeBSD/src bf142easys/net if_ovpn.c

if_ovpn: Fix memory leak in VNET during unload

Unloading if_ovpn while it's in use by other vnets causes
memory leaks and panics.
Fix this by reverting VNET_SYSUNINIT and adjusting the SI_SUB
initialization order.

Reviewed by:    markj
MFC after:      1 week
Differential Revision: https://reviews.freebsd.org/D54175
DeltaFile
+12-8sys/net/if_ovpn.c
+12-81 files

FreeBSD/src 3838aee. libcrux_internal.h libcrux_mlkem768_sha3.h, regress/unittests/crypto/testdata nistkats-44.json

Vendor import of OpenSSH 10.4p1

Sponsored by:   The FreeBSD Foundation
DeltaFile
+27,332-0libcrux_internal.h
+0-11,752libcrux_mlkem768_sha3.h
+1,869-1,349ChangeLog
+1,435-509servconf.c
+539-585moduli
+802-0regress/unittests/crypto/testdata/nistkats-44.json
+31,977-14,195171 files not shown
+37,630-15,689177 files

FreeBSD/src 7a0b9e3lib/clang/libllvmminimal Makefile

libllvmminimal: Fix building with LLVM < 21 on riscv64

On most architectures we end up not needing ABIBreak.cpp as, although
some of the sources here do reference EnableABIBreakingChecks (or, if
assertions are disabled, DisableABIBreakingChecks) at a source level, we
compile with -ffunction-sections and -fdata-sections, and link with
--gc-sections, and it happens to be the case that all references can be
GC'ed. However, prior to LLVM 21, the RISC-V backend did not apply
-fdata-sections to .sdata, where references to these symbols end up, and
for some files we're building with such references we end up not being
able to GC .sdata due to the other unrelated data in it, meaning that we
do in fact need to build ABIBreak.cpp.

Whilst we could make this conditional on the architecture, it's a tiny
file, and it's a bit fragile to rely on GC behaviour, so just include it
unconditionally.

Reviewed by:    dim, emaste
Fixes:          770cf0a5f02d ("Fixups after llvm-project main llvmorg-21-init-19288-gface93e724f4 merge")

    [2 lines not shown]
DeltaFile
+1-1lib/clang/libllvmminimal/Makefile
+1-11 files

FreeBSD/src 58c7372sys/kern vfs_syscalls.c

vfs: Fix resource leaks in kern_symlinkat()

Fixes:          2ec2ba7e232d ("vfs: Add VFS/syscall support for Solaris style extended attributes")
Reported by:    Yuxiang Yang, Yizhou Zhao, Ao Wang, Xuewei Feng, Qi Li,
                and Ke Xu from Tsinghua University using GLM-5.2 from Z.ai
Reviewed by:    rmacklem, kib
MFC after:      1 week
Sponsored by:   The FreeBSD Foundation
Differential Revision:  https://reviews.freebsd.org/D58053
DeltaFile
+1-3sys/kern/vfs_syscalls.c
+1-31 files

FreeBSD/src 3516403sys/arm64/vmm vmm_hyp.c vmm_arm64.c, sys/arm64/vmm/io vgic_v3.c vtimer.c

arm64/vmm: Make remaining registers use hypctx_*_sys_reg

Move vgic, timer and trapframe registers into sys_regs to handle them
in the same way as all the other registers.

Signed-off-by:  Kajetan Puchalski <kajetan.puchalski at arm.com>
Reviewed by:    andrew
Sponsored by:   Arm Ltd
Differential Revision:  https://reviews.freebsd.org/D56556
DeltaFile
+74-61sys/arm64/vmm/vmm_hyp.c
+63-47sys/arm64/vmm/vmm_arm64.c
+33-32sys/arm64/vmm/vmm_hyp_exception.S
+42-4sys/arm64/vmm/arm64.h
+24-22sys/arm64/vmm/io/vgic_v3.c
+18-18sys/arm64/vmm/io/vtimer.c
+254-1846 files not shown
+301-22212 files

FreeBSD/src e3cd6d1sys/arm64/vmm vmm_hyp.c arm64.h

arm64/vmm: Refactor vmm_hyp.c

Refactor vmm_hyp.c to split register reload logic by type of register,
streamline the implementation and improve readability.

Signed-off-by:  Kajetan Puchalski <kajetan.puchalski at arm.com>
Reviewed by:    andrew
Sponsored by:   Arm Ltd
Differential Revision:  https://reviews.freebsd.org/D56553
DeltaFile
+229-179sys/arm64/vmm/vmm_hyp.c
+6-0sys/arm64/vmm/arm64.h
+235-1792 files