summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--transport/ib-verbs/src/ib-verbs.c10
-rw-r--r--transport/ib-verbs/src/ib-verbs.h1
2 files changed, 6 insertions, 5 deletions
diff --git a/transport/ib-verbs/src/ib-verbs.c b/transport/ib-verbs/src/ib-verbs.c
index 0ec8df8b8..1dd00f27c 100644
--- a/transport/ib-verbs/src/ib-verbs.c
+++ b/transport/ib-verbs/src/ib-verbs.c
@@ -497,7 +497,7 @@ ib_verbs_receive (transport_t *this, char **hdr_p, size_t *hdrlen_p,
priv->data_ptr = NULL;
data_len = priv->data_len;
- /* pthread_cond_broadcast (&priv->recv_cond); */
+ pthread_cond_broadcast (&priv->recv_cond);
}
pthread_mutex_unlock (&priv->recv_mutex);
@@ -1137,9 +1137,9 @@ ib_verbs_recv_completion_proc (void *data)
pthread_mutex_lock (&priv->recv_mutex);
{
-/* while (priv->data_ptr)
- pthread_cond_wait (&priv->recv_cond, &priv->recv_mutex);
-*/
+ while (priv->data_ptr)
+ pthread_cond_wait (&priv->recv_cond,
+ &priv->recv_mutex);
priv->data_ptr = post->buf;
priv->data_offset = 0;
@@ -1555,7 +1555,7 @@ ib_verbs_init (transport_t *this)
pthread_mutex_init (&priv->read_mutex, NULL);
pthread_mutex_init (&priv->write_mutex, NULL);
pthread_mutex_init (&priv->recv_mutex, NULL);
- /* pthread_cond_init (&priv->recv_cond, NULL); */
+ pthread_cond_init (&priv->recv_cond, NULL);
return 0;
}
diff --git a/transport/ib-verbs/src/ib-verbs.h b/transport/ib-verbs/src/ib-verbs.h
index 348c673fa..ea016c34d 100644
--- a/transport/ib-verbs/src/ib-verbs.h
+++ b/transport/ib-verbs/src/ib-verbs.h
@@ -202,6 +202,7 @@ struct _ib_verbs_private {
char handshake_ret;
pthread_mutex_t recv_mutex;
+ pthread_cond_t recv_cond;
/* used during ib_verbs_handshake */
struct {