OpenBSD cvs log

created 2021-01-04T19:37:37Z
begin 2020-12-04T00:00:00Z
end 2020-12-05T00:00:00Z
path src/sys
commits 4

date 2020-12-04T03:22:46Z
author cheloha
files src/sys/dev/pv/hyperv.c log diff annotate
src/sys/dev/pv/if_hvn.c log diff annotate
message hvn(4), hyperv(4): more tsleep(9) -> tsleep_nsec(9) conversions

Replace all tsleep(..., 1) calls in these drivers with tsleep_nsec(9)
calls. In every case we can use the nearby delay(9) intervals as the
timeout.

Tested by Andre Stoebe <[email protected]> (Hyper-V on Windows 10).

"LGTM" mikeb@, ok mpi@

date 2020-12-04T15:16:45Z
author mpi
files src/sys/kern/kern_fork.c log diff annotate
src/sys/kern/kern_sig.c log diff annotate
message Prevent a TOCTOU race in single_thread_set() by extending the scope of the lock.

Make sure `ps_single' is set only once by checking then updating it without
releasing the lock.

Analyzed by and ok claudio@

date 2020-12-04T18:05:26Z
author cheloha
files src/sys/dev/pv/if_hvn.c log diff annotate
message hvn(4): msleep(9) -> msleep_nsec(9)

In hvn_alloc_cmd() we may spin waiting for a free rndis_cmd. We check
the list once per tick and block with msleep(9) if there aren't any
free objects.

In practice though we don't need to poll for a free rndis_cmd because
our sleep is protected by a mutex, so we can't miss a wakeup(9). That
is, it's safe to use msleep_nsec(9) here and not set a timeout (INFSLP).

Tested by Andre Stoebe <[email protected]> (Hyper-V on Windows 10).

"LGTM" mikeb@, ok mpi@

date 2020-12-04T21:18:09Z
author kettenis
files src/sys/arch/arm64/arm64/cpu.c log diff annotate
message Recognize Neoverse-N2.