Lines Matching refs:srp_rsp
1366 struct srp_rsp *srp_rsp; in srpt_build_cmd_rsp() local
1377 srp_rsp = ioctx->ioctx.buf; in srpt_build_cmd_rsp()
1378 BUG_ON(!srp_rsp); in srpt_build_cmd_rsp()
1384 memset(srp_rsp, 0, sizeof(*srp_rsp)); in srpt_build_cmd_rsp()
1385 srp_rsp->opcode = SRP_RSP; in srpt_build_cmd_rsp()
1386 srp_rsp->req_lim_delta = in srpt_build_cmd_rsp()
1388 srp_rsp->tag = tag; in srpt_build_cmd_rsp()
1389 srp_rsp->status = status; in srpt_build_cmd_rsp()
1394 srp_rsp->flags = SRP_RSP_FLAG_DOUNDER; in srpt_build_cmd_rsp()
1395 srp_rsp->data_out_res_cnt = cpu_to_be32(resid); in srpt_build_cmd_rsp()
1398 srp_rsp->flags = SRP_RSP_FLAG_DIUNDER; in srpt_build_cmd_rsp()
1399 srp_rsp->data_in_res_cnt = cpu_to_be32(resid); in srpt_build_cmd_rsp()
1404 srp_rsp->flags = SRP_RSP_FLAG_DOOVER; in srpt_build_cmd_rsp()
1405 srp_rsp->data_out_res_cnt = cpu_to_be32(resid); in srpt_build_cmd_rsp()
1408 srp_rsp->flags = SRP_RSP_FLAG_DIOVER; in srpt_build_cmd_rsp()
1409 srp_rsp->data_in_res_cnt = cpu_to_be32(resid); in srpt_build_cmd_rsp()
1414 BUILD_BUG_ON(MIN_MAX_RSP_SIZE <= sizeof(*srp_rsp)); in srpt_build_cmd_rsp()
1415 max_sense_len = ch->max_ti_iu_len - sizeof(*srp_rsp); in srpt_build_cmd_rsp()
1422 srp_rsp->flags |= SRP_RSP_FLAG_SNSVALID; in srpt_build_cmd_rsp()
1423 srp_rsp->sense_data_len = cpu_to_be32(sense_data_len); in srpt_build_cmd_rsp()
1424 memcpy(srp_rsp->data, sense_data, sense_data_len); in srpt_build_cmd_rsp()
1427 return sizeof(*srp_rsp) + sense_data_len; in srpt_build_cmd_rsp()
1447 struct srp_rsp *srp_rsp; in srpt_build_tskmgmt_rsp() local
1452 resp_len = sizeof(*srp_rsp) + resp_data_len; in srpt_build_tskmgmt_rsp()
1454 srp_rsp = ioctx->ioctx.buf; in srpt_build_tskmgmt_rsp()
1455 BUG_ON(!srp_rsp); in srpt_build_tskmgmt_rsp()
1456 memset(srp_rsp, 0, sizeof(*srp_rsp)); in srpt_build_tskmgmt_rsp()
1458 srp_rsp->opcode = SRP_RSP; in srpt_build_tskmgmt_rsp()
1459 srp_rsp->req_lim_delta = in srpt_build_tskmgmt_rsp()
1461 srp_rsp->tag = tag; in srpt_build_tskmgmt_rsp()
1463 srp_rsp->flags |= SRP_RSP_FLAG_RSPVALID; in srpt_build_tskmgmt_rsp()
1464 srp_rsp->resp_data_len = cpu_to_be32(resp_data_len); in srpt_build_tskmgmt_rsp()
1465 srp_rsp->data[3] = rsp_code; in srpt_build_tskmgmt_rsp()