scsi: qla2xxx: Remove unintended flag clearing
authorQuinn Tran <qutran@marvell.com>
Mon, 19 Dec 2022 11:07:44 +0000 (03:07 -0800)
committerMartin K. Petersen <martin.petersen@oracle.com>
Thu, 12 Jan 2023 02:28:38 +0000 (21:28 -0500)
FCF_ASYNC_SENT flag is used in session management. This flag is cleared in
task management path by accident.  Remove unintended flag clearing.

Fixes: 388a49959ee4 ("scsi: qla2xxx: Fix panic from use after free in qla2x00_async_tm_cmd")
Cc: stable@vger.kernel.org
Signed-off-by: Quinn Tran <qutran@marvell.com>
Signed-off-by: Nilesh Javali <njavali@marvell.com>
Reviewed-by: Himanshu Madhani <himanshu.madhani@oracle.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/qla2xxx/qla_init.c

index 745fee2..6968e8d 100644 (file)
@@ -2082,7 +2082,6 @@ qla2x00_async_tm_cmd(fc_port_t *fcport, uint32_t flags, uint32_t lun,
 done_free_sp:
        /* ref: INIT */
        kref_put(&sp->cmd_kref, qla2x00_sp_release);
-       fcport->flags &= ~FCF_ASYNC_SENT;
 done:
        return rval;
 }