OpenBSD cvs log

created 2024-11-04T21:43:05Z
begin 2024-10-31T00:00:00Z
end 2024-11-01T00:00:00Z
path src/sys
commits 6

date 2024-10-31T05:00:00Z
author dlg
files src/sys/uvm/uvm_map.c log diff annotate
src/sys/uvm/uvm_map.h log diff annotate
message try to simplify the locking code around busy maps.

this is src/sys/uvm/uvm_map.c r1.331 again with a small fix to pass
the right mutex to msleep when waiting for the busy proc pointer.

vm_maps have a "feature" where they can mark that they're being
operated on by a specific proc, and then release the rwlock protecting
their state. to relock, you have to be the same proc that marked
it busy.

this diff tries to simplify it a bit. it basically has threads check
the busy field up front and rechecks the busy field inside the
rwlock. if you can sleep, it will sleep up front for the busy field
to become clear, rather than sleep on either the busy field or the
rwlock. some code paths clear the busy field without holding the
rwlock, so it doesn't make sense to me to be waiting for the busy
field but sleeping somewhere else.

ok claudio@

date 2024-10-31T10:06:51Z
author mvs
files src/sys/kern/kern_sysctl.c log diff annotate
src/sys/kern/vfs_subr.c log diff annotate
src/sys/kern/vfs_syscalls.c log diff annotate
message Unlock fs_sysctl(). It is the only `suid_clear' variable - atomically
accessed integer.

ok bluhm

date 2024-10-31T11:41:31Z
author mvs
files src/sys/net/if_vxlan.c log diff annotate
message Drop forgotten backslashes within vxlan_input(). Seems they are stalled
from macro copy-paste. No functional changes.

ok mpi dlg

date 2024-10-31T12:33:11Z
author claudio
files src/sys/net/if_wg.c log diff annotate
message Rewrite mbuf handling in wg(4).

. Use m_align() to ensure that mbufs are packed towards the end so that
additional headers don't require costly m_prepends.
. Stop using m_copyback(), the way it was used there was actually wrong,
instead just use memcpy since this is just a single mbuf.
. Kill all usage of m_calchdrlen(), again this is not needed or can simply
be m->m_pkthdr.len = m->m_len since all this code uses a single buffer.
. In wg_encap() remove the min() with t->t_mtu when calculating plaintext_len
and out_len. The code does not correctly cope with this min() at all with
severe consequences.
Initial diff by dhill@ who found the m_prepend() issue.
Tested by various people.
OK dhill@ mvs@ bluhm@ sthen@

date 2024-10-31T12:51:55Z
author claudio
files src/sys/kern/uipc_socket.c log diff annotate
message No need to set pkthdr fields to 0 that are already 0. MGETHDR() does that.
OK dlg@

date 2024-10-31T13:55:21Z
author claudio
files src/sys/conf/files log diff annotate
src/sys/miscfs/fuse/fuse_file.c log diff annotate
src/sys/miscfs/fuse/fuse_ihash.c log diff annotate
src/sys/miscfs/fuse/fuse_lookup.c log diff annotate
src/sys/miscfs/fuse/fuse_vfsops.c log diff annotate
src/sys/miscfs/fuse/fuse_vnops.c log diff annotate
src/sys/miscfs/fuse/fusefs_node.h log diff annotate
message Stop abusing ufs inodes and with it the ufs_ihash.
Instead extend fusefs_node with the few required fields.
Tested by kirill@ with input from miod@
OK beck@