Hugh,

I have hier a PCI Express board and there are not the MSI capability set:

Class          = Unknown (Unknown)
Vendor ID      = 10b5h, PLX Technology, Inc.
Device ID      = 86e1h, Unknown Unknown
PCI index      = 0h
Class Codes    = ff0000h
Revision ID    = ach
Bus number     = 9
Device number  = 4
Function num   = 0
Status Reg     = 2b0h
Command Reg    = 17h
    I/O space access enabled
    Memory space access enabled
    Bus Master enabled
    Special Cycle operations ignored
    Memory Write and Invalidate enabled
    Palette Snooping disabled
    Parity Error Response disabled
    Data/Address stepping disabled
    SERR# driver disabled
    Fast back-to-back transactions to different agents disabled
    PCI INTx enabled
Header type    = 0h Single-function
BIST           = 0h Build-in-self-test not supported
Latency Timer  = 20h
Cache Line Size= 10h un-cacheable
BAR - 0 [Mem]  = 55480000h 32bit length 512 enabled
BAR - 1 [I/O]  = 3000h length 256 enabled
BAR - 2 [Mem]  = 55400000h 32bit length 524288 enabled
Subsystem Vendor ID = 14a0h
Subsystem ID        = 2bh
Max Lat        = 0ns
Min Gnt        = 0ns
PCI Int Pin    = INT A
Interrupt line = 18
CPU Interrupt  = 12h
Capabilities Pointer = 40h
Capability ID        = 1h - Power Management
Capabilities         = 0h - 0h
Capability ID        = 6h - CompactPCI Hot Swap <<<- it isn't a CompactPCI board and I'm missing the capability 5h !
Capabilities         = 0h - 3h
Capability ID        = 3h - VPD
Capabilities         = 0h - 0h
Device Dependent Registers:
0x040:  0148 0000 0000 0000   064c 0000 0300 0000
0x050:  0000 0000 0000 0000   0000 0000 0000 0000
...
0x0f0:  0000 0000 0000 0000   0000 0000 0000 0000

pci_attach_device returns also a false default IRQ back !

Regards

--Armin



Hugh Brown wrote:
If you run 'pci -v' you will see all of the capabilities for all of the devices. The MSI or MSIX interrupt is only assigned once a pci_attach_device() has been performed, so if there is no driver running against a MSI or MSIX capable device, you will see the standard IRQ interrupt. See the attached pci.txt file where the gigabit Ethernet device has been assigned MSIX interrupts.

-- 
Hugh Brown
QNX Software Systems Limited
1001 Farrar Rd.,
Ottawa. ON. K2K 0B3.
Telephone: 613-591-0931



From: Armin Steinhoff <community-noreply@qnx.com>
Reply-To: "general-community@community.qnx.com" <general-community@community.qnx.com>
Date: Wednesday, 4 July, 2012 2:33 PM
To: "general-community@community.qnx.com" <general-community@community.qnx.com>
Cc: Info System - IS Notifications <is-notifications@qnx.com>, Info System - IS Notifications <is-notifications@qnx.com>, Info System - IS Notifications <is-notifications@qnx.com>, Info System - IS Notifications <is-notifications@qnx.com>
Subject: Re: PCI Express

Hugh Brown wrote:
The PCI server enables either the MSI or MSIX capability depending on
which is selected and also assigns MSI/X IRQ numbers to the device. Is
this what you are talking about?

Yes and No.
>From the example provided by the pci_attach_device documentation:

if (pci_read_config8 (bus, devfn, cap_ptr, 1, &cap))  <<<--- that means the OS must set the capabilities before
                                                                                 <<<--- but in the dumps of pci or lspci  I saw
                                                                                 <<<--- never entries of the MSI capabilities of PCIe devices
    return (-1);
if (cap == PCI_CAP_MSI)

The assigned IRQ seems alway connected to an INTx line ... which is the default non MSI mapping.

Regards

--Armin