This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Juno MSI support

Hello,
I am working with a Juno platform (r1 & r2) and I have a PCIe endpoint device connected that supports 32 MSIs. When the endpoint device driver tries to register these IRQs using devm_request_irq() the request fails with error code 22.
Looking at the device tree for the juno platform (juno-base.dtsi) it seems as if the MSI interrupts are not mapped for the pcie controller node:
pcie_ctlr: pcie@40000000 {
        compatible = "arm,juno-r1-pcie", "plda,xpressrich3-axi", "pci-host-ecam-generic";
        device_type = "pci";
        reg = <0 0x40000000 0 0x10000000>;      /* ECAM config space */
        bus-range = <0 255>;
        linux,pci-domain = <0>;
        #address-cells = <3>;
        #size-cells = <2>;
        dma-coherent;
        ranges = <0x01000000 0x00 0x00000000 0x00 0x5f800000 0x0 0x00800000>,
                 <0x02000000 0x00 0x50000000 0x00 0x50000000 0x0 0x08000000>,
                 <0x42000000 0x40 0x00000000 0x40 0x00000000 0x1 0x00000000>;
        #interrupt-cells = <1>;
        interrupt-map-mask = <0 0 0 7>;
        interrupt-map = <0 0 0 1 &gic 0 0 0 136 4>,
                        <0 0 0 2 &gic 0 0 0 137 4>,
                        <0 0 0 3 &gic 0 0 0 138 4>,
                        <0 0 0 4 &gic 0 0 0 139 4>;
        msi-parent = <&v2m_0>;
        status = "disabled";
        iommu-map-mask = <0x0>; /* RC has no means to output PCI RID */
        iommu-map = <0x0 &smmu_pcie 0x0 0x1>;
};
The device tree only lists 4 interrupts. These interrupt numbers are also not aligned with what I would have expected based on table 3-3 of the Juno ARM r2 TRM.
My main questions therefore are:
1. how can I add the 32 MSI interrupts and have them properly connected to the GIC in the device tree?
2. why do the interrupt numbers in the dtsi (136-139) differ from the TRM (168-171)
Thank you.
Parents Reply Children
No data