diff --git a/include/iscsi-private.h b/include/iscsi-private.h index 40a96e3..bbc0462 100644 --- a/include/iscsi-private.h +++ b/include/iscsi-private.h @@ -274,7 +274,6 @@ unsigned long crc32c(char *buf, int len); struct scsi_task *iscsi_scsi_get_task_from_pdu(struct iscsi_pdu *pdu); -int iscsi_reconnect(struct iscsi_context *iscsi); void iscsi_set_noautoreconnect(struct iscsi_context *iscsi, int state); #ifdef __cplusplus diff --git a/include/iscsi.h b/include/iscsi.h index 3aac789..ea00f31 100644 --- a/include/iscsi.h +++ b/include/iscsi.h @@ -332,6 +332,15 @@ EXTERN int iscsi_full_connect_sync(struct iscsi_context *iscsi, const char *port */ EXTERN int iscsi_disconnect(struct iscsi_context *iscsi); +/* + * Disconnect a connection to a target and try to reconnect. + * + * Returns: + * 0 reconnect was successful + * <0 error + */ +EXTERN int iscsi_reconnect(struct iscsi_context *iscsi); + /* * Asynchronous call to perform an ISCSI login. *