Lines Matching refs:descr
1427 static bool tcm_is_ws_enabled(struct target_opcode_descriptor *descr, in tcm_is_ws_enabled() argument
1455 static bool tcm_is_caw_enabled(struct target_opcode_descriptor *descr, in tcm_is_caw_enabled() argument
1496 static bool tcm_is_rep_ref_enabled(struct target_opcode_descriptor *descr, in tcm_is_rep_ref_enabled() argument
1542 static bool tcm_is_unmap_enabled(struct target_opcode_descriptor *descr, in tcm_is_unmap_enabled() argument
1665 static bool tcm_is_pr_enabled(struct target_opcode_descriptor *descr, in tcm_is_pr_enabled() argument
1676 switch (descr->opcode) { in tcm_is_pr_enabled()
1687 switch (descr->service_action) { in tcm_is_pr_enabled()
1699 if (descr->service_action == PRI_READ_FULL_STATUS) in tcm_is_pr_enabled()
1883 static bool tcm_is_3pc_enabled(struct target_opcode_descriptor *descr, in tcm_is_3pc_enabled() argument
1945 static bool spc_rsoc_enabled(struct target_opcode_descriptor *descr, in spc_rsoc_enabled() argument
1966 static bool tcm_is_set_tpg_enabled(struct target_opcode_descriptor *descr, in tcm_is_set_tpg_enabled() argument
2056 struct target_opcode_descriptor *descr) in spc_rsoc_encode_command_timeouts_descriptor() argument
2062 buf[3] = descr->specific_timeout; in spc_rsoc_encode_command_timeouts_descriptor()
2063 put_unaligned_be32(descr->nominal_timeout, &buf[4]); in spc_rsoc_encode_command_timeouts_descriptor()
2064 put_unaligned_be32(descr->recommended_timeout, &buf[8]); in spc_rsoc_encode_command_timeouts_descriptor()
2071 struct target_opcode_descriptor *descr) in spc_rsoc_encode_command_descriptor() argument
2075 buf[0] = descr->opcode; in spc_rsoc_encode_command_descriptor()
2077 put_unaligned_be16(descr->service_action, &buf[2]); in spc_rsoc_encode_command_descriptor()
2079 buf[5] = (ctdp << 1) | descr->serv_action_valid; in spc_rsoc_encode_command_descriptor()
2080 put_unaligned_be16(descr->cdb_size, &buf[6]); in spc_rsoc_encode_command_descriptor()
2083 descr); in spc_rsoc_encode_command_descriptor()
2090 struct target_opcode_descriptor *descr, in spc_rsoc_encode_one_command_descriptor() argument
2095 if (!descr) { in spc_rsoc_encode_one_command_descriptor()
2101 put_unaligned_be16(descr->cdb_size, &buf[2]); in spc_rsoc_encode_one_command_descriptor()
2102 memcpy(&buf[4], descr->usage_bits, descr->cdb_size); in spc_rsoc_encode_one_command_descriptor()
2103 if (descr->update_usage_bits) in spc_rsoc_encode_one_command_descriptor()
2104 descr->update_usage_bits(&buf[4], dev); in spc_rsoc_encode_one_command_descriptor()
2107 &buf[4 + descr->cdb_size], ctdp, descr); in spc_rsoc_encode_one_command_descriptor()
2109 return 4 + descr->cdb_size + td_size; in spc_rsoc_encode_one_command_descriptor()
2115 struct target_opcode_descriptor *descr; in spc_rsoc_get_descr() local
2137 descr = tcm_supported_opcodes[i]; in spc_rsoc_get_descr()
2138 if (descr->opcode != requested_opcode) in spc_rsoc_get_descr()
2151 if (descr->serv_action_valid) in spc_rsoc_get_descr()
2154 if (!descr->enabled || descr->enabled(descr, cmd)) in spc_rsoc_get_descr()
2155 *opcode = descr; in spc_rsoc_get_descr()
2166 if (descr->serv_action_valid && in spc_rsoc_get_descr()
2167 descr->service_action == requested_sa) { in spc_rsoc_get_descr()
2168 if (!descr->enabled || descr->enabled(descr, in spc_rsoc_get_descr()
2170 *opcode = descr; in spc_rsoc_get_descr()
2171 } else if (!descr->serv_action_valid) in spc_rsoc_get_descr()
2181 if (descr->service_action == requested_sa) in spc_rsoc_get_descr()
2182 if (!descr->enabled || descr->enabled(descr, in spc_rsoc_get_descr()
2184 *opcode = descr; in spc_rsoc_get_descr()
2196 struct target_opcode_descriptor *descr = NULL; in spc_emulate_report_supp_op_codes() local
2218 ret = spc_rsoc_get_descr(cmd, &descr); in spc_emulate_report_supp_op_codes()
2222 if (descr) in spc_emulate_report_supp_op_codes()
2223 response_length = 4 + descr->cdb_size + rctd * 12; in spc_emulate_report_supp_op_codes()
2239 descr = tcm_supported_opcodes[i]; in spc_emulate_report_supp_op_codes()
2240 if (descr->enabled && !descr->enabled(descr, cmd)) in spc_emulate_report_supp_op_codes()
2244 &buf[response_length], rctd, descr); in spc_emulate_report_supp_op_codes()
2249 &buf[response_length], rctd, descr, in spc_emulate_report_supp_op_codes()