Why MSI is limited to 32 MSI's per device

Mark Rutland mark.rutland at arm.com
Tue Jun 14 08:45:07 PDT 2016


On Tue, Jun 14, 2016 at 02:58:36PM +0000, valmiki wrote:
> Hi,
> 
> Why MSI interrupts are limited to 32 per device ?
> We have 16 bit data, with which we can have 2^16 combinaitons of different
> data, which in turn those many MSI vectors.

I assume you're specifically asking w.r.t. PCI.
 
Conventional PCI allowed devices to have up to 32 MSIs, no more. PCI
devices are only permitted to choose up to the low 5 bits of an MSI
payload. The remaining bits are shared by all MSIs.

> Other than increase in number interrupts to 2048 in MSI-X, what advantage we
> get by using MSI-X over MSI.

As alluded to below, MSI-X allows MSIs to be targeted at different
doorbell addresses, and provides full control of the payload of each
MSI.

There may be other gains that I am not aware of.

> I read MSI-X interrupts can be targeted to different CPU's in an SMP system.
> why can't MSI interrupts can be targeted to different processors ?  

Conventional PCI has a single doorbell address per device. I believe
that x86 had a doorbell per-cpu, and hence all MSIs for a device
targeted the same CPU. I'm not entirely certain on that, nor whether
things have changed.

Whether or not that holds elsewhere depends on your MSI controller and
IRQ controllers.

Thanks,
Mark.



More information about the linux-arm-kernel mailing list