x86: xen: Fix xen_initdom_restore_msi #ifdef
Subsystems (2)
PATCH 1/1 x86: xen: Fix xen_initdom_restore_msi #ifdef
From: Arnd Bergmann <[email protected]>
The #ifdef check around the definition doesn't match the one around the declaration, leading to a link failure when CONFIG_XEN_DOM0 is enabled but CONFIG_XEN_PV_DOM0 is not:
x86_64-linux-ld: arch/x86/kernel/apic/msi.o: in function `arch_restore_msi_irqs':
msi.c:(.text+0x29a): undefined reference to `xen_initdom_restore_msi'
Change the declaration to use the same check that was already present around the function definition.
---
This should go on top the irq/msi branch of the tip tree, which introduced the build regression
--- arch/x86/include/asm/xen/hypervisor.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/include/asm/xen/hypervisor.h +1 -1
@@ -59,7 +59,7 @@ static inline bool __init xen_x2apic_para_available(void)struct pci_dev ; -#ifdef CONFIG_XEN_DOM0 +#ifdef CONFIG_XEN_PV_DOM0 bool xen_initdom_restore_msi (struct pci_dev *dev);#else static inline bool xen_initdom_restore_msi (struct pci_dev *dev) {return true; }
Signature · 1 line
2.29.2
[tip: irq/msi] x86/xen: Use correct #ifdef guard for xen_initdom_restore_msi()
The following commit has been merged into the irq/msi branch of tip:
The following commit has been merged into the irq/msi branch of tip:
Commit-ID: 91f7d2dbf952f54442fa81bb62f78ee023179bf9 Gitweb: https://git.kernel.org/tip/91f7d2dbf952f54442fa81bb62f78ee023179bf9 Author: Arnd Bergmann <[email protected]> AuthorDate: Wed, 15 Dec 2021 15:01:59 +01:00 Committer: Thomas Gleixner <[email protected]> CommitterDate: Wed, 15 Dec 2021 16:13:23 +01:00
x86/xen: Use correct #ifdef guard for xen_initdom_restore_msi()
The #ifdef check around the definition doesn't match the one around the declaration, leading to a link failure when CONFIG_XEN_DOM0 is enabled but CONFIG_XEN_PV_DOM0 is not:
x86_64-linux-ld: arch/x86/kernel/apic/msi.o: in function `arch_restore_msi_irqs':
msi.c:(.text+0x29a): undefined reference to `xen_initdom_restore_msi'
Change the declaration to use the same check that was already present around the function definition.
--- arch/x86/include/asm/xen/hypervisor.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
arch/x86/include/asm/xen/hypervisor.h +1 -1
@@ -59,7 +59,7 @@ static inline bool __init xen_x2apic_para_available(void)struct pci_dev ; -#ifdef CONFIG_XEN_DOM0 +#ifdef CONFIG_XEN_PV_DOM0 bool xen_initdom_restore_msi (struct pci_dev *dev);#else static inline bool xen_initdom_restore_msi (struct pci_dev *dev) {return true; }