Date: Tue, 14 Mar 2006 14:40:14 GMT From: Craig Manley <cmanley@xs4all.nl> To: freebsd-bugs@FreeBSD.org Subject: Re: bin/90903: [powerd] cpufreq inconsistency / powerd broken Message-ID: <200603141440.k2EEeEPc078942@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/90903; it has been noted by GNATS.
From: Craig Manley <cmanley@xs4all.nl>
To: bug-followup@FreeBSD.org, wiwi@progon.net
Cc:
Subject: Re: bin/90903: [powerd] cpufreq inconsistency / powerd broken
Date: Tue, 14 Mar 2006 15:32:16 +0100
Hi,
Could you please also add a sanity check after this block at line 50 in
powerd.c where the current frequency is read and then all known
frequencies in freqs are tested before entering the for (ever) loop
later on. A warning is shown for those frequencies that fail to be set,
and if 0 or 1 frequencies are good, then de daemon should croak with an
appropriate warning. I've only got limited knowledge of C and don't know
how to get this stuff patched or compiled myself otherwise I would, so
forgive me on that. The reason why this additional sanity check is
useful is because I've noticed that many people like me have more
frequencies in the array than that can be set by sysctl.
/* Check if we can read the idle time and supported freqs. */
if (read_usage_times(NULL, NULL))
err(1, "read_usage_times");
if (read_freqs(&numfreqs, &freqs, &mwatts))
err(1, "error reading supported CPU frequencies");
.... sanity check here ....
.... leaving a fresh new numfreqs, freqs, and mwatts here ...
Regards,
Craig Manley
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200603141440.k2EEeEPc078942>
