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: <CAJZ5v0iXrDULryT-t9Rt+Cq2i2uBH8tedobtk7h76gZocmiXWg@mail.gmail.com>
Date: Fri, 7 Mar 2025 15:32:56 +0100
From: "Rafael J. Wysocki" <rafael@...nel.org>
To: Mario Limonciello <superm1@...nel.org>
Cc: "Rafael J . Wysocki" <rjw@...ysocki.net>, Linus Walleij <linus.walleij@...aro.org>, 
	"open list:PIN CONTROL SUBSYSTEM" <linux-gpio@...r.kernel.org>, open list <linux-kernel@...r.kernel.org>, 
	linux-acpi@...r.kernel.org, Basavaraj Natikar <Basavaraj.Natikar@....com>, 
	Shyam Sundar S K <Shyam-sundar.S-k@....com>, Mario Limonciello <mario.limonciello@....com>, 
	kernel test robot <lkp@...el.com>
Subject: Re: [PATCH v3 RESEND 1/2] ACPI: Add missing prototype for non
 CONFIG_SUSPEND/CONFIG_X86 case

On Wed, Mar 5, 2025 at 11:01 PM Mario Limonciello <superm1@...nel.org> wrote:
>
> From: Mario Limonciello <mario.limonciello@....com>
>
> acpi_register_lps0_dev() and acpi_unregister_lps0_dev() may be used
> in drivers that don't require CONFIG_SUSPEND or compile on !X86.
>
> Add prototypes for those cases.
>
> Reported-by: kernel test robot <lkp@...el.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202502191627.fRgoBwcZ-lkp@intel.com/
> Signed-off-by: Mario Limonciello <mario.limonciello@....com>
> ---
> v3:
>  * Add struct acpi_s2idle_dev_ops outside defines too
> ---
>  include/linux/acpi.h | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/include/linux/acpi.h b/include/linux/acpi.h
> index 4e495b29c640f..8d2abe5dede93 100644
> --- a/include/linux/acpi.h
> +++ b/include/linux/acpi.h
> @@ -1115,13 +1115,13 @@ void acpi_os_set_prepare_extended_sleep(int (*func)(u8 sleep_state,
>
>  acpi_status acpi_os_prepare_extended_sleep(u8 sleep_state,
>                                            u32 val_a, u32 val_b);
> -#if defined(CONFIG_SUSPEND) && defined(CONFIG_X86)
>  struct acpi_s2idle_dev_ops {
>         struct list_head list_node;
>         void (*prepare)(void);
>         void (*check)(void);
>         void (*restore)(void);
>  };
> +#if defined(CONFIG_SUSPEND) && defined(CONFIG_X86)
>  int acpi_register_lps0_dev(struct acpi_s2idle_dev_ops *arg);
>  void acpi_unregister_lps0_dev(struct acpi_s2idle_dev_ops *arg);
>  int acpi_get_lps0_constraint(struct acpi_device *adev);
> @@ -1130,6 +1130,13 @@ static inline int acpi_get_lps0_constraint(struct device *dev)
>  {
>         return ACPI_STATE_UNKNOWN;
>  }
> +static inline int acpi_register_lps0_dev(struct acpi_s2idle_dev_ops *arg)
> +{
> +       return -ENODEV;
> +}
> +static inline void acpi_unregister_lps0_dev(struct acpi_s2idle_dev_ops *arg)
> +{
> +}
>  #endif /* CONFIG_SUSPEND && CONFIG_X86 */
>  void arch_reserve_mem_area(acpi_physical_address addr, size_t size);
>  #else
> --

Applied as 6.15 material, thanks!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ