OpenBSD cvs log

created 2021-11-21T19:46:33Z
begin 2021-10-20T00:00:00Z
end 2021-10-27T00:00:00Z
path src/sys
commits 93

date 2021-10-20T06:35:39Z
author semarie
files src/sys/kern/vfs_subr.c log diff annotate
src/sys/kern/vfs_vops.c log diff annotate
src/sys/nfs/nfs_node.c log diff annotate
src/sys/sys/vnode.h log diff annotate
src/sys/ufs/ext2fs/ext2fs_subr.c log diff annotate
src/sys/ufs/ffs/ffs_subr.c log diff annotate
src/sys/ufs/ffs/ffs_vfsops.c log diff annotate
message revert vnode: remove VLOCKSWORK and check locking when vop_islocked != nullop
(both kernel and userland bits)

GENERIC + VFSLCKDEBUG is broken with it.

date 2021-10-20T06:35:40Z
author semarie
files src/sys/uvm/uvm_vnode.c log diff annotate
message revert vnode: remove VLOCKSWORK and check locking when vop_islocked != nullop
(both kernel and userland bits)

GENERIC + VFSLCKDEBUG is broken with it.

date 2021-10-20T23:50:20Z
author jsg
files src/sys/dev/pci/drm/drm_edid.c log diff annotate
message drm/edid: In connector_bad_edid() cap num_of_ext by num_blocks read

From Douglas Anderson
a7b45024f66f9ec769e8dbb1a51ae83cd05929c7 in linux 5.10.y/5.10.75
97794170b696856483f74b47bfb6049780d2d3a0 in mainline linux

date 2021-10-21T08:39:33Z
author tobhe
files src/sys/netinet/ip_esp.c log diff annotate
message Remove duplicate variable ibytes, use plen instead.

ok bluhm@

date 2021-10-21T09:59:13Z
author claudio
files src/sys/kern/kern_descrip.c log diff annotate
message Move vfs_stall_barrier() from the fd layer into vn_lock() and the vfs layer.
vfs stalling is used by suspend/resume and by vmt(4) to stall any
filesystem operation from altering the state on disk. All these
operations will call vn_lock and be stalled. Adjust vfs_stall_barrier()
to allow the lock owner to still progress so that suspend can sync
the filesystems after stalling vfs operation.
OK mpi@

date 2021-10-21T09:59:14Z
author claudio
files src/sys/kern/vfs_subr.c log diff annotate
src/sys/kern/vfs_vnops.c log diff annotate
src/sys/sys/file.h log diff annotate
message Move vfs_stall_barrier() from the fd layer into vn_lock() and the vfs layer.
vfs stalling is used by suspend/resume and by vmt(4) to stall any
filesystem operation from altering the state on disk. All these
operations will call vn_lock and be stalled. Adjust vfs_stall_barrier()
to allow the lock owner to still progress so that suspend can sync
the filesystems after stalling vfs operation.
OK mpi@

date 2021-10-21T18:30:57Z
author patrick
files src/sys/arch/arm64/dev/ampintc.c log diff annotate
message Have ampintcmsi(4) go through the list of interrupt controllers to find the
correct parent. So far we were directly calling some ampintc(4) code, which
is fine for regular hardware. With Parallels on the Apple M1, ampintcmsi(4)
is combined with agintc(4), which is quite a surprise. Luckily both types of
interrupt controllers use the same API for passing interrupt information, so
we can craft one structure and both ampintc(4) and agintc(4) will happily work
with it.

ok kettenis@

date 2021-10-21T18:36:41Z
author bluhm
files src/sys/arch/alpha/conf/GENERIC log diff annotate
message Remove hifn(4), safe(4), and ubsec(4) crypto drivers. They require
the asynchronous crypto API which makes progress in MP difficult.
The hardware is rarely available. They support only obsolete crypto
algorithms. Scheduling crypto tasks via PCI is probably slower
than the CPU, especailly as modern CPUs have their own accelerators.

date 2021-10-21T18:36:42Z
author bluhm
files src/sys/arch/amd64/conf/GENERIC log diff annotate
src/sys/arch/i386/conf/GENERIC log diff annotate
src/sys/arch/macppc/conf/GENERIC log diff annotate
src/sys/arch/sparc64/conf/GENERIC log diff annotate
src/sys/dev/pci/files.pci log diff annotate
src/sys/dev/pci/Attic/hifn7751.c log diff annotate
src/sys/dev/pci/Attic/hifn7751reg.h log diff annotate
src/sys/dev/pci/Attic/hifn7751var.h log diff annotate
src/sys/dev/pci/Attic/safe.c log diff annotate
src/sys/dev/pci/Attic/safereg.h log diff annotate
src/sys/dev/pci/Attic/safevar.h log diff annotate
src/sys/dev/pci/Attic/ubsec.c log diff annotate
src/sys/dev/pci/Attic/ubsecreg.h log diff annotate
src/sys/dev/pci/Attic/ubsecvar.h log diff annotate
message Remove hifn(4), safe(4), and ubsec(4) crypto drivers. They require
the asynchronous crypto API which makes progress in MP difficult.
The hardware is rarely available. They support only obsolete crypto
algorithms. Scheduling crypto tasks via PCI is probably slower
than the CPU, especailly as modern CPUs have their own accelerators.

date 2021-10-21T21:47:41Z
author jsg
files src/sys/dev/pci/pcidevs log diff annotate
message add Gemini Lake MEI; from fkr

date 2021-10-21T21:50:16Z
author jsg
files src/sys/dev/pci/pcidevs.h log diff annotate
src/sys/dev/pci/pcidevs_data.h log diff annotate
message regen

date 2021-10-21T22:11:07Z
author mvs
files src/sys/kern/uipc_usrreq.c log diff annotate
message Release solock() before call unp_internalize() and take it within when
access garbage collector data.

This is the next step to make UNIX domain sockets locking fine grained.
This also moves M_WAIT/M_WAITOK allocations out from `unp_lock' rwlock(9).
The lock order between fdplock() and `unp_lock' changed and now fdplock()
should be taken first. This was not required, but helps to mpi@'s knote(9)
related work.

ok bluhm@

date 2021-10-21T22:25:03Z
author patrick
files src/sys/arch/arm64/dev/agintc.c log diff annotate
message Initialize interrupts to G1NS by configuring IGROUPR and IGRPMODR. This
makes interrupts work with Parallels on the Apple M1.

Tested by patrick@ on Ampere eMAG and MacchiatoBin
Tested by fkr@ on Pinebook Pro
ok kettenis@

date 2021-10-21T22:59:07Z
author tobhe
files src/sys/netinet/ip_ah.c log diff annotate
src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipcomp.c log diff annotate
message Remove code to run crypto operations in a task queue. The code was
not reachable because all callers had set the CRYPTO_F_NOQUEUE flag.

ok patrick@ mvs@ bluhm@

date 2021-10-21T22:59:08Z
author tobhe
files src/sys/crypto/crypto.c log diff annotate
src/sys/crypto/cryptodev.h log diff annotate
message Remove code to run crypto operations in a task queue. The code was
not reachable because all callers had set the CRYPTO_F_NOQUEUE flag.

ok patrick@ mvs@ bluhm@

date 2021-10-21T23:03:48Z
author tobhe
files src/sys/crypto/crypto.c log diff annotate
src/sys/crypto/cryptodev.h log diff annotate
message Remove more dead code related to crypto task queues.

date 2021-10-22T04:59:31Z
author anton
files src/sys/dev/wscons/wskbd.c log diff annotate
message One could end up with the wrong encoding in xenocara while having a ucc
keyboard attached and /etc/kbdtype being present. The advertised
encoding of a wsmux is a bit fragile as the last attached device will
dictate it. If this happens to be a ucc keyboard, KB_US will always be
the advertised encoding as its encoding is immutable and /etc/kbdtype is
ignored.

Instead, do not advertise the encoding for ucc devices when the parent
mux queries its attached devices. However, asking the device directly
(i.e. bypassing the mux) still returns the encoding as wsconsctl(8)
would otherwise report an error.

Thanks to landry@ for the report and testing.

date 2021-10-22T05:00:26Z
author anton
files src/sys/kern/sys_pipe.c log diff annotate
message Preserve pipe select(2) semantics when the other end of the pipe is gone.
In preparation for implementing select(2) on top of kqueue.

ok mpi@

date 2021-10-22T05:06:37Z
author anton
files src/sys/dev/softraid_crypto.c log diff annotate
message Remove last dangling usage of CRYPTO_F_NOQUEUE.

ok tb@

date 2021-10-22T08:48:08Z
author jsg
files src/sys/dev/pci/pcidevs log diff annotate
message add Intel ADL-S and ADL-P graphics ids Mesa matches

fix a GMA600 id while here

date 2021-10-22T08:48:46Z
author jsg
files src/sys/dev/pci/pcidevs.h log diff annotate
src/sys/dev/pci/pcidevs_data.h log diff annotate
message regen

date 2021-10-22T12:30:53Z
author bluhm
files src/sys/crypto/cryptodev.h log diff annotate
src/sys/crypto/xform.c log diff annotate
src/sys/crypto/xform.h log diff annotate
src/sys/net/pfkeyv2.c log diff annotate
src/sys/net/pfkeyv2.h log diff annotate
src/sys/net/pfkeyv2_convert.c log diff annotate
src/sys/netinet/ip_ipcomp.c log diff annotate
message After deleting hifn(4) the only provider for the LZS compression
algorithm is gone. Reomve all LZS references from the tree. The
v42bis in isakmpd also looks unsupported.
OK mvs@ patrick@ sthen@

date 2021-10-22T14:28:54Z
author kettenis
files src/sys/dev/fdt/if_dwge.c log diff annotate
message Mask LPI interrupts. This fixes an interrupt storm on dwge(4) variants
that support Energy Efficient Ethernet when connected to a switch that
also supports Energy Effient Ethernet. For example on the odroid-hc4.

ok patrick@

date 2021-10-22T15:11:32Z
author mpi
files src/sys/kern/tty_pty.c log diff annotate
src/sys/kern/uipc_socket.c log diff annotate
src/sys/miscfs/fifofs/fifo_vnops.c log diff annotate
message Make EVFILT_EXCEPT handling separate from the read filter.

This is a change of behavior and events wont be generated if there
is something to read on the fd. Only EV_EOF or NOTE_OOB will now
be reported.

While here a new filter for FIFOs supporting EV_EOF and __EV_HUP.

ok visa@

date 2021-10-22T15:16:50Z
author mpi
files src/sys/kern/sys_pipe.c log diff annotate
message Revert "Preserve select(2) semantics when the other end of the pipe is gone".

The logic to emulate the current poll/select behavior is better implemented
at the syscall layer and not in the kqueue backend.

Discussed with deraadt@, ok anton@

date 2021-10-22T15:44:20Z
author bluhm
files src/sys/netinet/ip_ah.c log diff annotate
src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipcomp.c log diff annotate
src/sys/netinet/ip_ipip.c log diff annotate
src/sys/netinet/ipsec_input.c log diff annotate
src/sys/netinet/ipsec_output.c log diff annotate
message Make error handling in IPsec consistent. Pass errors to the callers.
OK tobhe@

date 2021-10-23T09:36:58Z
author sashan
files src/sys/net/pf_table.c log diff annotate
message YIELD() in pf_table.c should preempt for ioctl() callers only

OK @mpi

date 2021-10-23T12:48:17Z
author kettenis
files src/sys/dev/ic/bwfm.c log diff annotate
src/sys/dev/ic/bwfmvar.h log diff annotate
src/sys/dev/pci/if_bwfm_pci.c log diff annotate
src/sys/dev/sdmmc/if_bwfm_sdio.c log diff annotate
message Make sure we have enough space to add padding and final token to the nvram
data. Also add the MAC address to the nvram data when there is a
"local-mac-address" property in the device tree. This makes bwfm(4) work
with the firmware/nvram/clm_blob files provided with MacOS on the Apple
M1 Macs.

ok patrick@

date 2021-10-23T14:08:46Z
author mpi
files src/sys/kern/vfs_subr.c log diff annotate
message Assert that the KERNEL_LOCK() is held in vref(9).

This is a guard against pushing the lock too far in UVM's vnode land.

ok beck@

date 2021-10-23T14:42:07Z
author mpi
files src/sys/kern/vfs_subr.c log diff annotate
src/sys/uvm/uvm_aobj.c log diff annotate
message Sprinkle uvm_obj_destroy() over UVM object recycling code.

For now, only assert that the tree of pages is empty in uvm_obj_destroy().
This will soon be used to free the per-UVM object lock.

While here call uvm_obj_init() when new vnodes are allocated instead of
in uvn_attach(). Because vnodes and there associated UVM object are
currently never freed, it isn't easy to know where/when to garbage
collect the associated lock. So simply check that the reference of a
given object is 0 when uvn_attach().

Tested by many as part of a bigger diff.

ok kettenis@

date 2021-10-23T14:42:08Z
author mpi
files src/sys/uvm/uvm_device.c log diff annotate
src/sys/uvm/uvm_object.c log diff annotate
src/sys/uvm/uvm_vnode.c log diff annotate
message Sprinkle uvm_obj_destroy() over UVM object recycling code.

For now, only assert that the tree of pages is empty in uvm_obj_destroy().
This will soon be used to free the per-UVM object lock.

While here call uvm_obj_init() when new vnodes are allocated instead of
in uvn_attach(). Because vnodes and there associated UVM object are
currently never freed, it isn't easy to know where/when to garbage
collect the associated lock. So simply check that the reference of a
given object is 0 when uvn_attach().

Tested by many as part of a bigger diff.

ok kettenis@

date 2021-10-23T14:53:02Z
author claudio
files src/sys/sys/proc.h log diff annotate
message ps_sigcode, ps_sigcoderet and ps_sigcookie are immutable after a process
is created. Annotate them accordingly.
OK mpi@

date 2021-10-23T14:56:55Z
author claudio
files src/sys/kern/kern_sig.c log diff annotate
message Be consistend and add missing spaces around some of the NOTREACHED comments.

date 2021-10-23T15:00:11Z
author visa
files src/sys/net/bpf.c log diff annotate
message Fix double free after allocation failure in bpf(4).

Reported by Peter J. Philipp.

OK mpi@

date 2021-10-23T15:42:34Z
author tobhe
files src/sys/arch/amd64/amd64/aesni.c log diff annotate
src/sys/arch/amd64/amd64/via.c log diff annotate
message Retire asynchronous crypto API as it is no longer required by any driver and
adds unnecessary complexity. Dedicated crypto offloading devices are not common
anymore. Modern CPU crypto acceleration works synchronously, eliminating the need
for callbacks.

Replace all occurrences of crypto_dispatch() with crypto_invoke(), which is
blocking and only returns after the operation has completed or an error occured.
Invoke callback functions directly from the consumer (e.g. IPsec, softraid)
instead of relying on the crypto driver to call crypto_done().

ok bluhm@ mvs@ patrick@

date 2021-10-23T15:42:35Z
author tobhe
files src/sys/arch/arm64/arm64/cryptox.c log diff annotate
src/sys/arch/i386/i386/via.c log diff annotate
src/sys/arch/i386/pci/glxsb.c log diff annotate
src/sys/arch/octeon/dev/octcrypto.c log diff annotate
src/sys/crypto/crypto.c log diff annotate
src/sys/crypto/cryptodev.h log diff annotate
src/sys/crypto/cryptosoft.c log diff annotate
src/sys/dev/softraid_crypto.c log diff annotate
src/sys/dev/softraid_raid1c.c log diff annotate
src/sys/netinet/ip_ah.c log diff annotate
src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipcomp.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
src/sys/netinet/ipsec_input.c log diff annotate
src/sys/netinet/ipsec_output.c log diff annotate
message Retire asynchronous crypto API as it is no longer required by any driver and
adds unnecessary complexity. Dedicated crypto offloading devices are not common
anymore. Modern CPU crypto acceleration works synchronously, eliminating the need
for callbacks.

Replace all occurrences of crypto_dispatch() with crypto_invoke(), which is
blocking and only returns after the operation has completed or an error occured.
Invoke callback functions directly from the consumer (e.g. IPsec, softraid)
instead of relying on the crypto driver to call crypto_done().

ok bluhm@ mvs@ patrick@

date 2021-10-23T16:39:03Z
author dv
files src/sys/dev/acpi/acpireg.h log diff annotate
src/sys/dev/acpi/tpm.c log diff annotate
message tpm(4): add support for tpm2 CRB interface

Some modern tpm2 devices require or prefer drivers communicate via
the CRB interface and not the TIS/fifo interface. This change adds
basic support for detecting CRB start mode and using CRB to issue
commands required for proper S4 hibernation. As a result, this also
defines a new struct definition for the TPM2 acpi table required
for start mode detection.

This fixes recent S4 regressions on the Surface Go 2 caused by a
change in firmware from Microsoft.

Other CRB start methods may need implementing in the future to
support additional hardware.

tested by deraadt@ and many others, ok kettenis@

date 2021-10-23T17:38:00Z
author patrick
files src/sys/tmpfs/tmpfs_vnops.c log diff annotate
message Fix tmpfs_lookup locking for ".." == ".". unveil_find_cover() calls
VFS_LOOKUP(dir, &parent) in a loop and looks up the parent directory
".." repeatedly. VFS_LOOKUP is expected to unlock 'dir' and return
'parent' locked.

So tmpfs_lookup() is called for ISDOTDOT and:
- runs with dvp = dir, vpp = &parent
- gets parent from tmpfs_vnode_get() and
- re-locks dir with vn_lock(dvp)
but skips the call to
VOP_UNLOCK(dvp);
on return because *vpp == dvp

The reason for doing so is the lookup for ".". In this case
tmpfs_lookup() just increases the reference on dvp and copies the
pointer:
*vpp = dvp; vref(dvp);

However, in our case we also have *vpp == dvp, but for a different
lookup (ISDOTDOT), so we must do the unlock.

From markus@

date 2021-10-23T17:39:08Z
author patrick
files src/sys/tmpfs/tmpfs_vnops.c log diff annotate
message Call uvm_vnp_uncache() in tmpfs_write(). We currently only call
uvm_vnp_uncache() in tmpfs_write() when a file grows in size. This
is not enough. We need to invalidate UVM's cache of the vnode every
time the contents of the vnode are modified. Failure to do so might
lead to inconsistencies between read/mmap consumers.

From Pedro Martelletto

date 2021-10-23T20:44:42Z
author mvs
files src/sys/kern/uipc_usrreq.c log diff annotate
message sonewconn() returns the pointer to 'socket' struct so check it against
NULL instead of '0'.

ok deraadt@

date 2021-10-23T22:00:51Z
author bluhm
files src/sys/netinet/ip_ipcomp.c log diff annotate
message Fix use-after-free in ipcomp_output() introduced by previous commit.
Retrieve ilen and olen from crypto descriptors before freeing them.
Found by regress/sys/netinet/ipsec.
OK mpi@

date 2021-10-23T22:19:37Z
author bluhm
files src/sys/net/if_bridge.c log diff annotate
src/sys/netinet/ip_ah.c log diff annotate
src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipcomp.c log diff annotate
src/sys/netinet/ip_ipip.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
src/sys/netinet/ipsec_input.c log diff annotate
src/sys/netinet/tcp_subr.c log diff annotate
src/sys/netinet/udp_usrreq.c log diff annotate
message There is an m_pullup() down in AH input. As it may free or change
the mbuf, the callers must be careful. Although there is no bug,
use the common pattern to handle this. Pass down an mbuf pointer
mp and let m_pullup() update the pointer in all callers.
It looks like the tcp signature functions should not be called.
Avoid an mbuf leak and return an error.
OK mvs@

date 2021-10-24T00:02:24Z
author jsg
files src/sys/ddb/db_sym.h log diff annotate
src/sys/kern/kern_exit.c log diff annotate
message use NULL not 0 for pointer values in kern
ok semarie@

date 2021-10-24T00:02:25Z
author jsg
files src/sys/kern/kern_proc.c log diff annotate
src/sys/kern/kern_prot.c log diff annotate
src/sys/kern/kern_sig.c log diff annotate
src/sys/kern/kern_sysctl.c log diff annotate
src/sys/kern/kern_tc.c log diff annotate
src/sys/kern/subr_disk.c log diff annotate
src/sys/kern/subr_userconf.c log diff annotate
src/sys/kern/sys_socket.c log diff annotate
src/sys/kern/tty.c log diff annotate
src/sys/kern/tty_pty.c log diff annotate
src/sys/kern/uipc_syscalls.c log diff annotate
src/sys/kern/vfs_biomem.c log diff annotate
src/sys/kern/vfs_lookup.c log diff annotate
src/sys/kern/vfs_subr.c log diff annotate
message use NULL not 0 for pointer values in kern
ok semarie@

date 2021-10-24T06:59:54Z
author visa
files src/sys/kern/sys_pipe.c log diff annotate
message Make pipe event filters MP-safe

Add the missing f_modify and f_process callbacks so that pipe_lock
serializes pipe knote handling. As pipe klist locking is already in
place, pipe event filters should now be MP-safe.

This uses write locking everywhere in the callbacks for simplicity.
There is not much multiple-readers parallelism to utilize.

OK mpi@ anton@

date 2021-10-24T07:02:47Z
author visa
files src/sys/kern/uipc_socket.c log diff annotate
src/sys/kern/uipc_socket2.c log diff annotate
src/sys/miscfs/fifofs/fifo_vnops.c log diff annotate
src/sys/sys/event.h log diff annotate
message Set klist lock for sockets to make socket event filters MP-safe

The filterops instances already provide f_modify and f_process
callbacks with proper internal locking. Locking of socket klists
has been the missing detail for MP-safety.

OK mpi@

date 2021-10-24T09:16:53Z
author deraadt
files src/sys/dev/pv/vioscsi.c log diff annotate
message pretty & normalize the cfdriver decl

date 2021-10-24T09:18:51Z
author deraadt
files src/sys/arch/luna88k/dev/lcd.c log diff annotate
src/sys/arch/luna88k/dev/sio.c log diff annotate
src/sys/arch/luna88k/luna88k/mainbus.c log diff annotate
message extra 0 fields in cfdriver are not needed

date 2021-10-24T09:59:52Z
author patrick
files src/sys/tmpfs/tmpfs_vnops.c log diff annotate
message Prohibit renames of tmpfs mount-points to fix a panic.

From gerhard@

date 2021-10-24T10:26:22Z
author patrick
files src/sys/arch/amd64/amd64/aesni.c log diff annotate
src/sys/arch/amd64/amd64/via.c log diff annotate
src/sys/arch/arm64/arm64/cryptox.c log diff annotate
src/sys/arch/i386/i386/via.c log diff annotate
src/sys/arch/i386/pci/glxsb.c log diff annotate
src/sys/arch/octeon/dev/octcrypto.c log diff annotate
src/sys/crypto/crypto.c log diff annotate
src/sys/crypto/cryptosoft.c log diff annotate
message Stop setting etype in the MD crypto code. So far we have set the etype
and returned the error, which made the MI crypto code set the etype for
a second time. We still have to set etype after calling the MD process
function, as the callers of crypto_invoke() still expect error handling
to be shown through the etype. But at least now all MD crypto code does
not have to worry about that anymore. Once the callers are changed to
not look at etype anymore, we can get rid of it completely.

ok tobhe@

date 2021-10-24T10:58:43Z
author sashan
files src/sys/net/pf_table.c log diff annotate
message let pf_table.c to use standard way to work with lists

OK todd@, mvs@, kn@

date 2021-10-24T11:23:22Z
author mpi
files src/sys/kern/sys_generic.c log diff annotate
src/sys/miscfs/fifofs/fifo_vnops.c log diff annotate
message Implement poll(2), select(2), ppoll(2) & pselect(2) on top of kqueue.

The given set of fds are converted to equivalent kevents using EV_SET(2)
and passed to the scanning internals of kevent(2): kqueue_scan().

ktrace(1) will now output the converted kevents on top of the usuals set
bits to be able to find possible error in the convertion.

This switch implies that poll(2) and select(2) will now query underlying
kqfilters instead of the *_poll() routines. An increase in latency is
visible, especially with UDP sockets and NET_LOCK()-contended subsystems
and will be addressed in next steps.

Based on similar work done on MacOS and DragonFlyBSD with inputs from
visa@, millert@, anton@, cheloha@, thanks!

Tested by many, thanks!

ok claudio@, bluhm@

date 2021-10-24T13:46:14Z
author mpi
files src/sys/uvm/uvm_aobj.c log diff annotate
message Shuffle variables around and use KASSERT() instead of panic().

No functionnal change.

Reduce differences with NetBSD, tested by many as part of a larger diff.

date 2021-10-24T14:24:29Z
author bluhm
files src/sys/netinet/ip_ah.c log diff annotate
src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipcomp.c log diff annotate
message Pass the error of the IPsec callback to the caller. The dropped
counter is handled there.
OK tobhe@

date 2021-10-24T14:50:42Z
author tobhe
files src/sys/crypto/crypto.c log diff annotate
src/sys/crypto/cryptodev.h log diff annotate
src/sys/dev/softraid_crypto.c log diff annotate
src/sys/dev/softraid_raid1c.c log diff annotate
src/sys/netinet/ip_ah.c log diff annotate
src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipcomp.c log diff annotate
message Remove crp_etype and return errors directly from crypto_invoke()

ok patrick@

date 2021-10-24T14:54:52Z
author patrick
files src/sys/arch/arm64/dev/ampintc.c log diff annotate
message Now that ampintcmsi(4)'s establish function returns a pointer to the
more generic machine intr handle, we need to call intr_barrier() for
it instead.

Panic found by bluhm@
ok kettenis@

date 2021-10-24T15:23:52Z
author mpi
files src/sys/uvm/uvm_km.c log diff annotate
src/sys/uvm/uvm_map.c log diff annotate
message Move pmap_{,k}remove() inside uvm_km_pgremove{,_intrsafe}().

Reduce differences with NetBSD, tested by many as part of a larger diff.

ok kettenis@

date 2021-10-24T15:29:10Z
author visa
files src/sys/arch/mips64/mips64/trap.c log diff annotate
message Unlock top part of UVM fault handler on mips64.

OK mpi@

date 2021-10-24T15:33:12Z
author patrick
files src/sys/tmpfs/tmpfs_vfsops.c log diff annotate
message Add mount -ur/uw support to tmpfs.

From Pedro Martelletto

date 2021-10-24T15:41:47Z
author patrick
files src/sys/tmpfs/tmpfs_vfsops.c log diff annotate
message A tiny bit of cleanup.

date 2021-10-24T15:47:39Z
author tobhe
files src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
message Remove 'struct tdb_crypto' allocations from esp_input() and esp_output().
This was needed to pass arguments to the callback function, but is no longer
necessary after the API makeover.

ok bluhm@

date 2021-10-24T16:02:44Z
author patrick
files src/sys/tmpfs/tmpfs_subr.c log diff annotate
src/sys/tmpfs/tmpfs_vnops.c log diff annotate
message tiny little whitespace fixes

date 2021-10-24T16:57:30Z
author mpi
files src/sys/scsi/cd.c log diff annotate
src/sys/scsi/ch.c log diff annotate
src/sys/scsi/mpath.c log diff annotate
src/sys/scsi/mpath_emc.c log diff annotate
src/sys/scsi/mpath_hds.c log diff annotate
src/sys/scsi/mpath_rdac.c log diff annotate
src/sys/scsi/mpath_sym.c log diff annotate
src/sys/scsi/safte.c log diff annotate
src/sys/scsi/scsiconf.c log diff annotate
src/sys/scsi/sd.c log diff annotate
src/sys/scsi/ses.c log diff annotate
src/sys/scsi/st.c log diff annotate
src/sys/scsi/uk.c log diff annotate
message Constify struct cfattach.

ok visa@ a long time ago, ok krw@

date 2021-10-24T17:05:03Z
author mpi
files src/sys/arch/sparc64/dev/auxio.c log diff annotate
src/sys/arch/sparc64/dev/bbc.c log diff annotate
src/sys/arch/sparc64/dev/beep.c log diff annotate
src/sys/arch/sparc64/dev/beeper.c log diff annotate
src/sys/arch/sparc64/dev/cbus.c log diff annotate
src/sys/arch/sparc64/dev/ce4231.c log diff annotate
src/sys/arch/sparc64/dev/central.c log diff annotate
src/sys/arch/sparc64/dev/clkbrd.c log diff annotate
src/sys/arch/sparc64/dev/cmp.c log diff annotate
src/sys/arch/sparc64/dev/com_ebus.c log diff annotate
src/sys/arch/sparc64/dev/comkbd_ebus.c log diff annotate
src/sys/arch/sparc64/dev/core.c log diff annotate
src/sys/arch/sparc64/dev/creator.c log diff annotate
src/sys/arch/sparc64/dev/ebus.c log diff annotate
src/sys/arch/sparc64/dev/ebus_mainbus.c log diff annotate
src/sys/arch/sparc64/dev/environ.c log diff annotate
src/sys/arch/sparc64/dev/fd.c log diff annotate
src/sys/arch/sparc64/dev/fhc_central.c log diff annotate
src/sys/arch/sparc64/dev/fhc_mainbus.c log diff annotate
src/sys/arch/sparc64/dev/gfb.c log diff annotate
src/sys/arch/sparc64/dev/gfxp.c log diff annotate
src/sys/arch/sparc64/dev/ifb.c log diff annotate
src/sys/arch/sparc64/dev/led.c log diff annotate
src/sys/arch/sparc64/dev/lom.c log diff annotate
src/sys/arch/sparc64/dev/lpt_ebus.c log diff annotate
src/sys/arch/sparc64/dev/machfb.c log diff annotate
src/sys/arch/sparc64/dev/mgiic.c log diff annotate
src/sys/arch/sparc64/dev/pcf8591_envctrl.c log diff annotate
src/sys/arch/sparc64/dev/pcf8591_ofw.c log diff annotate
src/sys/arch/sparc64/dev/pcfiic_ebus.c log diff annotate
src/sys/arch/sparc64/dev/pckbc_ebus.c log diff annotate
message Constify struct cfattach.

ok visa@ a long time ago

date 2021-10-24T17:05:04Z
author mpi
files src/sys/arch/sparc64/dev/pcons.c log diff annotate
src/sys/arch/sparc64/dev/pmc.c log diff annotate
src/sys/arch/sparc64/dev/power.c log diff annotate
src/sys/arch/sparc64/dev/ppm.c log diff annotate
src/sys/arch/sparc64/dev/prtc.c log diff annotate
src/sys/arch/sparc64/dev/psycho.c log diff annotate
src/sys/arch/sparc64/dev/radeonfb.c log diff annotate
src/sys/arch/sparc64/dev/raptor.c log diff annotate
src/sys/arch/sparc64/dev/rtc.c log diff annotate
src/sys/arch/sparc64/dev/sab.c log diff annotate
src/sys/arch/sparc64/dev/sbbc.c log diff annotate
src/sys/arch/sparc64/dev/sbus.c log diff annotate
src/sys/arch/sparc64/dev/ssm.c log diff annotate
src/sys/arch/sparc64/dev/stp_sbus.c log diff annotate
src/sys/arch/sparc64/dev/tda.c log diff annotate
src/sys/arch/sparc64/dev/upa.c log diff annotate
src/sys/arch/sparc64/dev/uperf_ebus.c log diff annotate
src/sys/arch/sparc64/dev/vbus.c log diff annotate
src/sys/arch/sparc64/dev/vcc.c log diff annotate
src/sys/arch/sparc64/dev/vcctty.c log diff annotate
src/sys/arch/sparc64/dev/vcons.c log diff annotate
src/sys/arch/sparc64/dev/vds.c log diff annotate
src/sys/arch/sparc64/dev/vdsk.c log diff annotate
src/sys/arch/sparc64/dev/vdsp.c log diff annotate
src/sys/arch/sparc64/dev/vgafb.c log diff annotate
src/sys/arch/sparc64/dev/vldc.c log diff annotate
src/sys/arch/sparc64/dev/vldcp.c log diff annotate
src/sys/arch/sparc64/dev/vnet.c log diff annotate
src/sys/arch/sparc64/dev/vrng.c log diff annotate
src/sys/arch/sparc64/dev/vrtc.c log diff annotate
src/sys/arch/sparc64/dev/vsw.c log diff annotate
src/sys/arch/sparc64/dev/wbsd_ebus.c log diff annotate
src/sys/arch/sparc64/dev/z8530kbd.c log diff annotate
src/sys/arch/sparc64/dev/zs.c log diff annotate
src/sys/arch/sparc64/sparc64/autoconf.c log diff annotate
src/sys/arch/sparc64/sparc64/clock.c log diff annotate
src/sys/arch/sparc64/sparc64/cpu.c log diff annotate
message Constify struct cfattach.

ok visa@ a long time ago

date 2021-10-24T17:08:27Z
author bluhm
files src/sys/netinet/ip_ah.c log diff annotate
src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipcomp.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
src/sys/netinet/ipsec_input.c log diff annotate
message There are more m_pullup() in IPsec input. Pass down the pointer
to the mbuf to update it globally. At the end it will reach
ip_deliver() which expects a pointer to an mbuf.
OK sashan@

date 2021-10-24T17:20:06Z
author patrick
files src/sys/tmpfs/tmpfs_subr.c log diff annotate
message Some more whitespace cleanup

date 2021-10-24T17:49:19Z
author deraadt
files src/sys/arch/amd64/stand/efi32/exec_i386.c log diff annotate
src/sys/arch/amd64/stand/efi64/exec_i386.c log diff annotate
src/sys/arch/amd64/stand/efiboot/exec_i386.c log diff annotate
src/sys/arch/amd64/stand/libsa/exec_i386.c log diff annotate
src/sys/arch/i386/stand/libsa/exec_i386.c log diff annotate
src/sys/arch/landisk/stand/xxboot/boot1.c log diff annotate
src/sys/arch/sparc64/stand/ofwboot/boot.c log diff annotate
src/sys/lib/libsa/loadfile.c log diff annotate
src/sys/lib/libsa/stand.h log diff annotate
src/sys/lib/libsa/stat.c log diff annotate
src/sys/stand/boot/boot.c log diff annotate
src/sys/stand/boot/cmd.c log diff annotate
message #define open O_* flags in libsa/stand.h, so that bootblocks can use
O_RDONLY rather using 0
ok beck

date 2021-10-24T17:52:26Z
author mpi
files src/sys/dev/fdt/acrtc.c log diff annotate
src/sys/dev/fdt/ahci_fdt.c log diff annotate
src/sys/dev/fdt/amlclock.c log diff annotate
src/sys/dev/fdt/amldwusb.c log diff annotate
src/sys/dev/fdt/amliic.c log diff annotate
src/sys/dev/fdt/amlmmc.c log diff annotate
src/sys/dev/fdt/amlpciephy.c log diff annotate
src/sys/dev/fdt/amlpinctrl.c log diff annotate
src/sys/dev/fdt/amlpwm.c log diff annotate
src/sys/dev/fdt/amlreset.c log diff annotate
src/sys/dev/fdt/amlrng.c log diff annotate
src/sys/dev/fdt/amlsm.c log diff annotate
src/sys/dev/fdt/amltemp.c log diff annotate
src/sys/dev/fdt/amluart.c log diff annotate
src/sys/dev/fdt/amlusbphy.c log diff annotate
src/sys/dev/fdt/axppmic.c log diff annotate
src/sys/dev/fdt/bcm2835_aux.c log diff annotate
src/sys/dev/fdt/bcm2835_dog.c log diff annotate
src/sys/dev/fdt/bcm2835_rng.c log diff annotate
src/sys/dev/fdt/bcm2835_temp.c log diff annotate
src/sys/dev/fdt/ccp_fdt.c log diff annotate
src/sys/dev/fdt/com_fdt.c log diff annotate
src/sys/dev/fdt/dwdog.c log diff annotate
src/sys/dev/fdt/dwmmc.c log diff annotate
src/sys/dev/fdt/dwpcie.c log diff annotate
src/sys/dev/fdt/ehci_fdt.c log diff annotate
src/sys/dev/fdt/exrtc.c log diff annotate
src/sys/dev/fdt/fanpwr.c log diff annotate
src/sys/dev/fdt/fusbtc.c log diff annotate
src/sys/dev/fdt/hiclock.c log diff annotate
src/sys/dev/fdt/hidwusb.c log diff annotate
src/sys/dev/fdt/hireset.c log diff annotate
src/sys/dev/fdt/hitemp.c log diff annotate
src/sys/dev/fdt/if_dwge.c log diff annotate
src/sys/dev/fdt/if_dwxe.c log diff annotate
src/sys/dev/fdt/if_fec.c log diff annotate
src/sys/dev/fdt/if_mvneta.c log diff annotate
src/sys/dev/fdt/imxanatop.c log diff annotate
src/sys/dev/fdt/imxccm.c log diff annotate
src/sys/dev/fdt/imxesdhc.c log diff annotate
src/sys/dev/fdt/imxgpc.c log diff annotate
src/sys/dev/fdt/imxgpio.c log diff annotate
src/sys/dev/fdt/imxiomuxc.c log diff annotate
src/sys/dev/fdt/imxrtc.c log diff annotate
src/sys/dev/fdt/imxspi.c log diff annotate
src/sys/dev/fdt/imxsrc.c log diff annotate
src/sys/dev/fdt/imxtmu.c log diff annotate
src/sys/dev/fdt/imxuart.c log diff annotate
src/sys/dev/fdt/moxtet.c log diff annotate
src/sys/dev/fdt/mvclock.c log diff annotate
src/sys/dev/fdt/mvdog.c log diff annotate
src/sys/dev/fdt/mvgicp.c log diff annotate
src/sys/dev/fdt/mvgpio.c log diff annotate
src/sys/dev/fdt/mvicu.c log diff annotate
src/sys/dev/fdt/mviic.c log diff annotate
src/sys/dev/fdt/mvmdio.c log diff annotate
src/sys/dev/fdt/mvpinctrl.c log diff annotate
src/sys/dev/fdt/mvrng.c log diff annotate
src/sys/dev/fdt/mvrtc.c log diff annotate
src/sys/dev/fdt/mvspi.c log diff annotate
src/sys/dev/fdt/mvtemp.c log diff annotate
src/sys/dev/fdt/mvuart.c log diff annotate
src/sys/dev/fdt/ohci_fdt.c log diff annotate
src/sys/dev/fdt/pinctrl.c log diff annotate
src/sys/dev/fdt/plgpio.c log diff annotate
src/sys/dev/fdt/plrtc.c log diff annotate
src/sys/dev/fdt/pluart_fdt.c log diff annotate
src/sys/dev/fdt/psci.c log diff annotate
src/sys/dev/fdt/pwmbl.c log diff annotate
src/sys/dev/fdt/pwmfan.c log diff annotate
src/sys/dev/fdt/pwmreg.c log diff annotate
src/sys/dev/fdt/rkclock.c log diff annotate
src/sys/dev/fdt/rkdwusb.c log diff annotate
src/sys/dev/fdt/rkemmcphy.c log diff annotate
src/sys/dev/fdt/rkgpio.c log diff annotate
src/sys/dev/fdt/rkgrf.c log diff annotate
src/sys/dev/fdt/rkiic.c log diff annotate
src/sys/dev/fdt/rkpcie.c log diff annotate
src/sys/dev/fdt/rkpinctrl.c log diff annotate
message Constify struct cfattach.

ok visa@ a long time ago, ok patrick@

date 2021-10-24T17:52:27Z
author mpi
files src/sys/arch/armv7/broadcom/bcm2836_intr.c log diff annotate
src/sys/arch/armv7/exynos/crosec.c log diff annotate
src/sys/arch/armv7/exynos/exclock.c log diff annotate
src/sys/arch/armv7/exynos/exdisplay.c log diff annotate
src/sys/arch/armv7/exynos/exdog.c log diff annotate
src/sys/arch/armv7/exynos/exdwusb.c log diff annotate
src/sys/arch/armv7/exynos/exehci.c log diff annotate
src/sys/arch/armv7/exynos/exgpio.c log diff annotate
src/sys/arch/armv7/exynos/exiic.c log diff annotate
src/sys/arch/armv7/exynos/exmct.c log diff annotate
src/sys/arch/armv7/exynos/expower.c log diff annotate
src/sys/arch/armv7/exynos/tps65090.c log diff annotate
src/sys/arch/armv7/imx/imxahci.c log diff annotate
src/sys/arch/armv7/imx/imxtemp.c log diff annotate
src/sys/arch/armv7/marvell/mvacc.c log diff annotate
src/sys/arch/armv7/marvell/mvagc.c log diff annotate
src/sys/arch/armv7/marvell/mvahci.c log diff annotate
src/sys/arch/armv7/marvell/mvmbus.c log diff annotate
src/sys/arch/armv7/marvell/mvmpic.c log diff annotate
src/sys/arch/armv7/marvell/mvpcie.c log diff annotate
src/sys/arch/armv7/marvell/mvpxa.c log diff annotate
src/sys/arch/armv7/marvell/mvsysctrl.c log diff annotate
src/sys/arch/armv7/marvell/mvxhci.c log diff annotate
src/sys/arch/armv7/omap/amdisplay.c log diff annotate
src/sys/arch/armv7/omap/dmtimer.c log diff annotate
src/sys/arch/armv7/omap/edma.c log diff annotate
src/sys/arch/armv7/omap/gptimer.c log diff annotate
src/sys/arch/armv7/omap/if_cpsw.c log diff annotate
src/sys/arch/armv7/omap/intc.c log diff annotate
src/sys/arch/armv7/omap/nxphdmi.c log diff annotate
src/sys/arch/armv7/omap/omap.c log diff annotate
src/sys/arch/armv7/omap/omapid.c log diff annotate
src/sys/arch/armv7/omap/omdisplay.c log diff annotate
src/sys/arch/armv7/omap/omdog.c log diff annotate
src/sys/arch/armv7/omap/omehci.c log diff annotate
src/sys/arch/armv7/omap/omgpio.c log diff annotate
src/sys/arch/armv7/omap/ommmc.c log diff annotate
src/sys/dev/fdt/rkpmic.c log diff annotate
src/sys/dev/fdt/rkpwm.c log diff annotate
src/sys/dev/fdt/rktemp.c log diff annotate
src/sys/dev/fdt/sdhc_fdt.c log diff annotate
src/sys/dev/fdt/sfp.c log diff annotate
src/sys/dev/fdt/simplefb.c log diff annotate
src/sys/dev/fdt/simplepanel.c log diff annotate
src/sys/dev/fdt/ssdfb.c log diff annotate
src/sys/dev/fdt/sxiccmu.c log diff annotate
src/sys/dev/fdt/sxidog.c log diff annotate
src/sys/dev/fdt/sximmc.c log diff annotate
src/sys/dev/fdt/sxipio.c log diff annotate
src/sys/dev/fdt/sxipwm.c log diff annotate
src/sys/dev/fdt/sxirsb.c log diff annotate
src/sys/dev/fdt/sxirtc.c log diff annotate
src/sys/dev/fdt/sxisid.c log diff annotate
src/sys/dev/fdt/sxisyscon.c log diff annotate
src/sys/dev/fdt/sxitemp.c log diff annotate
src/sys/dev/fdt/sxits.c log diff annotate
src/sys/dev/fdt/sxitwi.c log diff annotate
src/sys/dev/fdt/sypwr.c log diff annotate
src/sys/dev/fdt/syscon.c log diff annotate
src/sys/dev/fdt/virtio_mmio.c log diff annotate
src/sys/dev/fdt/xhci_fdt.c log diff annotate
message Constify struct cfattach.

ok visa@ a long time ago, ok patrick@

date 2021-10-24T17:52:28Z
author mpi
files src/sys/arch/arm64/arm64/acpi_machdep.c log diff annotate
src/sys/arch/arm64/arm64/cpu.c log diff annotate
src/sys/arch/arm64/dev/acpipci.c log diff annotate
src/sys/arch/arm64/dev/agintc.c log diff annotate
src/sys/arch/arm64/dev/agtimer.c log diff annotate
src/sys/arch/arm64/dev/ampintc.c log diff annotate
src/sys/arch/arm64/dev/apm.c log diff annotate
src/sys/arch/arm64/dev/bcm2836_intr.c log diff annotate
src/sys/arch/arm64/dev/efi.c log diff annotate
src/sys/arch/arm64/dev/mainbus.c log diff annotate
src/sys/arch/arm64/dev/simplebus.c log diff annotate
src/sys/arch/arm64/dev/smbios.c log diff annotate
src/sys/arch/armv7/omap/omohci.c log diff annotate
src/sys/arch/armv7/omap/omusbtll.c log diff annotate
src/sys/arch/armv7/omap/omwugen.c log diff annotate
src/sys/arch/armv7/omap/prcm.c log diff annotate
src/sys/arch/armv7/omap/ti_iic.c log diff annotate
src/sys/arch/armv7/sunxi/sxiahci.c log diff annotate
src/sys/arch/armv7/sunxi/sxie.c log diff annotate
src/sys/arch/armv7/sunxi/sxiintc.c log diff annotate
src/sys/arch/armv7/sunxi/sxitimer.c log diff annotate
src/sys/arch/armv7/vexpress/pciecam.c log diff annotate
src/sys/arch/armv7/vexpress/sysreg.c log diff annotate
message Constify struct cfattach.

ok visa@ a long time ago, ok patrick@

date 2021-10-24T18:15:58Z
author tobhe
files src/sys/netinet/ip_ipcomp.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
message Refactor ipcomp_input() and ipcomp_output(). Remove obsolete code related
to old crypto API.

ok bluhm@

date 2021-10-24T21:24:22Z
author deraadt
files src/sys/arch/alpha/stand/headersize.c log diff annotate
src/sys/arch/alpha/stand/setnetbootinfo/setnetbootinfo.c log diff annotate
message For open/openat, if the flags parameter does not contain O_CREAT, the
3rd (variadic) mode_t parameter is irrelevant. Many developers in the past
have passed mode_t (0, 044, 0644, or such), which might lead future people
to copy this broken idiom, and perhaps even believe this parameter has some
meaning or implication or application. Delete them all.
This comes out of a conversation where tb@ noticed that a strange (but
intentional) pledge behaviour is to always knock-out high-bits from
mode_t on a number of system calls as a safety factor, and his bewilderment
that this appeared to be happening against valid modes (at least visually),
but no sorry, they are all irrelevant junk. They could all be 0xdeafbeef.
ok millert

date 2021-10-24T21:37:49Z
author deraadt
files src/sys/dev/microcode/cyclades/cyzfirm2h.c log diff annotate
message For open/openat, if the flags parameter does not contain O_CREAT, the
3rd (variadic) mode_t parameter is irrelevant. Many developers in the past
have passed mode_t (0, 044, 0644, or such), which might lead future people
to copy this broken idiom, and perhaps even believe this parameter has some
meaning or implication or application. Delete them all.
This comes out of a conversation where tb@ noticed that a strange (but
intentional) pledge behaviour is to always knock-out high-bits from
mode_t on a number of system calls as a safety factor, and his bewilderment
that this appeared to be happening against valid modes (at least visually),
but no sorry, they are all irrelevant junk. They could all be 0xdeafbeef.
ok millert

date 2021-10-24T22:34:19Z
author tobhe
files src/sys/netinet/ip_ah.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
message Refactor ah_input() and ah_output() for new crypto API.

ok bluhm@

date 2021-10-24T22:59:47Z
author bluhm
files src/sys/netinet/in_proto.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
src/sys/netinet/ipsec_input.c log diff annotate
src/sys/netinet6/in6_proto.c log diff annotate
message Remove code duplication by merging the v4 and v6 input functions
for ah, esp, and ipcomp. Move common code into ipsec_protoff()
which finds the offset of the next protocol field in the previous
header.
OK tobhe@

date 2021-10-24T23:33:37Z
author tobhe
files src/sys/netinet/ip_esp.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
message Merge esp_input_cb() intp esp_input().

ok bluhm@

date 2021-10-25T09:47:02Z
author tobhe
files src/sys/netinet/ip_ah.c log diff annotate
message Fix use of uninitialized variable 'rpl'.

Found by jsg@
ok patrick@

date 2021-10-25T10:24:54Z
author claudio
files src/sys/kern/kern_descrip.c log diff annotate
src/sys/kern/vfs_subr.c log diff annotate
src/sys/kern/vfs_vnops.c log diff annotate
src/sys/sys/file.h log diff annotate
message Revert commitid: ufM9BcSbXqfLpzBH;
Move vfs_stall_barrier() from the fd layer into vn_lock() and the vfs layer.
In some cases it can result in a deadlock while suspending.
Discussed with mpi@ and deraadt@

date 2021-10-25T14:53:15Z
author sthen
files src/sys/arch/amd64/conf/GENERIC log diff annotate
message typos in comments, from jj, reported by Elyes Haouas on irc

date 2021-10-25T14:53:16Z
author sthen
files src/sys/arch/i386/conf/GENERIC log diff annotate
message typos in comments, from jj, reported by Elyes Haouas on irc

date 2021-10-25T15:59:46Z
author patrick
files src/sys/lib/libsa/netif.c log diff annotate
src/sys/lib/libsa/tftp.c log diff annotate
message Remove unused variables to silence clang.

ok kettenis@

date 2021-10-25T16:00:12Z
author bluhm
files src/sys/netinet/ip_ipsp.c log diff annotate
message Protect the tdb hashes with a mutex. Move initialization out of
the processing path. If rehashing fails due to low memory, just
keep the old hash buckets.
OK tobhe@

date 2021-10-25T17:15:29Z
author jasper
files src/sys/dev/dt/dt_prov_kprobe.c log diff annotate
src/sys/dev/dt/dtvar.h log diff annotate
message remove dtp_mtx which protected dtp_ref; the code is always called with KERNEL_LOCK() held

discussed with and OK mpi@

date 2021-10-25T18:25:01Z
author bluhm
files src/sys/net/pfkeyv2.c log diff annotate
src/sys/netinet/ip_ipsp.c log diff annotate
src/sys/netinet/ip_ipsp.h log diff annotate
message Call a locked variant of tdb_unlink() from tdb_walk(). Fixes a
mutex locking against myself panic introduced by my previous commit.
OK beck@ patrick@

date 2021-10-25T19:51:12Z
author millert
files src/sys/dev/dt/dt_dev.c log diff annotate
message remove dtp_mtx which protected dtp_ref; the code is always called with KERNEL_LOCK() held

date 2021-10-25T22:20:47Z
author bluhm
files src/sys/netinet/in_pcb.c log diff annotate
message The implementation of ipsp_spd_inp() is side effect free. It may
set the error output parameter or return a tdb. Both are ignored
in in_pcbconnect(). Remove the code that does nothing.
OK tobhe@ jca@ mvs@

date 2021-10-26T10:45:55Z
author patrick
files src/sys/arch/arm64/stand/efiboot/efiboot.c log diff annotate
src/sys/arch/armv7/stand/efiboot/efiboot.c log diff annotate
src/sys/arch/riscv64/stand/efiboot/efiboot.c log diff annotate
src/sys/arch/sparc64/stand/ofwboot/boot.c log diff annotate
message Remove more occurences of O_RDONLY in our bootloaders.

"just do it" deraadt@

date 2021-10-26T14:10:02Z
author patrick
files src/sys/arch/arm64/stand/efiboot/efiboot.c log diff annotate
src/sys/arch/armv7/stand/efiboot/efiboot.c log diff annotate
message Allocate fresh memory to put our device tree into, to make sure we have least
one page of free space for us to extend into. Fixes booting on VMware Fusion.

ok kettenis@

date 2021-10-26T14:13:57Z
author patrick
files src/sys/arch/arm64/arm64/pmap.c log diff annotate
message Only flush freshly mapped uncached/device mappings if we have a vm_page for it,
meaning we make sure it is indeed managed memory/RAM and not some MMIO. Fixes
booting on VMware Fusion (and an older QEMU diff for HVF acceleration).

ok kettenis@

date 2021-10-26T14:20:47Z
author patrick
files src/sys/arch/arm64/conf/GENERIC log diff annotate
src/sys/arch/arm64/conf/RAMDISK log diff annotate
message Enable vmx(4) on arm64. Tested using VMware Fusion on the Apple M1.

ok kettenis@

date 2021-10-26T16:29:49Z
author deraadt
files src/sys/arch/amd64/amd64/vmm.c log diff annotate
src/sys/dev/i2c/i2c.c log diff annotate
src/sys/dev/isa/isa.c log diff annotate
src/sys/dev/isa/isadma.c log diff annotate
src/sys/dev/pci/azalia.c log diff annotate
src/sys/dev/usb/ehci.c log diff annotate
src/sys/dev/usb/ohci.c log diff annotate
src/sys/dev/usb/uhci.c log diff annotate
src/sys/dev/usb/xhci.c log diff annotate
src/sys/kern/subr_autoconf.c log diff annotate
src/sys/stand/boot/boot.c log diff annotate
src/sys/sys/device.h log diff annotate
src/sys/sys/reboot.h log diff annotate
message Improve unhibernate performance (30% on some machines, another upcoming diff
shows gains up to 50%) by skipping attach of irrelevant devices, which are
tagged CD_SKIPHIBERNATE in the per-driver cfdriver. In particular, usb devices
are not attached, so they don't need to detach during the suspend-unpack-resume.
New bootblocks are required (which tell the kernel it's job is unhibernate
before configure runs)
tested by various

date 2021-10-26T16:49:12Z
author matthieu
files src/sys/dev/usb/uthum.c log diff annotate
message Add a new TEMPerHUM device id. style tweak deraadt@, ok mlarkin@