]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit - sys/compat/freebsd32/freebsd32_misc.c
umtx_op: reduce redundancy required for compat32
authorKyle Evans <kevans@FreeBSD.org>
Tue, 17 Nov 2020 03:36:58 +0000 (03:36 +0000)
committerKyle Evans <kevans@FreeBSD.org>
Tue, 17 Nov 2020 03:36:58 +0000 (03:36 +0000)
commit63ecb272a00c6f084a33db1c6ad3e925d4dcf015
treea9330aa55236df89262d4d139feccc0b1ef90754
parent4be0a1b5874b9713962580bafed2e452c6d104eb
umtx_op: reduce redundancy required for compat32

All of the compat32 variants are substantially the same, save for
copyin/copyout (mostly). Apply the same kind of technique used with kevent
here by having the syscall routines supply a umtx_copyops describing the
operations needed.

umtx_copyops carries the bare minimum needed- size of timespec and
_umtx_time are used for determining if copyout is needed in the sem2_wait
case.

Reviewed by: kib
MFC after: 1 week
Differential Revision: https://reviews.freebsd.org/D27222
sys/compat/freebsd32/freebsd32.h
sys/compat/freebsd32/freebsd32_misc.c
sys/kern/kern_umtx.c
sys/sys/proc.h
sys/sys/syscallsubr.h
sys/sys/umtx.h