Skip to content

Commit ba51ebb

Browse files
kerneltoastPixelBoot
authored andcommitted
PM: sleep: Don't allow s2idle to be used
Unfortunately, s2idle is only somewhat functional. Although commit 70441d3 ("cpuidle: lpm_levels: add soft watchdog for s2idle") makes s2idle usable, there are still CPU stalls caused by s2idle's buggy behavior, and the aforementioned hack doesn't address them. Therefore, let's stop userspace from enabling s2idle and instead enforce the default deep sleep mode. Signed-off-by: Sultan Alsawaf <[email protected]>
1 parent 0b3b40b commit ba51ebb

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

kernel/power/main.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,8 @@ static ssize_t mem_sleep_store(struct kobject *kobj, struct kobj_attribute *attr
127127
suspend_state_t state;
128128
int error;
129129

130+
/* Don't allow userspace to select s2idle */
131+
return n;
130132
error = pm_autosleep_lock();
131133
if (error)
132134
return error;

0 commit comments

Comments
 (0)