summaryrefslogtreecommitdiff
path: root/lib9p/srv.c
diff options
context:
space:
mode:
authorLuke T. Shumaker <lukeshu@lukeshu.com>2025-04-15 01:48:01 -0600
committerLuke T. Shumaker <lukeshu@lukeshu.com>2025-04-15 07:30:39 -0600
commit4c7c8889d304251553fcf02a35b2065814b04d92 (patch)
treedf3ad8fb69493e924121a854a7d959d970166221 /lib9p/srv.c
parent0aa6b262aeeea7ba24a75e3a89c9c767f35f05a6 (diff)
libcr_ipc: Have generic cr_rpc_* funcs instead of chan-specific funcs
Diffstat (limited to 'lib9p/srv.c')
-rw-r--r--lib9p/srv.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/lib9p/srv.c b/lib9p/srv.c
index d3748b7..dae73ea 100644
--- a/lib9p/srv.c
+++ b/lib9p/srv.c
@@ -443,7 +443,7 @@ void lib9p_srv_accept_and_read_loop(struct lib9p_srv *srv, lo_interface net_stre
srv->readers--;
if (srv->readers == 0)
while (srv->writers > 0)
- _lib9p_srv_reqch_send_req(&srv->_reqch, NULL);
+ cr_rpc_send_req(&srv->_reqch, NULL);
return;
}
lib9p_srv_read(srv, conn);
@@ -514,7 +514,7 @@ void lib9p_srv_read(struct lib9p_srv *srv, lo_interface net_stream_conn _conn) {
handle_message(&req);
else
/* ...but usually in another coroutine. */
- _lib9p_srv_reqch_send_req(&srv->_reqch, &req);
+ cr_rpc_send_req(&srv->_reqch, &req);
}
if (map_len(&sess.reqs) == 0)
io_close(conn.fd);
@@ -560,10 +560,10 @@ void lib9p_srv_worker_loop(struct lib9p_srv *srv) {
for (;;) {
/* Receive the request from the reader coroutine. ************/
- rpc_handle = _lib9p_srv_reqch_recv_req(&srv->_reqch);
+ rpc_handle = cr_rpc_recv_req(&srv->_reqch);
if (!rpc_handle.req) {
srv->writers--;
- _lib9p_srv_reqch_send_resp(rpc_handle, 0);
+ cr_rpc_send_resp(rpc_handle, 0);
return;
}
/* Copy the request from the reader coroutine's
@@ -574,7 +574,7 @@ void lib9p_srv_worker_loop(struct lib9p_srv *srv) {
assert(reqpp && *reqpp == &req);
/* Notify the reader coroutine that we're done with
* its data. */
- _lib9p_srv_reqch_send_resp(rpc_handle, 0);
+ cr_rpc_send_resp(rpc_handle, 0);
/* Process the request. **************************************/
handle_message(&req);