diff options
author | venkatesh.pallipadi@intel.com <venkatesh.pallipadi@intel.com> | 2008-01-31 20:35:06 -0500 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2008-02-07 02:20:15 -0500 |
commit | 9a0b841586c3c6c846effdbe75885c2ebc0031b0 (patch) | |
tree | d9522222094b6357c7933489b98c7249326e1cf8 /drivers/acpi/processor_idle.c | |
parent | 9b12e18cdc1553de62d931e73443c806347cd974 (diff) |
cpuidle: Add a poll_idle method
Add a default poll idle state with 0 latency. Provides an option to users
to use poll_idle by using 0 as the latency requirement.
Signed-off-by: Venkatesh Pallipadi <venkatesh.pallipadi@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/processor_idle.c')
-rw-r--r-- | drivers/acpi/processor_idle.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/acpi/processor_idle.c b/drivers/acpi/processor_idle.c index fea71597b40a..32488e6f76ab 100644 --- a/drivers/acpi/processor_idle.c +++ b/drivers/acpi/processor_idle.c | |||
@@ -1628,7 +1628,7 @@ struct cpuidle_driver acpi_idle_driver = { | |||
1628 | */ | 1628 | */ |
1629 | static int acpi_processor_setup_cpuidle(struct acpi_processor *pr) | 1629 | static int acpi_processor_setup_cpuidle(struct acpi_processor *pr) |
1630 | { | 1630 | { |
1631 | int i, count = 0; | 1631 | int i, count = CPUIDLE_DRIVER_STATE_START; |
1632 | struct acpi_processor_cx *cx; | 1632 | struct acpi_processor_cx *cx; |
1633 | struct cpuidle_state *state; | 1633 | struct cpuidle_state *state; |
1634 | struct cpuidle_device *dev = &pr->power.dev; | 1634 | struct cpuidle_device *dev = &pr->power.dev; |
@@ -1687,6 +1687,8 @@ static int acpi_processor_setup_cpuidle(struct acpi_processor *pr) | |||
1687 | } | 1687 | } |
1688 | 1688 | ||
1689 | count++; | 1689 | count++; |
1690 | if (count == CPUIDLE_STATE_MAX) | ||
1691 | break; | ||
1690 | } | 1692 | } |
1691 | 1693 | ||
1692 | dev->state_count = count; | 1694 | dev->state_count = count; |