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 8338587a5..d89a68928 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;
@@ -1567,7 +1567,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 0b61a2a60..2e38c009d 100644
--- a/transport/ib-verbs/src/ib-verbs.h
+++ b/transport/ib-verbs/src/ib-verbs.h
@@ -209,6 +209,7 @@ struct _ib_verbs_private {
char handshake_ret;
pthread_mutex_t recv_mutex;
+ pthread_cond_t recv_cond;
/* used during ib_verbs_handshake */
struct {