OpenBSD cvs log

created 2020-01-11T17:45:36Z
begin 2020-01-08T00:00:00Z
end 2020-01-09T00:00:00Z
path src/sys
commits 9

date 2020-01-08T09:09:10Z
author claudio
files src/sys/net/if_loop.c log diff annotate
message In loop_clone_destroy() reset the rdomain with rtable_l2set() after
the if_detach() call. In if_detach() various route messages are generated
and during that time the rtable_l2() mapping needs to stay.
OK kn@

date 2020-01-08T10:02:55Z
author claudio
files src/sys/net/route.c log diff annotate
message Fix confusion around rtlabelid and rtableid in rt_ifa_add() and rt_ifa_del().
The routing labels have nothing todo with rdomains and routing tables.
Remove the unneeded rdomain check. With this rtlabel on interfaces work again.
OK kn@

date 2020-01-08T12:57:35Z
author mpi
files src/sys/dev/usb/ulpt.c log diff annotate
message Kill unused defines referencing `hz'.

date 2020-01-08T15:03:10Z
author mpi
files src/sys/kern/sysv_sem.c log diff annotate
src/sys/miscfs/fifofs/fifo_vnops.c log diff annotate
src/sys/nfs/nfs_vfsops.c log diff annotate
message Convert infinite sleeps to tsleep_nsec(9).

ok bluhm@

date 2020-01-08T16:27:40Z
author visa
files src/sys/dev/wscons/wskbd.c log diff annotate
message Unify handling of ioctls FIOSETOWN/SIOCSPGRP/TIOCSPGRP and
FIOGETOWN/SIOCGPGRP/TIOCGPGRP. Do this by determining the meaning of
the ID parameter inside the sigio code. Also add cases for FIOSETOWN
and FIOGETOWN where there have been TIOCSPGRP and TIOCGPGRP before.
These changes allow removing the ID translation from sys_fcntl() and
sys_ioctl().

Idea from NetBSD

OK mpi@, claudio@

date 2020-01-08T16:27:41Z
author visa
files src/sys/dev/wscons/wsmouse.c log diff annotate
src/sys/dev/wscons/wsmux.c log diff annotate
src/sys/kern/kern_descrip.c log diff annotate
src/sys/kern/kern_sig.c log diff annotate
src/sys/kern/subr_log.c log diff annotate
src/sys/kern/sys_generic.c log diff annotate
src/sys/kern/sys_pipe.c log diff annotate
src/sys/kern/sys_socket.c log diff annotate
src/sys/kern/tty.c log diff annotate
src/sys/net/bpf.c log diff annotate
src/sys/net/if_tun.c log diff annotate
message Unify handling of ioctls FIOSETOWN/SIOCSPGRP/TIOCSPGRP and
FIOGETOWN/SIOCGPGRP/TIOCGPGRP. Do this by determining the meaning of
the ID parameter inside the sigio code. Also add cases for FIOSETOWN
and FIOGETOWN where there have been TIOCSPGRP and TIOCGPGRP before.
These changes allow removing the ID translation from sys_fcntl() and
sys_ioctl().

Idea from NetBSD

OK mpi@, claudio@

date 2020-01-08T16:27:42Z
author visa
files src/sys/sys/sigio.h log diff annotate
message Unify handling of ioctls FIOSETOWN/SIOCSPGRP/TIOCSPGRP and
FIOGETOWN/SIOCGPGRP/TIOCGPGRP. Do this by determining the meaning of
the ID parameter inside the sigio code. Also add cases for FIOSETOWN
and FIOGETOWN where there have been TIOCSPGRP and TIOCGPGRP before.
These changes allow removing the ID translation from sys_fcntl() and
sys_ioctl().

Idea from NetBSD

OK mpi@, claudio@

date 2020-01-08T16:45:28Z
author visa
files src/sys/kern/kern_descrip.c log diff annotate
src/sys/kern/kern_event.c log diff annotate
message Skip fdplock when freeing a file descriptor table. The lock is not
necessary because other threads cannot access the data structure.
This fixes the following lock order issue:

witness: lock order reversal:
1st 0xfffffd81d821d248 fdlock (&newfdp->fd_fd.fd_lock)
2nd 0xffff800000fe45b8 primlk (&prime_fpriv->lock)
lock order "&prime_fpriv->lock"(rwlock) -> "&newfdp->fd_fd.fd_lock"(rwlock) first seen at:
#0 witness_checkorder+0x449
#1 rw_enter_write+0x43
#2 dma_buf_fd+0x8c
#3 drm_gem_prime_handle_to_fd+0xed
#4 drmioctl+0xdc
#5 VOP_IOCTL+0x55
#6 vn_ioctl+0x64
#7 sys_ioctl+0x2f6
#8 syscall+0x389
#9 Xsyscall+0x128
lock order "&newfdp->fd_fd.fd_lock"(rwlock) -> "&prime_fpriv->lock"(rwlock) first seen at:
#0 witness_checkorder+0x449
#1 rw_enter_write+0x43
#2 drm_gem_object_release_handle+0x5e
#3 idr_for_each+0xee
#4 drm_gem_release+0x1f
#5 drmclose+0x144
#6 spec_close+0x213
#7 VOP_CLOSE+0x49
#8 vn_closefile+0x9b
#9 fdrop+0x8b
#10 closef+0xaf
#11 fdfree+0xd4
#12 exit1+0x1cf
#13 sys_exit+0x16
#14 syscall+0x389
#15 Xsyscall+0x128


OK mpi@

date 2020-01-08T21:48:59Z
author bluhm
files src/sys/net/pf_ioctl.c log diff annotate
message Check address family of pf ioctl(2) DIOCNATLOOK parameter at kernel
entry instead of calling panic() due to unhandled af.
Reported-by: [email protected]
from Benjamin Baier