Sophie

Sophie

distrib > Scientific%20Linux > 5x > x86_64 > by-pkgid > 89877e42827f16fa5f86b1df0c2860b1 > files > 2203

kernel-2.6.18-128.1.10.el5.src.rpm

From: Marcus Barrow <mbarrow@redhat.com>
Date: Wed, 19 Dec 2007 21:55:42 -0500
Subject: [scsi] qla2xxx: fix for infinite-login-retry
Message-id: 20071220025541.8999.50068.sendpatchset@shell.boston.redhat.com
O-Subject: [Bug 426327][QLogic][RHEL 5.2 Patch]qla2xxx: regression fix for infinite-login-retry fix
Bugzilla: 426327

BZ 426327  qla2xxx: regression fix for infinite-login-retry fix

The infinite login retry fix introduced a bug where
the HBA's loop id was cleared when the login was successful.

This patch makes sure that the loop id is only cleared
when the login fails.

This patch is queued for upstream and tested at QLogic.

Nacked-by: Prarit Bhargava <prarit@redhat.com>

diff --git a/drivers/scsi/qla2xxx/qla_os.c b/drivers/scsi/qla2xxx/qla_os.c
index 157177c..ed5a90d 100644
--- a/drivers/scsi/qla2xxx/qla_os.c
+++ b/drivers/scsi/qla2xxx/qla_os.c
@@ -2527,7 +2527,7 @@ qla2x00_do_dpc(void *data)
 					} else {
 						fcport->login_retry = 0;
 					}
-					if (fcport->login_retry == 0)
+					if (fcport->login_retry == 0 && status != QLA_SUCCESS)
 						fcport->loop_id = FC_NO_LOOP_ID;
 				}
 				if (test_bit(LOOP_RESYNC_NEEDED, &ha->dpc_flags))