diff mbox series

[03/15] qla4xxx: use iscsi_is_session_online

Message ID 1606858196-5421-4-git-send-email-michael.christie@oracle.com (mailing list archive)
State Changes Requested
Headers show
Series libiscsi: lock clean ups | expand

Commit Message

Mike Christie Dec. 1, 2020, 9:29 p.m. UTC
__qla4xxx_is_chap_active just wants to know if a session is online and
does not care about why it's not, so this has it use
iscsi_is_session_online.

This is not a bug now, but the next patch changes the behavior of
iscsi_session_chkready so this patch just prepares the driver for that
change.

Signed-off-by: Mike Christie <michael.christie@oracle.com>
---
 drivers/scsi/qla4xxx/ql4_os.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Lee Duncan Dec. 3, 2020, 9:07 p.m. UTC | #1
On 12/1/20 1:29 PM, Mike Christie wrote:
> __qla4xxx_is_chap_active just wants to know if a session is online and
> does not care about why it's not, so this has it use
> iscsi_is_session_online.
> 
> This is not a bug now, but the next patch changes the behavior of
> iscsi_session_chkready so this patch just prepares the driver for that
> change.
> 
> Signed-off-by: Mike Christie <michael.christie@oracle.com>
> ---
>  drivers/scsi/qla4xxx/ql4_os.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c
> index 2c23b69..6996942 100644
> --- a/drivers/scsi/qla4xxx/ql4_os.c
> +++ b/drivers/scsi/qla4xxx/ql4_os.c
> @@ -844,7 +844,7 @@ static int __qla4xxx_is_chap_active(struct device *dev, void *data)
>  	sess = cls_session->dd_data;
>  	ddb_entry = sess->dd_data;
>  
> -	if (iscsi_session_chkready(cls_session))
> +	if (iscsi_is_session_online(cls_session))
>  		goto exit_is_chap_active;
>  
>  	if (ddb_entry->chap_tbl_idx == *chap_tbl_idx)
> 

Reviewed-by: Lee Duncan <lduncan@suse.com>
diff mbox series

Patch

diff --git a/drivers/scsi/qla4xxx/ql4_os.c b/drivers/scsi/qla4xxx/ql4_os.c
index 2c23b69..6996942 100644
--- a/drivers/scsi/qla4xxx/ql4_os.c
+++ b/drivers/scsi/qla4xxx/ql4_os.c
@@ -844,7 +844,7 @@  static int __qla4xxx_is_chap_active(struct device *dev, void *data)
 	sess = cls_session->dd_data;
 	ddb_entry = sess->dd_data;
 
-	if (iscsi_session_chkready(cls_session))
+	if (iscsi_is_session_online(cls_session))
 		goto exit_is_chap_active;
 
 	if (ddb_entry->chap_tbl_idx == *chap_tbl_idx)