Lines Matching refs:req_id
125 static inline int get_request(struct pvcalls_bedata *bedata, int *req_id) in get_request() argument
127 *req_id = bedata->ring.req_prod_pvt & (RING_SIZE(&bedata->ring) - 1); in get_request()
129 bedata->rsp[*req_id].req_id != PVCALLS_INVALID_ID) in get_request()
171 int req_id = 0, more = 0, done = 0; in pvcalls_front_event_handler() local
187 req_id = rsp->req_id; in pvcalls_front_event_handler()
203 dst = (uint8_t *)&bedata->rsp[req_id] + in pvcalls_front_event_handler()
204 sizeof(rsp->req_id); in pvcalls_front_event_handler()
205 src = (uint8_t *)rsp + sizeof(rsp->req_id); in pvcalls_front_event_handler()
206 memcpy(dst, src, sizeof(*rsp) - sizeof(rsp->req_id)); in pvcalls_front_event_handler()
212 bedata->rsp[req_id].req_id = req_id; in pvcalls_front_event_handler()
265 int notify, req_id, ret; in pvcalls_front_socket() local
292 ret = get_request(bedata, &req_id); in pvcalls_front_socket()
309 req = RING_GET_REQUEST(&bedata->ring, req_id); in pvcalls_front_socket()
310 req->req_id = req_id; in pvcalls_front_socket()
324 READ_ONCE(bedata->rsp[req_id].req_id) == req_id); in pvcalls_front_socket()
328 ret = bedata->rsp[req_id].ret; in pvcalls_front_socket()
329 bedata->rsp[req_id].req_id = PVCALLS_INVALID_ID; in pvcalls_front_socket()
418 int notify, req_id, ret; in pvcalls_front_connect() local
436 ret = get_request(bedata, &req_id); in pvcalls_front_connect()
451 req = RING_GET_REQUEST(&bedata->ring, req_id); in pvcalls_front_connect()
452 req->req_id = req_id; in pvcalls_front_connect()
471 READ_ONCE(bedata->rsp[req_id].req_id) == req_id); in pvcalls_front_connect()
475 ret = bedata->rsp[req_id].ret; in pvcalls_front_connect()
476 bedata->rsp[req_id].req_id = PVCALLS_INVALID_ID; in pvcalls_front_connect()
666 int notify, req_id, ret; in pvcalls_front_bind() local
677 ret = get_request(bedata, &req_id); in pvcalls_front_bind()
683 req = RING_GET_REQUEST(&bedata->ring, req_id); in pvcalls_front_bind()
684 req->req_id = req_id; in pvcalls_front_bind()
702 READ_ONCE(bedata->rsp[req_id].req_id) == req_id); in pvcalls_front_bind()
706 ret = bedata->rsp[req_id].ret; in pvcalls_front_bind()
707 bedata->rsp[req_id].req_id = PVCALLS_INVALID_ID; in pvcalls_front_bind()
719 int notify, req_id, ret; in pvcalls_front_listen() local
732 ret = get_request(bedata, &req_id); in pvcalls_front_listen()
738 req = RING_GET_REQUEST(&bedata->ring, req_id); in pvcalls_front_listen()
739 req->req_id = req_id; in pvcalls_front_listen()
751 READ_ONCE(bedata->rsp[req_id].req_id) == req_id); in pvcalls_front_listen()
755 ret = bedata->rsp[req_id].ret; in pvcalls_front_listen()
756 bedata->rsp[req_id].req_id = PVCALLS_INVALID_ID; in pvcalls_front_listen()
769 int notify, req_id, ret, nonblock; in pvcalls_front_accept() local
789 req_id = READ_ONCE(map->passive.inflight_req_id); in pvcalls_front_accept()
790 if (req_id != PVCALLS_INVALID_ID && in pvcalls_front_accept()
791 READ_ONCE(bedata->rsp[req_id].req_id) == req_id) { in pvcalls_front_accept()
823 ret = get_request(bedata, &req_id); in pvcalls_front_accept()
846 req = RING_GET_REQUEST(&bedata->ring, req_id); in pvcalls_front_accept()
847 req->req_id = req_id; in pvcalls_front_accept()
862 WRITE_ONCE(map->passive.inflight_req_id, req_id); in pvcalls_front_accept()
868 READ_ONCE(bedata->rsp[req_id].req_id) == req_id)) { in pvcalls_front_accept()
879 bedata->rsp[req_id].req_id = PVCALLS_INVALID_ID; in pvcalls_front_accept()
889 ret = bedata->rsp[req_id].ret; in pvcalls_front_accept()
890 bedata->rsp[req_id].req_id = PVCALLS_INVALID_ID; in pvcalls_front_accept()
905 int notify, req_id, ret; in pvcalls_front_poll_passive() local
910 uint32_t req_id = READ_ONCE(map->passive.inflight_req_id); in pvcalls_front_poll_passive() local
912 if (req_id != PVCALLS_INVALID_ID && in pvcalls_front_poll_passive()
913 READ_ONCE(bedata->rsp[req_id].req_id) == req_id) in pvcalls_front_poll_passive()
937 ret = get_request(bedata, &req_id); in pvcalls_front_poll_passive()
942 req = RING_GET_REQUEST(&bedata->ring, req_id); in pvcalls_front_poll_passive()
943 req->req_id = req_id; in pvcalls_front_poll_passive()
1004 int req_id, notify, ret; in pvcalls_front_release() local
1020 ret = get_request(bedata, &req_id); in pvcalls_front_release()
1028 req = RING_GET_REQUEST(&bedata->ring, req_id); in pvcalls_front_release()
1029 req->req_id = req_id; in pvcalls_front_release()
1040 READ_ONCE(bedata->rsp[req_id].req_id) == req_id); in pvcalls_front_release()
1077 WRITE_ONCE(bedata->rsp[req_id].req_id, PVCALLS_INVALID_ID); in pvcalls_front_release()
1178 bedata->rsp[i].req_id = PVCALLS_INVALID_ID; in pvcalls_front_probe()