I am confused by the new documentation of HW_PERFPOLICY.  Is this bound
to change?  Looking at the function sysctl_hwperfpolicy() in
sys/kern/sched_bsd.c, I think the following is more accurate, although I
don't know what has to go wrong that the string is actually set to
`unknown'.

For consistency with the rest of the manual page, I used .Dq instead
of .Qq.

$ apm -L
$ sysctl hw.perfpolicy
hw.perfpolicy=manual
$ apm -A
$ sysctl hw.perfpolicy
hw.perfpolicy=auto
$ apm -H
$ sysctl hw.perfpolicy
hw.perfpolicy=high


Index: lib/libc/gen/sysctl.3
===================================================================
RCS file: /cvs/src/lib/libc/gen/sysctl.3,v
retrieving revision 1.248
diff -u -p -r1.248 sysctl.3
--- lib/libc/gen/sysctl.3       11 Mar 2015 19:42:38 -0000      1.248
+++ lib/libc/gen/sysctl.3       12 Mar 2015 07:32:20 -0000
@@ -332,9 +332,11 @@ The software page size.
 .It Dv HW_PERFPOLICY
 The performance policy for power management.
 Can be one of
-.Qq manual
+.Dq manual ,
+.Dq auto ,
+.Dq high ,
 or
-.Qq automatic .
+.Dq unknown .
 .It Dv HW_PHYSMEM
 The total physical memory, in bytes.
 This variable is deprecated; use
@@ -377,6 +379,9 @@ The serial number of the machine.
 .It Dv HW_SETPERF
 Current CPU performance
 .Pq percentage .
+Only modifiable if
+.Dv HW_PERFPOLICY is set to
+.Dq manual .
 .It Dv HW_USERMEM
 The amount of available non-kernel memory in bytes.
 This variable is deprecated; use

Reply via email to