提交 5beea19c 编写于 作者: A Arun Easi 提交者: Zheng Zengkai

scsi: qla2xxx: Fix losing FCP-2 targets during port perturbation tests

stable inclusion
from stable-v5.10.137
commit 1118020b3b7ab2fbc5806434866867b2ab357f4d
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I60PLB

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=1118020b3b7ab2fbc5806434866867b2ab357f4d

--------------------------------

commit 58d1c124 upstream.

When a mix of FCP-2 (tape) and non-FCP-2 targets are present, FCP-2 target
state was incorrectly transitioned when both of the targets were gone. Fix
this by ignoring state transition for FCP-2 targets.

Link: https://lore.kernel.org/r/20220616053508.27186-7-njavali@marvell.com
Fixes: 44c57f20 ("scsi: qla2xxx: Changes to support FCP2 Target")
Cc: stable@vger.kernel.org
Signed-off-by: NArun Easi <aeasi@marvell.com>
Signed-off-by: NNilesh Javali <njavali@marvell.com>
Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
Reviewed-by: NWei Li <liwei391@huawei.com>
上级 81c8640d
...@@ -3552,7 +3552,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp) ...@@ -3552,7 +3552,7 @@ void qla24xx_async_gnnft_done(scsi_qla_host_t *vha, srb_t *sp)
do_delete) { do_delete) {
if (fcport->loop_id != FC_NO_LOOP_ID) { if (fcport->loop_id != FC_NO_LOOP_ID) {
if (fcport->flags & FCF_FCP2_DEVICE) if (fcport->flags & FCF_FCP2_DEVICE)
fcport->logout_on_delete = 0; continue;
ql_dbg(ql_dbg_disc, vha, 0x20f0, ql_dbg(ql_dbg_disc, vha, 0x20f0,
"%s %d %8phC post del sess\n", "%s %d %8phC post del sess\n",
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册