diff options
Diffstat (limited to 'drivers/acpi/processor_idle.c')
-rw-r--r-- | drivers/acpi/processor_idle.c | 39 |
1 files changed, 1 insertions, 38 deletions
diff --git a/drivers/acpi/processor_idle.c b/drivers/acpi/processor_idle.c index 6d9ec3e0b52e..e589c1985248 100644 --- a/drivers/acpi/processor_idle.c +++ b/drivers/acpi/processor_idle.c @@ -221,10 +221,6 @@ static void lapic_timer_state_broadcast(struct acpi_processor *pr, #endif -/* - * Suspend / resume control - */ -static int acpi_idle_suspend; static u32 saved_bm_rld; static void acpi_idle_bm_rld_save(void) @@ -243,21 +239,13 @@ static void acpi_idle_bm_rld_restore(void) int acpi_processor_suspend(struct device *dev) { - if (acpi_idle_suspend == 1) - return 0; - acpi_idle_bm_rld_save(); - acpi_idle_suspend = 1; return 0; } int acpi_processor_resume(struct device *dev) { - if (acpi_idle_suspend == 0) - return 0; - acpi_idle_bm_rld_restore(); - acpi_idle_suspend = 0; return 0; } @@ -595,7 +583,6 @@ static void acpi_processor_power_verify_c3(struct acpi_processor *pr, */ cx->valid = 1; - cx->latency_ticks = cx->latency; /* * On older chipsets, BM_RLD needs to be set * in order for Bus Master activity to wake the @@ -628,7 +615,6 @@ static int acpi_processor_power_verify(struct acpi_processor *pr) if (!cx->address) break; cx->valid = 1; - cx->latency_ticks = cx->latency; /* Normalize latency */ break; case ACPI_STATE_C3: @@ -763,11 +749,6 @@ static int acpi_idle_enter_c1(struct cpuidle_device *dev, local_irq_disable(); - if (acpi_idle_suspend) { - local_irq_enable(); - cpu_relax(); - return -EBUSY; - } lapic_timer_state_broadcast(pr, cx, 1); kt1 = ktime_get_real(); @@ -779,7 +760,6 @@ static int acpi_idle_enter_c1(struct cpuidle_device *dev, dev->last_residency = (int)idle_time; local_irq_enable(); - cx->usage++; lapic_timer_state_broadcast(pr, cx, 0); return index; @@ -838,11 +818,6 @@ static int acpi_idle_enter_simple(struct cpuidle_device *dev, local_irq_disable(); - if (acpi_idle_suspend) { - local_irq_enable(); - cpu_relax(); - return -EBUSY; - } if (cx->entry_method != ACPI_CSTATE_FFH) { current_thread_info()->status &= ~TS_POLLING; @@ -887,10 +862,7 @@ static int acpi_idle_enter_simple(struct cpuidle_device *dev, if (cx->entry_method != ACPI_CSTATE_FFH) current_thread_info()->status |= TS_POLLING; - cx->usage++; - lapic_timer_state_broadcast(pr, cx, 0); - cx->time += idle_time; return index; } @@ -928,8 +900,7 @@ static int acpi_idle_enter_bm(struct cpuidle_device *dev, drv, drv->safe_state_index); } else { local_irq_disable(); - if (!acpi_idle_suspend) - acpi_safe_halt(); + acpi_safe_halt(); local_irq_enable(); return -EBUSY; } @@ -937,11 +908,6 @@ static int acpi_idle_enter_bm(struct cpuidle_device *dev, local_irq_disable(); - if (acpi_idle_suspend) { - local_irq_enable(); - cpu_relax(); - return -EBUSY; - } if (cx->entry_method != ACPI_CSTATE_FFH) { current_thread_info()->status &= ~TS_POLLING; @@ -1014,10 +980,7 @@ static int acpi_idle_enter_bm(struct cpuidle_device *dev, if (cx->entry_method != ACPI_CSTATE_FFH) current_thread_info()->status |= TS_POLLING; - cx->usage++; - lapic_timer_state_broadcast(pr, cx, 0); - cx->time += idle_time; return index; } |