On Mon, Sep 21, 2026 at 09:45:59PM +0200, Rafael J. Wysocki wrote:
From: "Rafael J. Wysocki" <redacted>
Corrently acpi/acpi_bus.h is included in linux/acpi.h only if
CONFIG_ACPI is set, but it contains declarations that are useful
otherwise too.
For consistency, modify linux/acpi.h to always include acpi/acpi_bus.h
and update the latter to avoid exposing too much when CONFIG_ACPI is
not set.
Since acpi_has_method() is called from some code build when
CONFIG_ACPI is unset, add a stub for it to the !CONFIG_ACPI
block in acpi/acpi_bus.h.
Reviewed-by: Sudeep Holla <sudeep.holla@kernel.org>
I was planning to just pull acpi_device_hid() out so that I can get rid
of CONFIG_ACPI in [1]. This looks much more elegant. Thanks for doing it.
--
Regards,
Sudeep
[1] https://lore.kernel.org/all/20260915-acpi_scmi_pcc-v5-4-298579e9f359@kernel.org (local)