diff options
| -rw-r--r-- | src/core/protocol.h | 1 | ||||
| -rw-r--r-- | src/protocol/pipeline0/pull.c | 13 | ||||
| -rw-r--r-- | src/protocol/pipeline0/push.c | 15 | ||||
| -rw-r--r-- | src/protocol/pubsub0/pub.c | 2 | ||||
| -rw-r--r-- | src/protocol/pubsub0/sub.c | 2 | ||||
| -rw-r--r-- | src/protocol/reqrep0/rep.c | 2 | ||||
| -rw-r--r-- | src/protocol/reqrep0/req.c | 2 | ||||
| -rw-r--r-- | src/protocol/survey0/respond.c | 2 | ||||
| -rw-r--r-- | src/protocol/survey0/survey.c | 2 |
9 files changed, 19 insertions, 22 deletions
diff --git a/src/core/protocol.h b/src/core/protocol.h index 77ccdb08..91611e9a 100644 --- a/src/core/protocol.h +++ b/src/core/protocol.h @@ -166,7 +166,6 @@ struct nni_proto { #define NNI_PROTO_FLAG_SND 2u // Protocol can send #define NNI_PROTO_FLAG_SNDRCV 3u // Protocol can both send & recv #define NNI_PROTO_FLAG_RAW 4u // Protocol is raw -#define NNI_PROTO_FLAG_NOMSGQ 8u // Protocol bypasses the upper queues // nni_proto_open is called by the protocol to create a socket instance // with its ops vector. The intent is that applications will only see diff --git a/src/protocol/pipeline0/pull.c b/src/protocol/pipeline0/pull.c index 94403431..616b0817 100644 --- a/src/protocol/pipeline0/pull.c +++ b/src/protocol/pipeline0/pull.c @@ -186,7 +186,7 @@ static void pull0_sock_close(void *arg) { pull0_sock *s = arg; - nni_aio *a; + nni_aio * a; nni_mtx_lock(&s->m); while ((a = nni_list_first(&s->rq)) != NULL) { nni_aio_list_remove(a); @@ -298,17 +298,16 @@ static nni_proto pull0_proto = { .proto_version = NNI_PROTOCOL_VERSION, .proto_self = { NNI_PROTO_PULL_V0, "pull" }, .proto_peer = { NNI_PROTO_PUSH_V0, "push" }, - .proto_flags = NNI_PROTO_FLAG_RCV | NNI_PROTO_FLAG_NOMSGQ, + .proto_flags = NNI_PROTO_FLAG_RCV, .proto_pipe_ops = &pull0_pipe_ops, .proto_sock_ops = &pull0_sock_ops, }; static nni_proto pull0_proto_raw = { - .proto_version = NNI_PROTOCOL_VERSION, - .proto_self = { NNI_PROTO_PULL_V0, "pull" }, - .proto_peer = { NNI_PROTO_PUSH_V0, "push" }, - .proto_flags = - NNI_PROTO_FLAG_RCV | NNI_PROTO_FLAG_RAW | NNI_PROTO_FLAG_NOMSGQ, + .proto_version = NNI_PROTOCOL_VERSION, + .proto_self = { NNI_PROTO_PULL_V0, "pull" }, + .proto_peer = { NNI_PROTO_PUSH_V0, "push" }, + .proto_flags = NNI_PROTO_FLAG_RCV | NNI_PROTO_FLAG_RAW, .proto_pipe_ops = &pull0_pipe_ops, .proto_sock_ops = &pull0_sock_ops, }; diff --git a/src/protocol/pipeline0/push.c b/src/protocol/pipeline0/push.c index 8aa5311c..ad43d967 100644 --- a/src/protocol/pipeline0/push.c +++ b/src/protocol/pipeline0/push.c @@ -353,7 +353,7 @@ static int push0_get_send_buf_len(void *arg, void *buf, size_t *szp, nni_opt_type t) { push0_sock *s = arg; - int val; + int val; nni_mtx_lock(&s->m); val = nni_lmq_cap(&s->wq); @@ -394,7 +394,7 @@ static nni_option push0_sock_options[] = { .o_get = push0_get_send_buf_len, .o_set = push0_set_send_buf_len, }, - // terminate list + // terminate list { .o_name = NULL, }, @@ -415,17 +415,16 @@ static nni_proto push0_proto = { .proto_version = NNI_PROTOCOL_VERSION, .proto_self = { NNI_PROTO_PUSH_V0, "push" }, .proto_peer = { NNI_PROTO_PULL_V0, "pull" }, - .proto_flags = NNI_PROTO_FLAG_SND | NNI_PROTO_FLAG_NOMSGQ, + .proto_flags = NNI_PROTO_FLAG_SND, .proto_pipe_ops = &push0_pipe_ops, .proto_sock_ops = &push0_sock_ops, }; static nni_proto push0_proto_raw = { - .proto_version = NNI_PROTOCOL_VERSION, - .proto_self = { NNI_PROTO_PUSH_V0, "push" }, - .proto_peer = { NNI_PROTO_PULL_V0, "pull" }, - .proto_flags = - NNI_PROTO_FLAG_SND | NNI_PROTO_FLAG_RAW | NNI_PROTO_FLAG_NOMSGQ, + .proto_version = NNI_PROTOCOL_VERSION, + .proto_self = { NNI_PROTO_PUSH_V0, "push" }, + .proto_peer = { NNI_PROTO_PULL_V0, "pull" }, + .proto_flags = NNI_PROTO_FLAG_SND | NNI_PROTO_FLAG_RAW, .proto_pipe_ops = &push0_pipe_ops, .proto_sock_ops = &push0_sock_ops, }; diff --git a/src/protocol/pubsub0/pub.c b/src/protocol/pubsub0/pub.c index 2bd723cc..e3d4f16a 100644 --- a/src/protocol/pubsub0/pub.c +++ b/src/protocol/pubsub0/pub.c @@ -356,7 +356,7 @@ static nni_proto pub0_proto = { .proto_version = NNI_PROTOCOL_VERSION, .proto_self = { NNI_PROTO_PUB_V0, "pub" }, .proto_peer = { NNI_PROTO_SUB_V0, "sub" }, - .proto_flags = NNI_PROTO_FLAG_SND | NNI_PROTO_FLAG_NOMSGQ, + .proto_flags = NNI_PROTO_FLAG_SND, .proto_sock_ops = &pub0_sock_ops, .proto_pipe_ops = &pub0_pipe_ops, }; diff --git a/src/protocol/pubsub0/sub.c b/src/protocol/pubsub0/sub.c index c56c8b79..9f3f2283 100644 --- a/src/protocol/pubsub0/sub.c +++ b/src/protocol/pubsub0/sub.c @@ -742,7 +742,7 @@ static nni_proto sub0_proto = { .proto_version = NNI_PROTOCOL_VERSION, .proto_self = { NNI_PROTO_SUB_V0, "sub" }, .proto_peer = { NNI_PROTO_PUB_V0, "pub" }, - .proto_flags = NNI_PROTO_FLAG_RCV | NNI_PROTO_FLAG_NOMSGQ, + .proto_flags = NNI_PROTO_FLAG_RCV, .proto_sock_ops = &sub0_sock_ops, .proto_pipe_ops = &sub0_pipe_ops, .proto_ctx_ops = &sub0_ctx_ops, diff --git a/src/protocol/reqrep0/rep.c b/src/protocol/reqrep0/rep.c index 2f10d3d6..aa32d249 100644 --- a/src/protocol/reqrep0/rep.c +++ b/src/protocol/reqrep0/rep.c @@ -692,7 +692,7 @@ static nni_proto rep0_proto = { .proto_version = NNI_PROTOCOL_VERSION, .proto_self = { NNG_REP0_SELF, NNG_REP0_SELF_NAME }, .proto_peer = { NNG_REP0_PEER, NNG_REP0_PEER_NAME }, - .proto_flags = NNI_PROTO_FLAG_SNDRCV | NNI_PROTO_FLAG_NOMSGQ, + .proto_flags = NNI_PROTO_FLAG_SNDRCV, .proto_sock_ops = &rep0_sock_ops, .proto_pipe_ops = &rep0_pipe_ops, .proto_ctx_ops = &rep0_ctx_ops, diff --git a/src/protocol/reqrep0/req.c b/src/protocol/reqrep0/req.c index fc12cb89..cb3c9395 100644 --- a/src/protocol/reqrep0/req.c +++ b/src/protocol/reqrep0/req.c @@ -856,7 +856,7 @@ static nni_proto req0_proto = { .proto_version = NNI_PROTOCOL_VERSION, .proto_self = { NNG_REQ0_SELF, NNG_REQ0_SELF_NAME }, .proto_peer = { NNG_REQ0_PEER, NNG_REQ0_PEER_NAME }, - .proto_flags = NNI_PROTO_FLAG_SNDRCV | NNI_PROTO_FLAG_NOMSGQ, + .proto_flags = NNI_PROTO_FLAG_SNDRCV, .proto_sock_ops = &req0_sock_ops, .proto_pipe_ops = &req0_pipe_ops, .proto_ctx_ops = &req0_ctx_ops, diff --git a/src/protocol/survey0/respond.c b/src/protocol/survey0/respond.c index 993e3243..ad551c8f 100644 --- a/src/protocol/survey0/respond.c +++ b/src/protocol/survey0/respond.c @@ -680,7 +680,7 @@ static nni_proto resp0_proto = { .proto_version = NNI_PROTOCOL_VERSION, .proto_self = { NNI_PROTO_RESPONDENT_V0, "respondent" }, .proto_peer = { NNI_PROTO_SURVEYOR_V0, "surveyor" }, - .proto_flags = NNI_PROTO_FLAG_SNDRCV | NNI_PROTO_FLAG_NOMSGQ, + .proto_flags = NNI_PROTO_FLAG_SNDRCV, .proto_sock_ops = &resp0_sock_ops, .proto_pipe_ops = &resp0_pipe_ops, .proto_ctx_ops = &resp0_ctx_ops, diff --git a/src/protocol/survey0/survey.c b/src/protocol/survey0/survey.c index f2cc8aa8..ce1ed601 100644 --- a/src/protocol/survey0/survey.c +++ b/src/protocol/survey0/survey.c @@ -650,7 +650,7 @@ static nni_proto surv0_proto = { .proto_version = NNI_PROTOCOL_VERSION, .proto_self = { NNG_SURVEYOR0_SELF, NNG_SURVEYOR0_SELF_NAME }, .proto_peer = { NNG_SURVEYOR0_PEER, NNG_SURVEYOR0_PEER_NAME }, - .proto_flags = NNI_PROTO_FLAG_SNDRCV | NNI_PROTO_FLAG_NOMSGQ, + .proto_flags = NNI_PROTO_FLAG_SNDRCV, .proto_sock_ops = &surv0_sock_ops, .proto_pipe_ops = &surv0_pipe_ops, .proto_ctx_ops = &surv0_ctx_ops, |
