Lines Matching refs:crq

70     vscsi_crq               crq;  member
188 rc = spapr_vio_dma_write(&s->vdev, req->crq.s.IU_data_ptr, in vscsi_send_iu()
194 req->crq.s.valid = 0x80; in vscsi_send_iu()
195 req->crq.s.format = format; in vscsi_send_iu()
196 req->crq.s.reserved = 0x00; in vscsi_send_iu()
197 req->crq.s.timeout = cpu_to_be16(0x0000); in vscsi_send_iu()
198 req->crq.s.IU_length = cpu_to_be16(length); in vscsi_send_iu()
199 req->crq.s.IU_data_ptr = req_iu(req)->srp.rsp.tag; /* right byte order */ in vscsi_send_iu()
202 req->crq.s.status = VIOSRP_OK; in vscsi_send_iu()
204 req->crq.s.status = VIOSRP_ADAPTER_FAIL; in vscsi_send_iu()
207 rc1 = spapr_vio_send_crq(&s->vdev, req->crq.raw); in vscsi_send_iu()
609 VMSTATE_BUFFER(crq.raw, vscsi_req),
1087 static void vscsi_got_payload(VSCSIState *s, vscsi_crq *crq) in vscsi_got_payload() argument
1103 if (crq->s.IU_length > SRP_MAX_IU_LEN) { in vscsi_got_payload()
1105 crq->s.IU_length); in vscsi_got_payload()
1111 if (spapr_vio_dma_read(&s->vdev, crq->s.IU_data_ptr, &req->viosrp_iu_buf, in vscsi_got_payload()
1112 crq->s.IU_length)) { in vscsi_got_payload()
1117 memcpy(&req->crq, crq, sizeof(vscsi_crq)); in vscsi_got_payload()
1119 if (crq->s.format == VIOSRP_MAD_FORMAT) { in vscsi_got_payload()
1134 vscsi_crq crq; in vscsi_do_crq() local
1136 memcpy(crq.raw, crq_data, 16); in vscsi_do_crq()
1137 crq.s.timeout = be16_to_cpu(crq.s.timeout); in vscsi_do_crq()
1138 crq.s.IU_length = be16_to_cpu(crq.s.IU_length); in vscsi_do_crq()
1139 crq.s.IU_data_ptr = be64_to_cpu(crq.s.IU_data_ptr); in vscsi_do_crq()
1141 trace_spapr_vscsi_do_crq(crq.raw[0], crq.raw[1]); in vscsi_do_crq()
1143 switch (crq.s.valid) { in vscsi_do_crq()
1147 if (crq.s.format == 0x01) { in vscsi_do_crq()
1148 memset(crq.raw, 0, 16); in vscsi_do_crq()
1149 crq.s.valid = 0xc0; in vscsi_do_crq()
1150 crq.s.format = 0x02; in vscsi_do_crq()
1151 spapr_vio_send_crq(dev, crq.raw); in vscsi_do_crq()
1165 switch (crq.s.format) { in vscsi_do_crq()
1168 vscsi_got_payload(s, &crq); in vscsi_do_crq()
1175 crq.s.format); in vscsi_do_crq()
1179 crq.s.format); in vscsi_do_crq()
1184 crq.raw[0], crq.raw[1]); in vscsi_do_crq()
1218 dev->crq.SendFunc = vscsi_do_crq; in spapr_vscsi_realize()