Skip to content

Commit fbd5d52

Browse files
arndbrafaeljw
authored andcommitted
ACPI: add acpi_get_cpu_uid() stub helper
When ACPI is disabled, x86 Xen support fails to build: arch/x86/xen/enlighten_hvm.c: In function 'xen_cpu_up_prepare_hvm': arch/x86/xen/enlighten_hvm.c:165:13: error: implicit declaration of function 'acpi_get_cpu_uid' [-Wimplicit-function-declaration] 165 | if (acpi_get_cpu_uid(cpu, &cpu_uid) == 0) | ^~~~~~~~~~~~~~~~ Add a trivial stub that can be used in place of the real function. Fixes: f652d0a ("ACPI: Centralize acpi_get_cpu_uid() declaration in include/linux/acpi.h") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Chengwen Feng <fengchengwen@huawei.com> Link: https://patch.msgid.link/20260413070132.3828606-1-arnd@kernel.org Signed-off-by: Rafael J. Wysocki <rjw@rjwysocki.net>
1 parent 2e31b16 commit fbd5d52

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

include/linux/acpi.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -959,6 +959,12 @@ static inline int acpi_table_parse(char *id,
959959
return -ENODEV;
960960
}
961961

962+
static inline int acpi_get_cpu_uid(unsigned int cpu, u32 *uid)
963+
{
964+
*uid = cpu;
965+
return 0;
966+
}
967+
962968
static inline int acpi_nvs_register(__u64 start, __u64 size)
963969
{
964970
return 0;

0 commit comments

Comments
 (0)