On 2024-04-24, Harald Dunkel <harald.dun...@aixigo.com> wrote: > Hi folks, > > https://www.openbsd.org/faq/upgrade57.html doesn't mention it, so > I wonder what became of "apmd -C"? The man page for OpenBSD 5.7 > silently dropped this option, but even apmd of 7.5 still accepts > it. > > ?
apmd used to have code that checked cpu load and adjusted hw.setperf. This moved to the kernel under hw.perfpolicy=auto which used to do about the same thing, but was changed to use high all the time on a machine where line power is connected. To get similar to previous behaviour, you can either install obsdfreqd from packages (userland monitoring, similar to old old apmd -C), or some people run with a kernel patch like this: Index: kern/sched_bsd.c =================================================================== RCS file: /cvs/src/sys/kern/sched_bsd.c,v diff -u -p -r1.91 sched_bsd.c --- kern/sched_bsd.c 30 Mar 2024 13:33:20 -0000 1.91 +++ kern/sched_bsd.c 24 Apr 2024 07:18:01 -0000 @@ -603,7 +603,7 @@ setperf_auto(void *v) if (cpu_setperf == NULL) return; - if (hw_power) { + if (0 && hw_power) { speedup = 1; goto faster; }