OpenBSD cvs log

created 2023-09-21T18:09:27Z
begin 2023-09-14T00:00:00Z
end 2023-09-15T00:00:00Z
path src/sys
commits 8

date 2023-09-14T00:29:35Z
author jsg
files src/sys/dev/pci/drm/radeon/radeon_combios.c log diff annotate
message revert previous, it doesn't help
reporter had radeondrm disabled when testing

date 2023-09-14T19:39:47Z
author cheloha
files src/sys/arch/amd64/amd64/lapic.c log diff annotate
src/sys/arch/arm/cortex/agtimer.c log diff annotate
src/sys/arch/arm/cortex/amptimer.c log diff annotate
src/sys/arch/arm64/dev/agtimer.c log diff annotate
src/sys/arch/armv7/omap/dmtimer.c log diff annotate
src/sys/arch/armv7/omap/gptimer.c log diff annotate
src/sys/arch/armv7/sunxi/sxitimer.c log diff annotate
src/sys/kern/kern_clock.c log diff annotate
src/sys/kern/kern_clockintr.c log diff annotate
src/sys/sys/clockintr.h log diff annotate
src/sys/sys/systm.h log diff annotate
message clockintr: replace CL_RNDSTAT with global variable statclock_is_randomized

In order to separate the statclock from the clock interrupt subsystem
we need to move all statclock state out into the broader kernel.

Start by replacing the CL_RNDSTAT flag with a new global variable,
"statclock_is_randomized", in kern_clock.c. Update all clockintr_init()
callers to set the boolean instead of passing the flag.

Thread: https://marc.info/?l=openbsd-tech&m=169428749720476&w=2

date 2023-09-14T19:39:48Z
author cheloha
files src/sys/arch/hppa/dev/clock.c log diff annotate
src/sys/arch/i386/i386/lapic.c log diff annotate
src/sys/arch/loongson/dev/glxclk.c log diff annotate
src/sys/arch/macppc/macppc/clock.c log diff annotate
src/sys/arch/mips64/mips64/clock.c log diff annotate
src/sys/arch/powerpc64/powerpc64/clock.c log diff annotate
src/sys/arch/riscv64/riscv64/clock.c log diff annotate
src/sys/arch/sparc64/sparc64/clock.c log diff annotate
message clockintr: replace CL_RNDSTAT with global variable statclock_is_randomized

In order to separate the statclock from the clock interrupt subsystem
we need to move all statclock state out into the broader kernel.

Start by replacing the CL_RNDSTAT flag with a new global variable,
"statclock_is_randomized", in kern_clock.c. Update all clockintr_init()
callers to set the boolean instead of passing the flag.

Thread: https://marc.info/?l=openbsd-tech&m=169428749720476&w=2

date 2023-09-14T19:51:17Z
author cheloha
files src/sys/kern/kern_clockintr.c log diff annotate
message clockintr: move clockintr_advance_random() prototype into sys/clockintr.h

statclock() is going to need this. Move the prototype into the public API.

Thread: https://marc.info/?l=openbsd-tech&m=169428749720476&w=2

date 2023-09-14T19:51:18Z
author cheloha
files src/sys/sys/clockintr.h log diff annotate
message clockintr: move clockintr_advance_random() prototype into sys/clockintr.h

statclock() is going to need this. Move the prototype into the public API.

Thread: https://marc.info/?l=openbsd-tech&m=169428749720476&w=2

date 2023-09-14T20:58:51Z
author cheloha
files src/sys/kern/kern_clock.c log diff annotate
src/sys/kern/kern_clockintr.c log diff annotate
src/sys/sys/systm.h log diff annotate
message clockintr, statclock: eliminate clockintr_statclock() wrapper

- Move remaining statclock variables from kern_clockintr.c to
kern_clock.c. Move statclock variable initialization from
clockintr_init() into initclocks().

- Change statclock() prototype to make it a legal clockintr
callback function and establish the handle with statclock()
instead clockintr_statclock().

- Merge the contents of clockintr_statclock() into statclock().
statclock() can now reschedule itself and handles multiple
expirations transparently.

- Make statclock_avg visible from sys/systm.h so that clockintr_cpu_init()
can use it to advance the statclock across suspend/hibernate.

Thread: https://marc.info/?l=openbsd-tech&m=169428749720476&w=2

date 2023-09-14T22:07:11Z
author cheloha
files src/sys/kern/kern_clockintr.c log diff annotate
src/sys/kern/kern_sched.c log diff annotate
src/sys/sys/clockintr.h log diff annotate
src/sys/sys/sched.h log diff annotate
message clockintr, scheduler: move statclock handle from clockintr_queue to schedstate_percpu

Move the statclock handle from clockintr_queue.cq_statclock to
schedstate_percpu.spc_statclock. Establish spc_statclock during
sched_init_cpu() alongside the other scheduler clock interrupts.

Thread: https://marc.info/?l=openbsd-tech&m=169428749720476&w=2

date 2023-09-14T22:27:09Z
author cheloha
files src/sys/kern/kern_clock.c log diff annotate
src/sys/kern/kern_clockintr.c log diff annotate
message clockintr: move hz(9)-based initialization out to initclocks()

To separate the hardclock from the clock interrupt subsystem we'll
need to move all related state out first.

hz(9) is set when we return from cpu_initclocks(), so it's safe to
move hardclock_period and roundrobin_period initialization out into
initclocks(). Move hardclock_period itself out into kern_clock.c
alongside the statclock variables.