/illumos-gate/usr/src/uts/common/io/scsi/adapters/iscsi/ |
H A D | iscsi_cmd.c | 32 static void iscsi_cmd_state_free(iscsi_cmd_t *icmdp, 34 static void iscsi_cmd_state_pending(iscsi_cmd_t *icmdp, 36 static void iscsi_cmd_state_active(iscsi_cmd_t *icmdp, 38 static void iscsi_cmd_state_aborting(iscsi_cmd_t *icmdp, 40 static void iscsi_cmd_state_idm_aborting(iscsi_cmd_t *icmdp, 42 static void iscsi_cmd_state_completed(iscsi_cmd_t *icmdp, 51 #define ISCSI_CMD_ISSUE_CALLBACK(icmdp, status) \ argument 52 icmdp->cmd_completed = B_TRUE; \ 53 icmdp->cmd_result = status; \ 54 cv_broadcast(&icmdp->cmd_completion); [all …]
|
H A D | iscsi_queue.c | 32 iscsi_cmd_t *icmdp); 81 iscsi_enqueue_pending_cmd(iscsi_sess_t *isp, iscsi_cmd_t *icmdp) in iscsi_enqueue_pending_cmd() argument 84 ASSERT(icmdp != NULL); in iscsi_enqueue_pending_cmd() 87 icmdp->cmd_state = ISCSI_CMD_STATE_PENDING; in iscsi_enqueue_pending_cmd() 88 if (icmdp->cmd_type == ISCSI_CMD_TYPE_SCSI) { in iscsi_enqueue_pending_cmd() 90 &isp->sess_queue_pending.tail, icmdp); in iscsi_enqueue_pending_cmd() 95 &isp->sess_queue_pending.tail, icmdp); in iscsi_enqueue_pending_cmd() 107 iscsi_dequeue_pending_cmd(iscsi_sess_t *isp, iscsi_cmd_t *icmdp) in iscsi_dequeue_pending_cmd() argument 112 ASSERT(icmdp != NULL); in iscsi_dequeue_pending_cmd() 116 &isp->sess_queue_pending.tail, icmdp); in iscsi_dequeue_pending_cmd() [all …]
|
H A D | iscsi_io.c | 70 idm_conn_t *ic, iscsi_scsi_rsp_hdr_t *ihp, iscsi_cmd_t **icmdp); 72 iscsi_hdr_t *ihp, iscsi_cmd_t **icmdp); 76 static boolean_t iscsi_nop_timeout_checks(iscsi_cmd_t *icmdp); 100 static iscsi_status_t iscsi_tx_scsi(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 101 static iscsi_status_t iscsi_tx_nop(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 102 static iscsi_status_t iscsi_tx_abort(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 103 static iscsi_status_t iscsi_tx_reset(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 104 static iscsi_status_t iscsi_tx_logout(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 105 static iscsi_status_t iscsi_tx_text(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 115 static boolean_t iscsi_decode_sense(uint8_t *sense_data, iscsi_cmd_t *icmdp); [all …]
|
H A D | iscsi.h | 457 struct iscsi_cmd *icmdp; member 470 struct iscsi_cmd *icmdp; member 1235 iscsi_status_t iscsi_tx_cmd(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 1237 void iscsi_task_cleanup(int opcode, iscsi_cmd_t *icmdp); 1248 void iscsi_iodone(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 1258 void iscsi_enqueue_pending_cmd(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 1259 void iscsi_dequeue_pending_cmd(iscsi_sess_t *isp, iscsi_cmd_t *icmdp); 1260 void iscsi_enqueue_active_cmd(iscsi_conn_t *icp, iscsi_cmd_t *icmdp); 1261 void iscsi_dequeue_active_cmd(iscsi_conn_t *icp, iscsi_cmd_t *icmdp); 1262 void iscsi_enqueue_idm_aborting_cmd(iscsi_conn_t *icp, iscsi_cmd_t *icmdp); [all …]
|
H A D | iscsi.c | 821 iscsi_cmd_t *icmdp; in iscsi_tran_init_pkt() local 848 icmdp = (iscsi_cmd_t *)pkt->pkt_ha_private; in iscsi_tran_init_pkt() 849 icmdp->cmd_sig = ISCSI_SIG_CMD; in iscsi_tran_init_pkt() 850 icmdp->cmd_state = ISCSI_CMD_STATE_FREE; in iscsi_tran_init_pkt() 851 icmdp->cmd_lun = ilp; in iscsi_tran_init_pkt() 853 icmdp->cmd_type = ISCSI_CMD_TYPE_SCSI; in iscsi_tran_init_pkt() 855 icmdp->cmd_un.scsi.lun = ilp->lun_addr_type << 14; in iscsi_tran_init_pkt() 856 icmdp->cmd_un.scsi.lun = icmdp->cmd_un.scsi.lun | in iscsi_tran_init_pkt() 858 icmdp->cmd_un.scsi.pkt = pkt; in iscsi_tran_init_pkt() 859 icmdp->cmd_un.scsi.bp = bp; in iscsi_tran_init_pkt() [all …]
|
H A D | iscsi_sess.c | 906 iscsi_sess_reserve_scsi_itt(iscsi_cmd_t *icmdp) in iscsi_sess_reserve_scsi_itt() argument 909 iscsi_conn_t *icp = icmdp->cmd_conn; in iscsi_sess_reserve_scsi_itt() 913 itp->idt_private = icmdp; in iscsi_sess_reserve_scsi_itt() 914 icmdp->cmd_itp = itp; in iscsi_sess_reserve_scsi_itt() 915 icmdp->cmd_itt = itp->idt_tt; in iscsi_sess_reserve_scsi_itt() 923 iscsi_sess_release_scsi_itt(iscsi_cmd_t *icmdp) in iscsi_sess_release_scsi_itt() argument 925 idm_task_free(icmdp->cmd_itp); in iscsi_sess_release_scsi_itt() 932 iscsi_sess_reserve_itt(iscsi_sess_t *isp, iscsi_cmd_t *icmdp) in iscsi_sess_reserve_itt() argument 959 icmdp->cmd_itt = isp->sess_itt; in iscsi_sess_reserve_itt() 961 ISCSI_CMD_TABLE_SIZE] = icmdp; in iscsi_sess_reserve_itt() [all …]
|
H A D | iscsi_conn.c | 968 iscsi_cmd_t *icmdp; in iscsi_conn_flush_active_cmds() local 983 icmdp = icp->conn_queue_active.head; in iscsi_conn_flush_active_cmds() 984 while (icmdp != NULL) { in iscsi_conn_flush_active_cmds() 986 mutex_enter(&icmdp->cmd_mutex); in iscsi_conn_flush_active_cmds() 987 if (icmdp->cmd_type == ISCSI_CMD_TYPE_SCSI) { in iscsi_conn_flush_active_cmds() 988 icmdp->cmd_un.scsi.pkt_stat |= STAT_ABORTED; in iscsi_conn_flush_active_cmds() 990 mutex_exit(&icmdp->cmd_mutex); in iscsi_conn_flush_active_cmds() 992 iscsi_cmd_state_machine(icmdp, in iscsi_conn_flush_active_cmds() 994 icmdp = icp->conn_queue_active.head; in iscsi_conn_flush_active_cmds()
|
H A D | iscsi_lun.c | 285 iscsi_cmd_t *icmdp, *nicmdp; in iscsi_lun_cmd_cancel() local 290 for (icmdp = isp->sess_queue_pending.head; in iscsi_lun_cmd_cancel() 291 icmdp; icmdp = nicmdp) { in iscsi_lun_cmd_cancel() 292 nicmdp = icmdp->cmd_next; in iscsi_lun_cmd_cancel() 299 iscsi_cmd_state_machine(icmdp, ISCSI_CMD_EVENT_E4, isp); in iscsi_lun_cmd_cancel()
|
/illumos-gate/usr/src/cmd/mdb/common/modules/stmf/ |
H A D | stmf.c | 860 print_tasks(struct fct_i_cmd *icmdp, struct find_options *options, void *arg) in print_tasks() argument 866 (uintptr_t)icmdp) != sizeof (struct fct_i_cmd)) { in print_tasks() 906 print_tasks_on_rp(struct fct_i_cmd *icmdp, struct find_options *options, in print_tasks_on_rp() argument 914 (uintptr_t)icmdp) != sizeof (struct fct_i_cmd)) { in print_tasks_on_rp() 1081 struct fct_i_cmd *icmdp; in fct_icmds() local 1108 icmdp = iport.iport_cached_cmdlist; in fct_icmds() 1109 while (icmdp) { in fct_icmds() 1111 (uintptr_t)icmdp) == -1) { in fct_icmds() 1112 mdb_warn("failed to read fct_i_cmd at %p", icmdp); in fct_icmds() 1116 mdb_printf("%p\n", icmdp); in fct_icmds() [all …]
|