Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband: (63 commits) IB/qib: clean up properly if pci_set_consistent_dma_mask() fails IB/qib: Allow driver to load if PCIe AER fails IB/qib: Fix uninitialized pointer if CONFIG_PCI_MSI not set IB/qib: Fix extra log level in qib_early_err() RDMA/cxgb4: Remove unnecessary KERN_<level> use RDMA/cxgb3: Remove unnecessary KERN_<level> use IB/core: Add link layer type information to sysfs IB/mlx4: Add VLAN support for IBoE IB/core: Add VLAN support for IBoE IB/mlx4: Add support for IBoE mlx4_en: Change multicast promiscuous mode to support IBoE mlx4_core: Update data structures and constants for IBoE mlx4_core: Allow protocol drivers to find corresponding interfaces IB/uverbs: Return link layer type to userspace for query port operation IB/srp: Sync buffer before posting send IB/srp: Use list_first_entry() IB/srp: Reduce number of BUSY conditions IB/srp: Eliminate two forward declarations IB/mlx4: Signal node desc changes to SM by using FW to generate trap 144 IB: Replace EXTRA_CFLAGS with ccflags-y ...
This commit is contained in:
@@ -58,6 +58,7 @@ enum {
|
||||
MLX4_CMD_SENSE_PORT = 0x4d,
|
||||
MLX4_CMD_HW_HEALTH_CHECK = 0x50,
|
||||
MLX4_CMD_SET_PORT = 0xc,
|
||||
MLX4_CMD_SET_NODE = 0x5a,
|
||||
MLX4_CMD_ACCESS_DDR = 0x2e,
|
||||
MLX4_CMD_MAP_ICM = 0xffa,
|
||||
MLX4_CMD_UNMAP_ICM = 0xff9,
|
||||
@@ -141,6 +142,7 @@ enum {
|
||||
MLX4_SET_PORT_MAC_TABLE = 0x2,
|
||||
MLX4_SET_PORT_VLAN_TABLE = 0x3,
|
||||
MLX4_SET_PORT_PRIO_MAP = 0x4,
|
||||
MLX4_SET_PORT_GID_TABLE = 0x5,
|
||||
};
|
||||
|
||||
struct mlx4_dev;
|
||||
|
||||
@@ -67,7 +67,8 @@ enum {
|
||||
MLX4_DEV_CAP_FLAG_ATOMIC = 1 << 18,
|
||||
MLX4_DEV_CAP_FLAG_RAW_MCAST = 1 << 19,
|
||||
MLX4_DEV_CAP_FLAG_UD_AV_PORT = 1 << 20,
|
||||
MLX4_DEV_CAP_FLAG_UD_MCAST = 1 << 21
|
||||
MLX4_DEV_CAP_FLAG_UD_MCAST = 1 << 21,
|
||||
MLX4_DEV_CAP_FLAG_IBOE = 1 << 30
|
||||
};
|
||||
|
||||
enum {
|
||||
@@ -171,6 +172,10 @@ enum {
|
||||
MLX4_NUM_FEXCH = 64 * 1024,
|
||||
};
|
||||
|
||||
enum {
|
||||
MLX4_MAX_FAST_REG_PAGES = 511,
|
||||
};
|
||||
|
||||
static inline u64 mlx4_fw_ver(u64 major, u64 minor, u64 subminor)
|
||||
{
|
||||
return (major << 32) | (minor << 16) | subminor;
|
||||
@@ -379,6 +384,27 @@ struct mlx4_av {
|
||||
u8 dgid[16];
|
||||
};
|
||||
|
||||
struct mlx4_eth_av {
|
||||
__be32 port_pd;
|
||||
u8 reserved1;
|
||||
u8 smac_idx;
|
||||
u16 reserved2;
|
||||
u8 reserved3;
|
||||
u8 gid_index;
|
||||
u8 stat_rate;
|
||||
u8 hop_limit;
|
||||
__be32 sl_tclass_flowlabel;
|
||||
u8 dgid[16];
|
||||
u32 reserved4[2];
|
||||
__be16 vlan;
|
||||
u8 mac[6];
|
||||
};
|
||||
|
||||
union mlx4_ext_av {
|
||||
struct mlx4_av ib;
|
||||
struct mlx4_eth_av eth;
|
||||
};
|
||||
|
||||
struct mlx4_dev {
|
||||
struct pci_dev *pdev;
|
||||
unsigned long flags;
|
||||
@@ -407,6 +433,12 @@ struct mlx4_init_port_param {
|
||||
if (((type) == MLX4_PORT_TYPE_IB ? (dev)->caps.port_mask : \
|
||||
~(dev)->caps.port_mask) & 1 << ((port) - 1))
|
||||
|
||||
#define mlx4_foreach_ib_transport_port(port, dev) \
|
||||
for ((port) = 1; (port) <= (dev)->caps.num_ports; (port)++) \
|
||||
if (((dev)->caps.port_mask & 1 << ((port) - 1)) || \
|
||||
((dev)->caps.flags & MLX4_DEV_CAP_FLAG_IBOE))
|
||||
|
||||
|
||||
int mlx4_buf_alloc(struct mlx4_dev *dev, int size, int max_direct,
|
||||
struct mlx4_buf *buf);
|
||||
void mlx4_buf_free(struct mlx4_dev *dev, int size, struct mlx4_buf *buf);
|
||||
@@ -474,6 +506,7 @@ int mlx4_multicast_detach(struct mlx4_dev *dev, struct mlx4_qp *qp, u8 gid[16]);
|
||||
int mlx4_register_mac(struct mlx4_dev *dev, u8 port, u64 mac, int *index);
|
||||
void mlx4_unregister_mac(struct mlx4_dev *dev, u8 port, int index);
|
||||
|
||||
int mlx4_find_cached_vlan(struct mlx4_dev *dev, u8 port, u16 vid, int *idx);
|
||||
int mlx4_register_vlan(struct mlx4_dev *dev, u8 port, u16 vlan, int *index);
|
||||
void mlx4_unregister_vlan(struct mlx4_dev *dev, u8 port, int index);
|
||||
|
||||
|
||||
@@ -44,15 +44,24 @@ enum mlx4_dev_event {
|
||||
MLX4_DEV_EVENT_PORT_REINIT,
|
||||
};
|
||||
|
||||
enum mlx4_protocol {
|
||||
MLX4_PROTOCOL_IB,
|
||||
MLX4_PROTOCOL_EN,
|
||||
};
|
||||
|
||||
struct mlx4_interface {
|
||||
void * (*add) (struct mlx4_dev *dev);
|
||||
void (*remove)(struct mlx4_dev *dev, void *context);
|
||||
void (*event) (struct mlx4_dev *dev, void *context,
|
||||
enum mlx4_dev_event event, int port);
|
||||
void * (*get_dev)(struct mlx4_dev *dev, void *context, u8 port);
|
||||
struct list_head list;
|
||||
enum mlx4_protocol protocol;
|
||||
};
|
||||
|
||||
int mlx4_register_interface(struct mlx4_interface *intf);
|
||||
void mlx4_unregister_interface(struct mlx4_interface *intf);
|
||||
|
||||
void *mlx4_get_protocol_dev(struct mlx4_dev *dev, enum mlx4_protocol proto, int port);
|
||||
|
||||
#endif /* MLX4_DRIVER_H */
|
||||
|
||||
@@ -109,10 +109,11 @@ struct mlx4_qp_path {
|
||||
__be32 tclass_flowlabel;
|
||||
u8 rgid[16];
|
||||
u8 sched_queue;
|
||||
u8 snooper_flags;
|
||||
u8 vlan_index;
|
||||
u8 reserved3[2];
|
||||
u8 counter_index;
|
||||
u8 reserved4[7];
|
||||
u8 reserved4;
|
||||
u8 dmac[6];
|
||||
};
|
||||
|
||||
struct mlx4_qp_context {
|
||||
@@ -166,6 +167,7 @@ enum {
|
||||
MLX4_WQE_CTRL_TCP_UDP_CSUM = 1 << 5,
|
||||
MLX4_WQE_CTRL_INS_VLAN = 1 << 6,
|
||||
MLX4_WQE_CTRL_STRONG_ORDER = 1 << 7,
|
||||
MLX4_WQE_CTRL_FORCE_LOOPBACK = 1 << 0,
|
||||
};
|
||||
|
||||
struct mlx4_wqe_ctrl_seg {
|
||||
@@ -219,7 +221,8 @@ struct mlx4_wqe_datagram_seg {
|
||||
__be32 av[8];
|
||||
__be32 dqpn;
|
||||
__be32 qkey;
|
||||
__be32 reservd[2];
|
||||
__be16 vlan;
|
||||
u8 mac[6];
|
||||
};
|
||||
|
||||
struct mlx4_wqe_lso_seg {
|
||||
|
||||
Reference in New Issue
Block a user