Skip to content

Commit 6e24c88

Browse files
committed
x86/apic/msi: Enable PCI/IMS
Enable IMS in the domain init and allocation mapping code, but do not enable it on the vector domain as discussed in various threads on LKML. The interrupt remap domains can expand this setting like they do with PCI multi MSI. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Kevin Tian <kevin.tian@intel.com> Acked-by: Marc Zyngier <maz@kernel.org> Link: https://lore.kernel.org/r/20221124232327.022658817@linutronix.de
1 parent c9e5bea commit 6e24c88

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

  • arch/x86/kernel/apic

arch/x86/kernel/apic/msi.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,7 @@ static int x86_msi_prepare(struct irq_domain *domain, struct device *dev,
184184
alloc->type = X86_IRQ_ALLOC_TYPE_PCI_MSI;
185185
return 0;
186186
case DOMAIN_BUS_PCI_DEVICE_MSIX:
187+
case DOMAIN_BUS_PCI_DEVICE_IMS:
187188
alloc->type = X86_IRQ_ALLOC_TYPE_PCI_MSIX;
188189
return 0;
189190
default:
@@ -230,6 +231,10 @@ static bool x86_init_dev_msi_info(struct device *dev, struct irq_domain *domain,
230231
case DOMAIN_BUS_PCI_DEVICE_MSI:
231232
case DOMAIN_BUS_PCI_DEVICE_MSIX:
232233
break;
234+
case DOMAIN_BUS_PCI_DEVICE_IMS:
235+
if (!(pops->supported_flags & MSI_FLAG_PCI_IMS))
236+
return false;
237+
break;
233238
default:
234239
WARN_ON_ONCE(1);
235240
return false;

0 commit comments

Comments
 (0)