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] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 01 Jun 2023 18:31:33 -0700
From:   "David E. Box" <david.e.box@...ux.intel.com>
To:     Mario Limonciello <mario.limonciello@....com>, rafael@...nel.org
Cc:     linux-acpi@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-pm@...r.kernel.org
Subject: Re: [PATCH] ACPI: x86: Adjust Microsoft LPS0 _DSM handling sequence

On Thu, 2023-06-01 at 18:39 -0500, Mario Limonciello wrote:
> In Windows the Microsoft _DSM doesn't call functions 3->5->7 for suspend
> and 8->6->4 for resume like Linux currently does.
> 
> Rather it calls 3->7->5 for suspend and 6->8->4 for resume.
> Align this calling order for Linux as well.
> 
> Link:
> https://learn.microsoft.com/en-us/windows-hardware/design/device-experiences/modern-standby-states

I didn't catch the ordering in the link. Was there any issue that prompted this
change?

David

> Signed-off-by: Mario Limonciello <mario.limonciello@....com>
> ---
>  drivers/acpi/x86/s2idle.c | 14 +++++++-------
>  1 file changed, 7 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/acpi/x86/s2idle.c b/drivers/acpi/x86/s2idle.c
> index e499c60c4579..7214197c15a0 100644
> --- a/drivers/acpi/x86/s2idle.c
> +++ b/drivers/acpi/x86/s2idle.c
> @@ -485,11 +485,11 @@ int acpi_s2idle_prepare_late(void)
>                                         ACPI_LPS0_ENTRY,
>                                         lps0_dsm_func_mask, lps0_dsm_guid);
>         if (lps0_dsm_func_mask_microsoft > 0) {
> -               acpi_sleep_run_lps0_dsm(ACPI_LPS0_ENTRY,
> -                               lps0_dsm_func_mask_microsoft,
> lps0_dsm_guid_microsoft);
>                 /* modern standby entry */
>                 acpi_sleep_run_lps0_dsm(ACPI_LPS0_MS_ENTRY,
>                                 lps0_dsm_func_mask_microsoft,
> lps0_dsm_guid_microsoft);
> +               acpi_sleep_run_lps0_dsm(ACPI_LPS0_ENTRY,
> +                               lps0_dsm_func_mask_microsoft,
> lps0_dsm_guid_microsoft);
>         }
>  
>         list_for_each_entry(handler, &lps0_s2idle_devops_head, list_node) {
> @@ -524,11 +524,6 @@ void acpi_s2idle_restore_early(void)
>                 if (handler->restore)
>                         handler->restore();
>  
> -       /* Modern standby exit */
> -       if (lps0_dsm_func_mask_microsoft > 0)
> -               acpi_sleep_run_lps0_dsm(ACPI_LPS0_MS_EXIT,
> -                               lps0_dsm_func_mask_microsoft,
> lps0_dsm_guid_microsoft);
> -
>         /* LPS0 exit */
>         if (lps0_dsm_func_mask > 0)
>                 acpi_sleep_run_lps0_dsm(acpi_s2idle_vendor_amd() ?
> @@ -539,6 +534,11 @@ void acpi_s2idle_restore_early(void)
>                 acpi_sleep_run_lps0_dsm(ACPI_LPS0_EXIT,
>                                 lps0_dsm_func_mask_microsoft,
> lps0_dsm_guid_microsoft);
>  
> +       /* Modern standby exit */
> +       if (lps0_dsm_func_mask_microsoft > 0)
> +               acpi_sleep_run_lps0_dsm(ACPI_LPS0_MS_EXIT,
> +                               lps0_dsm_func_mask_microsoft,
> lps0_dsm_guid_microsoft);
> +
>         /* Screen on */
>         if (lps0_dsm_func_mask_microsoft > 0)
>                 acpi_sleep_run_lps0_dsm(ACPI_LPS0_SCREEN_ON,

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ