diff options
author | Russell King (Oracle) <rmk+kernel@armlinux.org.uk> | 2022-04-01 17:12:31 +0200 |
---|---|---|
committer | Russell King (Oracle) <rmk+kernel@armlinux.org.uk> | 2022-04-01 17:12:31 +0200 |
commit | de4fb176622d54a82ea3ceb7362392aaf5ff0b5a (patch) | |
tree | 8b510763d14d89b97cd719e79834c84e095932d7 /arch/x86/kernel/apic/msi.c | |
parent | ARM: 9191/1: arm/stacktrace, kasan: Silence KASAN warnings in unwind_frame() (diff) | |
parent | ARM: 9189/1: decompressor: fix unneeded rebuilds of library objects (diff) | |
download | linux-de4fb176622d54a82ea3ceb7362392aaf5ff0b5a.tar.xz linux-de4fb176622d54a82ea3ceb7362392aaf5ff0b5a.zip |
Merge branches 'fixes' and 'misc' into for-linus
Diffstat (limited to 'arch/x86/kernel/apic/msi.c')
-rw-r--r-- | arch/x86/kernel/apic/msi.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/arch/x86/kernel/apic/msi.c b/arch/x86/kernel/apic/msi.c index dbacb9ec8843..7517eb05bdc1 100644 --- a/arch/x86/kernel/apic/msi.c +++ b/arch/x86/kernel/apic/msi.c @@ -19,6 +19,7 @@ #include <asm/hw_irq.h> #include <asm/apic.h> #include <asm/irq_remapping.h> +#include <asm/xen/hypervisor.h> struct irq_domain *x86_pci_msi_default_domain __ro_after_init; @@ -159,11 +160,8 @@ static struct irq_chip pci_msi_controller = { int pci_msi_prepare(struct irq_domain *domain, struct device *dev, int nvec, msi_alloc_info_t *arg) { - struct pci_dev *pdev = to_pci_dev(dev); - struct msi_desc *desc = first_pci_msi_entry(pdev); - init_irq_alloc_info(arg, NULL); - if (desc->msi_attrib.is_msix) { + if (to_pci_dev(dev)->msix_enabled) { arg->type = X86_IRQ_ALLOC_TYPE_PCI_MSIX; } else { arg->type = X86_IRQ_ALLOC_TYPE_PCI_MSI; @@ -345,3 +343,8 @@ void dmar_free_hwirq(int irq) irq_domain_free_irqs(irq, 1); } #endif + +bool arch_restore_msi_irqs(struct pci_dev *dev) +{ + return xen_initdom_restore_msi(dev); +} |