lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <9c61f778-fd65-4b28-8bda-e8463dda2862@collabora.com>
Date: Mon, 24 Nov 2025 18:03:16 +0500
From: Muhammad Usama Anjum <usama.anjum@...labora.com>
To: "Rafael J. Wysocki" <rafael@...nel.org>, superm1@...nel.org
Cc: usama.anjum@...labora.com, kernel@...labora.com,
 Len Brown <lenb@...nel.org>, linux-pm@...r.kernel.org,
 Danilo Krummrich <dakr@...nel.org>, Pavel Machek <pavel@...nel.org>,
 Thomas Gleixner <tglx@...utronix.de>, Peter Zijlstra <peterz@...radead.org>,
 Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
 linux-input@...r.kernel.org, Dmitry Torokhov <dmitry.torokhov@...il.com>,
 linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 0/4] PM: Hibernate: Add hibernation cancellation support

Hi,

Please review the patches when you have time. 

On 11/7/25 11:44 PM, Muhammad Usama Anjum wrote:
> On a normal laptop/PC, the hibernation takes 15-20 seconds which is
> considerable time. Once hibernation is triggered from command line or by
> some GUI option, the hibernation cannot be cancelled until completed.
> Its not a blocker, but poor user experience.
> 
> When power button is pressed during hibernation, it generates interrupt
> and then the event is routed to userspace. If systemd is being used, the
> logind handles these events and performs the specific action.
> 
> During hibernation, the first stage is to freeze the userspace. Hence
> even if the power button is pressed, it doesn't aborts the hibernation
> as user space daemon is frozen.
> 
> My device takes ~19 seconds to hibernate. When I was testing hibernation
> using rtcwake with timeout of 10 seconds, I found out that hibernation
> gets canceled around 10 seconds mark when the interrupt fires.
> 
> In this series, the idea is to find a way to cancel the hibernation.
> With this series applied, the hibernation gets cancelled gracefully.
> 
> The hibernation cancellation support isn't present in very last stage
> just before power_down(). I've not been able to handle the error paths
> correctly there yet as logs aren't available from that stage. I'll send
> that patch separately when it works.
> 
> Cc: rafael@...nel.org
> Cc: superm1@...nel.org
> ---
> Changes since RFC:
> - Update description of patches
> - Use pm_sleep_transition_in_progress() instead of
>   hibernation_in_progress()
> 
> Muhammad Usama Anjum (4):
>   PM: hibernate: export pm_sleep_transition_in_progress()
>   ACPI: button: Cancel hibernation if button is pressed during
>     hibernation
>   Input: Ignore the KEY_POWER events if hibernation is in progress
>   PM: sleep: clear pm_abort_suspend at suspend
> 
>  drivers/acpi/button.c     | 12 +++++++++---
>  drivers/base/power/main.c |  2 ++
>  drivers/input/input.c     |  6 ++++++
>  kernel/cpu.c              |  1 +
>  kernel/power/hibernate.c  |  5 ++++-
>  kernel/power/main.c       |  1 +
>  kernel/power/process.c    |  1 +
>  7 files changed, 24 insertions(+), 4 deletions(-)
> 


-- 
---
Thanks,
Usama

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ