Skip to content

Commit 3af73d3

Browse files
committed
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: (29 commits) RDMA/nes: Fix slab corruption IB/mlx4: Set RLKEY bit for kernel QPs RDMA/nes: Correct error_module bit mask RDMA/nes: Fix routed RDMA connections RDMA/nes: Enhanced PFT management scheme RDMA/nes: Handle AE bounds violation RDMA/nes: Limit critical error interrupts RDMA/nes: Stop spurious MAC interrupts RDMA/nes: Correct tso_wqe_length RDMA/nes: Fill in firmware version for ethtool RDMA/nes: Use ethtool timer value RDMA/nes: Correct MAX TSO frags value RDMA/nes: Enable MC/UC after changing MTU RDMA/nes: Free NIC TX buffers when destroying NIC QP RDMA/nes: Fix MDC setting RDMA/nes: Add wqm_quanta module option RDMA/nes: Module parameter permissions RDMA/cxgb3: Set active_mtu in ib_port_attr RDMA/nes: Add support for 4-port 1G HP blade card RDMA/nes: Make mini_cm_connect() static ...
2 parents 13dd7f8 + eedd5d0 commit 3af73d3

28 files changed

+957
-355
lines changed

drivers/infiniband/core/cm.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3748,6 +3748,7 @@ static void cm_add_one(struct ib_device *ib_device)
37483748
cm_remove_port_fs(port);
37493749
}
37503750
device_unregister(cm_dev->device);
3751+
kfree(cm_dev);
37513752
}
37523753

37533754
static void cm_remove_one(struct ib_device *ib_device)
@@ -3776,6 +3777,7 @@ static void cm_remove_one(struct ib_device *ib_device)
37763777
cm_remove_port_fs(port);
37773778
}
37783779
device_unregister(cm_dev->device);
3780+
kfree(cm_dev);
37793781
}
37803782

37813783
static int __init ib_cm_init(void)

drivers/infiniband/core/mad.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1697,9 +1697,8 @@ static inline int rcv_has_same_gid(struct ib_mad_agent_private *mad_agent_priv,
16971697
u8 port_num = mad_agent_priv->agent.port_num;
16981698
u8 lmc;
16991699

1700-
send_resp = ((struct ib_mad *)(wr->send_buf.mad))->
1701-
mad_hdr.method & IB_MGMT_METHOD_RESP;
1702-
rcv_resp = rwc->recv_buf.mad->mad_hdr.method & IB_MGMT_METHOD_RESP;
1700+
send_resp = ib_response_mad((struct ib_mad *)wr->send_buf.mad);
1701+
rcv_resp = ib_response_mad(rwc->recv_buf.mad);
17031702

17041703
if (send_resp == rcv_resp)
17051704
/* both requests, or both responses. GIDs different */

drivers/infiniband/hw/amso1100/c2_provider.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,6 @@ static struct ib_qp *c2_create_qp(struct ib_pd *pd,
272272
pr_debug("%s: Invalid QP type: %d\n", __func__,
273273
init_attr->qp_type);
274274
return ERR_PTR(-EINVAL);
275-
break;
276275
}
277276

278277
if (err) {

drivers/infiniband/hw/cxgb3/iwch_provider.c

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1155,13 +1155,11 @@ static int iwch_query_port(struct ib_device *ibdev,
11551155
u8 port, struct ib_port_attr *props)
11561156
{
11571157
PDBG("%s ibdev %p\n", __func__, ibdev);
1158+
1159+
memset(props, 0, sizeof(struct ib_port_attr));
11581160
props->max_mtu = IB_MTU_4096;
1159-
props->lid = 0;
1160-
props->lmc = 0;
1161-
props->sm_lid = 0;
1162-
props->sm_sl = 0;
1161+
props->active_mtu = IB_MTU_2048;
11631162
props->state = IB_PORT_ACTIVE;
1164-
props->phys_state = 0;
11651163
props->port_cap_flags =
11661164
IB_PORT_CM_SUP |
11671165
IB_PORT_SNMP_TUNNEL_SUP |
@@ -1170,7 +1168,6 @@ static int iwch_query_port(struct ib_device *ibdev,
11701168
IB_PORT_VENDOR_CLASS_SUP | IB_PORT_BOOT_MGMT_SUP;
11711169
props->gid_tbl_len = 1;
11721170
props->pkey_tbl_len = 1;
1173-
props->qkey_viol_cntr = 0;
11741171
props->active_width = 2;
11751172
props->active_speed = 2;
11761173
props->max_msg_sz = -1;

drivers/infiniband/hw/ehca/ehca_classes.h

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,13 @@ struct ehca_qmap_entry {
164164
u16 reported;
165165
};
166166

167+
struct ehca_queue_map {
168+
struct ehca_qmap_entry *map;
169+
unsigned int entries;
170+
unsigned int tail;
171+
unsigned int left_to_poll;
172+
};
173+
167174
struct ehca_qp {
168175
union {
169176
struct ib_qp ib_qp;
@@ -173,8 +180,9 @@ struct ehca_qp {
173180
enum ehca_ext_qp_type ext_type;
174181
enum ib_qp_state state;
175182
struct ipz_queue ipz_squeue;
176-
struct ehca_qmap_entry *sq_map;
183+
struct ehca_queue_map sq_map;
177184
struct ipz_queue ipz_rqueue;
185+
struct ehca_queue_map rq_map;
178186
struct h_galpas galpas;
179187
u32 qkey;
180188
u32 real_qp_num;
@@ -204,6 +212,8 @@ struct ehca_qp {
204212
atomic_t nr_events; /* events seen */
205213
wait_queue_head_t wait_completion;
206214
int mig_armed;
215+
struct list_head sq_err_node;
216+
struct list_head rq_err_node;
207217
};
208218

209219
#define IS_SRQ(qp) (qp->ext_type == EQPT_SRQ)
@@ -233,6 +243,8 @@ struct ehca_cq {
233243
/* mmap counter for resources mapped into user space */
234244
u32 mm_count_queue;
235245
u32 mm_count_galpa;
246+
struct list_head sqp_err_list;
247+
struct list_head rqp_err_list;
236248
};
237249

238250
enum ehca_mr_flag {

drivers/infiniband/hw/ehca/ehca_cq.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,9 @@ struct ib_cq *ehca_create_cq(struct ib_device *device, int cqe, int comp_vector,
276276
for (i = 0; i < QP_HASHTAB_LEN; i++)
277277
INIT_HLIST_HEAD(&my_cq->qp_hashtab[i]);
278278

279+
INIT_LIST_HEAD(&my_cq->sqp_err_list);
280+
INIT_LIST_HEAD(&my_cq->rqp_err_list);
281+
279282
if (context) {
280283
struct ipz_queue *ipz_queue = &my_cq->ipz_queue;
281284
struct ehca_create_cq_resp resp;

drivers/infiniband/hw/ehca/ehca_iverbs.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -197,6 +197,8 @@ void ehca_poll_eqs(unsigned long data);
197197
int ehca_calc_ipd(struct ehca_shca *shca, int port,
198198
enum ib_rate path_rate, u32 *ipd);
199199

200+
void ehca_add_to_err_list(struct ehca_qp *qp, int on_sq);
201+
200202
#ifdef CONFIG_PPC_64K_PAGES
201203
void *ehca_alloc_fw_ctrlblock(gfp_t flags);
202204
void ehca_free_fw_ctrlblock(void *ptr);

0 commit comments

Comments
 (0)