From: Tom Tucker Date: Tue, 24 Jul 2007 19:31:52 +0000 (-0500) Subject: RDMA/amso1100: Initialize the wait_queue_head_t in the c2_qp structure X-Git-Tag: v2.6.23-rc2~149^2~8 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4e8e6ee380c3858151165d7455b4954782f145a0;p=linux-2.6 RDMA/amso1100: Initialize the wait_queue_head_t in the c2_qp structure Fix a crash if the driver has to wait for a QP reference to be dropped when destroying the QP. Signed-off-by: Ethan Burns Acked-by: Tom Tucker Signed-off-by: Roland Dreier --- diff --git a/drivers/infiniband/hw/amso1100/c2_qp.c b/drivers/infiniband/hw/amso1100/c2_qp.c index 420c1380f5..01d07862ea 100644 --- a/drivers/infiniband/hw/amso1100/c2_qp.c +++ b/drivers/infiniband/hw/amso1100/c2_qp.c @@ -506,6 +506,7 @@ int c2_alloc_qp(struct c2_dev *c2dev, qp->send_sgl_depth = qp_attrs->cap.max_send_sge; qp->rdma_write_sgl_depth = qp_attrs->cap.max_send_sge; qp->recv_sgl_depth = qp_attrs->cap.max_recv_sge; + init_waitqueue_head(&qp->wait); /* Initialize the SQ MQ */ q_size = be32_to_cpu(reply->sq_depth);