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]
Message-ID: <20160311155546.GJ15775@codeblueprint.co.uk>
Date:	Fri, 11 Mar 2016 15:55:46 +0000
From:	Matt Fleming <matt@...eblueprint.co.uk>
To:	Chen Yu <yu.c.chen@...el.com>
Cc:	linux-acpi@...r.kernel.org, linux-pm@...r.kernel.org,
	"Rafael J. Wysocki" <rafael@...nel.org>,
	Len Brown <lenb@...nel.org>,
	Thomas Gleixner <tglx@...utronix.de>,
	Ingo Molnar <mingo@...hat.com>,
	"H. Peter Anvin" <hpa@...or.com>, rui.zhang@...el.com,
	linux-efi@...r.kernel.org, x86@...nel.org,
	linux-kernel@...r.kernel.org,
	Ard Biesheuvel <ard.biesheuvel@...aro.org>,
	Mark Salter <msalter@...hat.com>
Subject: Re: [PATCH][RFC,v4] ACPI / PM: Introduce efi poweroff for HW-full
 platforms without _S5

On Fri, 11 Mar, at 05:05:33PM, Chen Yu wrote:
> The problem is Linux registers pm_power_off = efi_power_off
> only if we are in hardware reduced mode. Actually, what we also
> want is to do this when ACPI S5 is simply not supported on
> non-legacy platforms. That should handle both the HW reduced mode,
> and the HW-full mode where the DSDT fails to supply an _S5 object.
> 
> This patch introduces pm_power_off_default which would be used by
> pm_power_off if nothing else is available. And in this case we
> leverage efi power off to be this role. However since efi power off
> may not be stable enough thus in order not to interfere with other
> poweroff path, we only make a minimum enhancement for x86 in
> native_machine_power_off.
> 
> Suggested-by: Len Brown <len.brown@...el.com>
> Signed-off-by: Chen Yu <yu.c.chen@...el.com>
> ---
> v4:
>  - Since in v3 efi_poweroff_required() is not guaranteed to run
>    after all of the other code that may register alternative
>    power off handling, add the pm_power_off_default that would
>    be used by pm_power_off if nothing else is available.
> v3:
>  - Only assign pm_power_off to efi_power_off when there are no
>    other pm_power_off registered at that time, in case other
>    commponents would like to customize their own implementation.
> ---
> v2:
>  - Convert the acpi_no_s5 to a global bool variable in sleep.c and
>    add a declaration to include/linux/acpi.h.
> ---
>  arch/x86/kernel/reboot.c       | 3 +++
>  arch/x86/platform/efi/quirks.c | 5 +++++
>  drivers/acpi/sleep.c           | 7 +++++++
>  drivers/firmware/efi/reboot.c  | 8 ++++++++
>  include/linux/acpi.h           | 1 +
>  include/linux/efi.h            | 1 +
>  include/linux/pm.h             | 1 +
>  kernel/reboot.c                | 1 +
>  8 files changed, 27 insertions(+)

Couple of things,

  1) I'm still waiting for an answer to my question on whether
     platforms without _S5 that need EFI reset actually exist. You
     said they "might" exist, which makes this all sound very
     speculative. It is not obvious to me that this approach makes
     sense. 

  2) In v4 you're modifying the generic EFI reboot code and should Cc
     other developers who might care, e.g. the arm64 folks. I've Cc'd
     them now.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ