[haiku-development] Re: [gsoc2012] cpuidle support

  • From: Yongcong Du <ycdu.vmcore@xxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Tue, 27 Mar 2012 09:15:37 +0800

Dear Clemens,

On Tue, Mar 27, 2012 at 3:27 AM, Clemens Zeidler <
clemens.zeidler@xxxxxxxxxxxxxx> wrote:

> On Mon, 26 Mar 2012 15:15:04 +1300, Yongcong Du <ycdu.vmcore@xxxxxxxxx>
> wrote:
>
>
>  I noticed that haiku has supported something similar as cpufreq:
>> //www.freelists.org/post/**haiku-development/Intel-**
>> Enhanced-Speedstep-Driver<//www.freelists.org/post/haiku-development/Intel-Enhanced-Speedstep-Driver>
>> and I did find the related drivers in
>> src/add-ons/kernel/drivers/**power/enhanced_speedstep/
>>
>>
> One of the problems with this driver was that the timer got messed up,
> time was ticking to fast or to slow. If I got it right the usage of HPET
> would help here. So maybe a part of your project should be to get HPET
> working...
>
> Hmm, Do you mean http://beos.mlotz.ch/documents/cpu_fix.html ?
But cpuidle doesn't have this problem. However, cpuidle need to handle with
timer also -- On some platforms, some timers may be shutdown when entering
deeper idle stage, take my intern job's platform(one arm SoC) for example,
the local timer per cpu will be shutdown when entering C2 state.  So
switching to another live timer before entering deeper idle is necessary.
Dear Jisheng,
Please correct me if something is wrong.


Hopefully, using ACPI to change and query cpu states should be quite easy.
> So eventually there should be time to integrate it into the current
> pref-let.


Would you please  point me the location of "pref-let" and the "power"
source code ?

> And/or move it into a power server.
>
>
Using ACPI to get and change c-states is a common way on PC platform, but
1. I still don't know whether haiku's acpi  can get and change
c-states(NOTE: c-states not p-states)
2. acpi is complex, I don't know can it be completed in one summer
3. As the intel_idle driver said, the method can be more efficient and
knows more than ACPI, as well as make Linux more immune to ACPI BIOS bugs.
But per my understanding, the more advantage is it's more SW programer
friendly than ACPI

However, I can put it into my project's goals if haiku acpi support
c-states.

Regards,
Yongcong

Other related posts: