[Infiniband] Add preliminary support for multi-port devices.

Arbel and Hermon cards both have multiple ports.  Add the
infrastructure required to register each port as a separate IB
device.  Don't yet register more than one port, since registration
will currently fail unless a valid link is detected.

Use ib_*_{set,get}_{drv,owner}data wrappers to access driver- and
owner-private data on Infiniband structures.
This commit is contained in:
Michael Brown
2008-02-27 13:59:56 +00:00
parent 6570203571
commit bc3f0a25c6
7 changed files with 284 additions and 119 deletions

View File

@@ -17,6 +17,10 @@
*
*/
/* Ports in existence */
#define ARBEL_NUM_PORTS 1
#define ARBEL_PORT_BASE 1
/* PCI BARs */
#define ARBEL_PCI_CONFIG_BAR PCI_BASE_ADDRESS_0
#define ARBEL_PCI_CONFIG_BAR_SIZE 0x100000
@@ -344,6 +348,9 @@ struct arbel {
/** Device limits */
struct arbel_dev_limits limits;
/** Infiniband devices */
struct ib_device *ibdev[ARBEL_NUM_PORTS];
};
/** Global protection domain */