Skip to content

Commit bf1d33d

Browse files
committed
ACPI: processor_idle: Use acpi_idle_play_dead() for all C-states
Notice that acpi_processor_setup_cstates() can set state->enter_dead to acpi_idle_play_dead() for all C-states unconditionally and remove the confusing C-state type check done before setting it. No intentional functional impact. Suggested-by: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Reviewed-by: Mario Limonciello <mario.limonciello@amd.com> Tested-by: Mario Limonciello <mario.limonciello@amd.com> # 6.12-rc7 Acked-by: Peter Zijlstra (Intel) <peterz@infradead.org> Link: https://patch.msgid.link/2373563.ElGaqSPkdT@rjwysocki.net
1 parent 4e9ad03 commit bf1d33d

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

drivers/acpi/processor_idle.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -803,12 +803,12 @@ static int acpi_processor_setup_cstates(struct acpi_processor *pr)
803803
state->enter = acpi_idle_enter;
804804

805805
state->flags = 0;
806-
if (cx->type == ACPI_STATE_C1 || cx->type == ACPI_STATE_C2 ||
807-
cx->type == ACPI_STATE_C3) {
808-
state->enter_dead = acpi_idle_play_dead;
809-
if (cx->type != ACPI_STATE_C3)
810-
drv->safe_state_index = count;
811-
}
806+
807+
state->enter_dead = acpi_idle_play_dead;
808+
809+
if (cx->type == ACPI_STATE_C1 || cx->type == ACPI_STATE_C2)
810+
drv->safe_state_index = count;
811+
812812
/*
813813
* Halt-induced C1 is not good for ->enter_s2idle, because it
814814
* re-enables interrupts on exit. Moreover, C1 is generally not

0 commit comments

Comments
 (0)