* Re: [PATCH v6 2/5] ACPI: bus: Add stub acpi_sleep_state_supported() in non-ACPI cases
[not found] ` <1676021646-2619-3-git-send-email-ssengar@linux.microsoft.com>
@ 2023-02-13 18:40 ` Rafael J. Wysocki
0 siblings, 0 replies; only message in thread
From: Rafael J. Wysocki @ 2023-02-13 18:40 UTC (permalink / raw)
To: Saurabh Sengar
Cc: devicetree, wei.liu, mikelley, linux-hyperv, rafael, haiyangz,
daniel.lezcano, decui, linux-kernel, virtualization, linux-acpi,
robh+dt, dphadke, krzysztof.kozlowski+dt, tglx, lenb
On Fri, Feb 10, 2023 at 10:34 AM Saurabh Sengar
<ssengar@linux.microsoft.com> wrote:
>
> acpi_sleep_state_supported() is defined only when CONFIG_ACPI=y. The
> function is in acpi_bus.h, and acpi_bus.h can only be used in
> CONFIG_ACPI=y cases. Add the stub function to linux/acpi.h to make
> compilation successful for !CONFIG_ACPI cases.
>
> Signed-off-by: Saurabh Sengar <ssengar@linux.microsoft.com>
Acked-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
and please feel free to toute this patch whichever way is convenient.
Thanks!
> ---
> include/linux/acpi.h | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/include/linux/acpi.h b/include/linux/acpi.h
> index efff750f326d..d331f76b0c19 100644
> --- a/include/linux/acpi.h
> +++ b/include/linux/acpi.h
> @@ -1075,6 +1075,11 @@ static inline u32 acpi_osc_ctx_get_cxl_control(struct acpi_osc_context *context)
> return 0;
> }
>
> +static inline bool acpi_sleep_state_supported(u8 sleep_state)
> +{
> + return false;
> +}
> +
> #endif /* !CONFIG_ACPI */
>
> #ifdef CONFIG_ACPI_HOTPLUG_IOAPIC
> --
> 2.34.1
>
_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-02-13 18:41 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <1676021646-2619-1-git-send-email-ssengar@linux.microsoft.com>
[not found] ` <1676021646-2619-3-git-send-email-ssengar@linux.microsoft.com>
2023-02-13 18:40 ` [PATCH v6 2/5] ACPI: bus: Add stub acpi_sleep_state_supported() in non-ACPI cases Rafael J. Wysocki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).