Re: [PATCH v3 1/6] freezer: Have {,un}lock_system_sleep() save/restore flags
From: Will Deacon <will@kernel.org>
Date: 2021-10-14 08:58:56
Also in:
lkml
From: Will Deacon <will@kernel.org>
Date: 2021-10-14 08:58:56
Also in:
lkml
On Sat, Oct 09, 2021 at 12:07:55PM +0200, Peter Zijlstra wrote:
Rafael explained that the reason for having both PF_NOFREEZE and
PF_FREEZER_SKIP is that {,un}lock_system_sleep() is callable from
kthread context that has previously called set_freezable().
In preparation of merging the flags, have {,un}lock_system_slee() save
and restore current->flags.
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
---
drivers/scsi/scsi_transport_spi.c | 7 ++++---
include/linux/suspend.h | 8 ++++----
kernel/power/hibernate.c | 35 ++++++++++++++++++++++-------------
kernel/power/main.c | 16 ++++++++++------
kernel/power/suspend.c | 12 ++++++++----
kernel/power/user.c | 24 ++++++++++++++----------
6 files changed, 62 insertions(+), 40 deletions(-)There's lots of Christmas tree inversion sprinkled in here, but the change looks good so: Acked-by: Will Deacon <will@kernel.org> Will