On 02/17/2010 07:47 PM, Jayamohan Kallickal wrote:
@@ -2449,7 +2449,6 @@ int iscsi_eh_target_reset(struct scsi_cmnd *sc) break; case TMF_TIMEDOUT: spin_unlock_bh(&session->lock); - iscsi_conn_failure(conn, ISCSI_ERR_CONN_FAILED);
It is harmless to keep this, right? Just keep it for now so the reset handler code behaves the same for all TMF_TIMEDOUT cases.
goto done; default: conn->tmf_state = TMF_INITIAL; @@ -2476,12 +2475,27 @@ done: ISCSI_DBG_EH(session, "tgt %s reset result = %s\n", session->targetname, rc == SUCCESS ? "SUCCESS" : "FAILED"); mutex_unlock(&session->eh_mutex); + return rc; +} +EXPORT_SYMBOL_GPL(iscsi_eh_target_reset); +
You can remove the export symbol since no one is using it now, and remove the libiscsi.h iscsi_eh_target_reset code too.
+/** + * iscsi_eh_recover_target - reset target and possibly the session + * @sc: scsi command + * + * This will attempt to send a warm target reset. If that fails, + * we will escalate to ERL0 session recovery. + */ +int iscsi_eh_recover_target(struct scsi_cmnd *sc) +{ + int rc; + rc = iscsi_eh_target_reset(sc);
Some extra whitespace at the end of that line. You can do a git am --wihtespace=fix on your patches before you send and that will fix them up for you (just remember to respit the new ones out and send them).
-- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html