Lines Matching refs:sess
41 conn->sess->sess_ops->MaxBurstLength) { in iscsit_create_conn_recovery_datain_values()
48 (conn->sess->sess_ops->MaxBurstLength - in iscsit_create_conn_recovery_datain_values()
66 if ((write_data_done + conn->sess->sess_ops->MaxBurstLength) <= in iscsit_create_conn_recovery_dataout_values()
68 write_data_done += conn->sess->sess_ops->MaxBurstLength; in iscsit_create_conn_recovery_dataout_values()
77 struct iscsit_session *sess, in iscsit_attach_active_connection_recovery_entry() argument
80 spin_lock(&sess->cr_a_lock); in iscsit_attach_active_connection_recovery_entry()
81 list_add_tail(&cr->cr_list, &sess->cr_active_list); in iscsit_attach_active_connection_recovery_entry()
82 spin_unlock(&sess->cr_a_lock); in iscsit_attach_active_connection_recovery_entry()
88 struct iscsit_session *sess, in iscsit_attach_inactive_connection_recovery_entry() argument
91 spin_lock(&sess->cr_i_lock); in iscsit_attach_inactive_connection_recovery_entry()
92 list_add_tail(&cr->cr_list, &sess->cr_inactive_list); in iscsit_attach_inactive_connection_recovery_entry()
94 sess->conn_recovery_count++; in iscsit_attach_inactive_connection_recovery_entry()
96 " SID: %u\n", sess->conn_recovery_count, sess->sid); in iscsit_attach_inactive_connection_recovery_entry()
97 spin_unlock(&sess->cr_i_lock); in iscsit_attach_inactive_connection_recovery_entry()
103 struct iscsit_session *sess, in iscsit_get_inactive_connection_recovery_entry() argument
108 spin_lock(&sess->cr_i_lock); in iscsit_get_inactive_connection_recovery_entry()
109 list_for_each_entry(cr, &sess->cr_inactive_list, cr_list) { in iscsit_get_inactive_connection_recovery_entry()
111 spin_unlock(&sess->cr_i_lock); in iscsit_get_inactive_connection_recovery_entry()
115 spin_unlock(&sess->cr_i_lock); in iscsit_get_inactive_connection_recovery_entry()
120 void iscsit_free_connection_recovery_entries(struct iscsit_session *sess) in iscsit_free_connection_recovery_entries() argument
125 spin_lock(&sess->cr_a_lock); in iscsit_free_connection_recovery_entries()
126 list_for_each_entry_safe(cr, cr_tmp, &sess->cr_active_list, cr_list) { in iscsit_free_connection_recovery_entries()
128 spin_unlock(&sess->cr_a_lock); in iscsit_free_connection_recovery_entries()
141 spin_lock(&sess->cr_a_lock); in iscsit_free_connection_recovery_entries()
145 spin_unlock(&sess->cr_a_lock); in iscsit_free_connection_recovery_entries()
147 spin_lock(&sess->cr_i_lock); in iscsit_free_connection_recovery_entries()
148 list_for_each_entry_safe(cr, cr_tmp, &sess->cr_inactive_list, cr_list) { in iscsit_free_connection_recovery_entries()
150 spin_unlock(&sess->cr_i_lock); in iscsit_free_connection_recovery_entries()
163 spin_lock(&sess->cr_i_lock); in iscsit_free_connection_recovery_entries()
167 spin_unlock(&sess->cr_i_lock); in iscsit_free_connection_recovery_entries()
172 struct iscsit_session *sess) in iscsit_remove_active_connection_recovery_entry() argument
174 spin_lock(&sess->cr_a_lock); in iscsit_remove_active_connection_recovery_entry()
177 sess->conn_recovery_count--; in iscsit_remove_active_connection_recovery_entry()
179 " SID: %u\n", sess->conn_recovery_count, sess->sid); in iscsit_remove_active_connection_recovery_entry()
180 spin_unlock(&sess->cr_a_lock); in iscsit_remove_active_connection_recovery_entry()
189 struct iscsit_session *sess) in iscsit_remove_inactive_connection_recovery_entry() argument
191 spin_lock(&sess->cr_i_lock); in iscsit_remove_inactive_connection_recovery_entry()
193 spin_unlock(&sess->cr_i_lock); in iscsit_remove_inactive_connection_recovery_entry()
201 struct iscsit_session *sess) in iscsit_remove_cmd_from_connection_recovery() argument
222 struct iscsit_session *sess = cr->sess; in iscsit_discard_cr_cmds_by_expstatsn() local
239 iscsit_remove_cmd_from_connection_recovery(cmd, sess); in iscsit_discard_cr_cmds_by_expstatsn()
254 cr->cid, sess->sid); in iscsit_discard_cr_cmds_by_expstatsn()
255 iscsit_remove_inactive_connection_recovery_entry(cr, sess); in iscsit_discard_cr_cmds_by_expstatsn()
256 iscsit_attach_active_connection_recovery_entry(sess, cr); in iscsit_discard_cr_cmds_by_expstatsn()
258 " %hu on SID: %u\n", cr->cid, sess->sid); in iscsit_discard_cr_cmds_by_expstatsn()
259 iscsit_remove_active_connection_recovery_entry(cr, sess); in iscsit_discard_cr_cmds_by_expstatsn()
261 iscsit_remove_inactive_connection_recovery_entry(cr, sess); in iscsit_discard_cr_cmds_by_expstatsn()
262 iscsit_attach_active_connection_recovery_entry(sess, cr); in iscsit_discard_cr_cmds_by_expstatsn()
271 struct iscsit_session *sess = conn->sess; in iscsit_discard_unacknowledged_ooo_cmdsns_for_conn() local
273 mutex_lock(&sess->cmdsn_mutex); in iscsit_discard_unacknowledged_ooo_cmdsns_for_conn()
275 &sess->sess_ooo_cmdsn_list, ooo_list) { in iscsit_discard_unacknowledged_ooo_cmdsns_for_conn()
284 iscsit_remove_ooo_cmdsn(sess, ooo_cmdsn); in iscsit_discard_unacknowledged_ooo_cmdsns_for_conn()
286 mutex_unlock(&sess->cmdsn_mutex); in iscsit_discard_unacknowledged_ooo_cmdsns_for_conn()
303 sess->exp_cmd_sn); in iscsit_discard_unacknowledged_ooo_cmdsns_for_conn()
366 iscsi_sna_gte(cmd->cmd_sn, conn->sess->exp_cmd_sn)) { in iscsit_prepare_cmds_for_reallegiance()
387 cmd->sess = conn->sess; in iscsit_prepare_cmds_for_reallegiance()
414 cr->sess = conn->sess; in iscsit_prepare_cmds_for_reallegiance()
416 iscsit_attach_inactive_connection_recovery_entry(conn->sess, cr); in iscsit_prepare_cmds_for_reallegiance()