Re: [Devel] Regarding ACPI library

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, 23 Dec 2009, nisha jain wrote:

> Hi All,
> 
> I am working on research related to Power management and control for single and multiprocessors and I came across ACPI standard. I want
> to get all CPU power information (c state and frequency p state information) for different applications and kernel processes running
> into system (with load).  I went through user manual of the ACPI and as per my understaning there is some information written by the
> ACPI HW/SW module and ACPI is already a part of most Linux kernels.I went through all the acpi site but there is no sample program to
> show its usage also i have installed the UNIX Format Source Code and Build Environment and  UNIX Format Test Suite of the ACPI and
> successfully compiled it. I am not sure how and which acpi APIs needs to be called to get such information and how to install the ACPI
> library...Also I want to control CPU frquency and state not sure how to achieve it using ACPI library?
> 
> I am using an environment with Intel Dual Core Tm processor and Ubuntu platform.

Hi Nisha,
ACPI is an interface between the hardware and the OS,
not an interface between the kernel and user-space.

So generally the ACPICA core is hidden inside the kernel
and not directly visible to user-space.

So your question is really about the Linux APIs for
user-space utilities to get to the stuff that is
implemented by ACPI.

On Linux, we endeavor to expose ACPI directly to application layer
only for debugging hooks -- eg the old /proc/acpi/*
and the new /sys/firmware/acpi/*

In general, we try to have generic policy code that doesn't
directly know if ACPI is involved in the underlying implementation.
For example, cpufreq abstracts ACPI P-states, cpuidle
abstracts ACPI C-states, thermal abstracts ACPI thermal & T-states,
power supply abstracts ACPI battery etc.

Note that the powertop application is available in most recent distros
to grab and summarize a lot of what you may be seeking.
It looks in /sys/devices/system/cpu/* for cpufreq and cpuidle info.

cheers,
-Len Brown
Intel Open Source Technology Center

[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux