Lines Matching refs:wd

1008 	struct send_wid	*wd;
1030 wd = (struct send_wid *)(uintptr_t)wc.wc_id;
1031 qp = wd->qp;
1034 mutex_enter(&wd->sendwait_lock);
1037 wd->status = RDMA_SUCCESS;
1060 wd->status = RDMA_FAILED;
1068 if (wd->cv_sig == 1) {
1072 cv_signal(&wd->wait_cv);
1073 mutex_exit(&wd->sendwait_lock);
1079 for (i = 0; i < wd->nsbufs; i++) {
1080 rib_rbuf_free(qptoc(wd->qp),
1082 (void *)(uintptr_t)wd->sbufaddr[i]);
1088 mutex_exit(&wd->sendwait_lock);
1089 (void) rib_free_sendwait(wd);
1101 struct send_wid *wd;
1123 wd = (struct send_wid *)(uintptr_t)wc.wc_id;
1124 qp = wd->qp;
1126 mutex_enter(&wd->sendwait_lock);
1130 wd->status = RDMA_SUCCESS;
1138 wd->status = RDMA_FAILED;
1146 if (wd->cv_sig == 1) {
1150 cv_signal(&wd->wait_cv);
1151 mutex_exit(&wd->sendwait_lock);
1157 for (i = 0; i < wd->nsbufs; i++) {
1158 rib_rbuf_free(qptoc(wd->qp),
1160 (void *)(uintptr_t)wd->sbufaddr[i]);
1166 mutex_exit(&wd->sendwait_lock);
1167 (void) rib_free_sendwait(wd);
2178 rib_sendwait(rib_qp_t *qp, struct send_wid *wd)
2187 ASSERT(wd != NULL);
2188 mutex_enter(&wd->sendwait_lock);
2189 if (wd->status == (uint_t)SEND_WAIT) {
2194 while ((cv_wait_ret = cv_timedwait(&wd->wait_cv,
2195 &wd->sendwait_lock, timout)) > 0 &&
2196 wd->status == (uint_t)SEND_WAIT)
2202 wd->cv_sig = 0; /* no signal needed */
2209 while ((cv_wait_ret = cv_timedwait_sig(&wd->wait_cv,
2210 &wd->sendwait_lock, timout)) > 0 &&
2211 wd->status == (uint_t)SEND_WAIT)
2217 wd->cv_sig = 0; /* no signal needed */
2223 wd->cv_sig = 0; /* no signal needed */
2232 if (wd->status != (uint_t)SEND_WAIT) {
2234 if (wd->status != RDMA_SUCCESS) {
2235 switch (wd->status) {
2244 for (i = 0; i < wd->nsbufs; i++) {
2246 (void *)(uintptr_t)wd->sbufaddr[i]);
2251 mutex_exit(&wd->sendwait_lock);
2252 (void) rib_free_sendwait(wd);
2255 mutex_exit(&wd->sendwait_lock);
2263 struct send_wid *wd;
2265 wd = kmem_zalloc(sizeof (struct send_wid), KM_SLEEP);
2266 wd->xid = xid;
2267 wd->cv_sig = cv_sig;
2268 wd->qp = qp;
2269 cv_init(&wd->wait_cv, NULL, CV_DEFAULT, NULL);
2270 mutex_init(&wd->sendwait_lock, NULL, MUTEX_DRIVER, NULL);
2271 wd->status = (uint_t)SEND_WAIT;
2273 return (wd);
2407 caddr_t wd;
2410 ret = rib_send_and_wait(conn, cl, msgid, 1, 1, &wd);