Skip to content

Commit 4849bc7

Browse files
nathanchancerafaeljw
authored andcommitted
ACPI / NUMA: Add stub function for pxm_to_node()
After commit 01feba5 ("ACPI: Do not create new NUMA domains from ACPI static tables that are not SRAT"): $ scripts/config --file arch/x86/configs/x86_64_defconfig -d NUMA -e ACPI_NFIT $ make -skj"$(nproc)" distclean defconfig drivers/acpi/nfit/ drivers/acpi/nfit/core.c: In function ‘acpi_nfit_register_region’: drivers/acpi/nfit/core.c:3010:27: error: implicit declaration of function ‘pxm_to_node’; did you mean ‘xa_to_node’? [-Werror=implicit-function-declaration] 3010 | ndr_desc->target_node = pxm_to_node(spa->proximity_domain); | ^~~~~~~~~~~ | xa_to_node cc1: some warnings being treated as errors ... Add a stub function like acpi_map_pxm_to_node() had so that the build continues to work. Fixes: 01feba5 ("ACPI: Do not create new NUMA domains from ACPI static tables that are not SRAT") Signed-off-by: Nathan Chancellor <natechancellor@gmail.com> Acked-by: Randy Dunlap <rdunlap@infradead.org> # build-tested Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Reviewed-by: Hanjun Guo <guohanjun@huawei.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
1 parent 95ac5bf commit 4849bc7

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

include/acpi/acpi_numa.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,10 @@ extern int acpi_numa __initdata;
2222
extern void bad_srat(void);
2323
extern int srat_disabled(void);
2424

25+
#else /* CONFIG_ACPI_NUMA */
26+
static inline int pxm_to_node(int pxm)
27+
{
28+
return 0;
29+
}
2530
#endif /* CONFIG_ACPI_NUMA */
2631
#endif /* __ACP_NUMA_H */

0 commit comments

Comments
 (0)