From 41188cf5a60a24bf54df5be70142f0928f413788 Mon Sep 17 00:00:00 2001 From: Jing Huang Date: Thu, 8 Jul 2010 19:52:00 -0700 Subject: [SCSI] bfa: fix prli retry issues Add a max retry limit for PRLI retries. Max retry limit (5) is same as used in rport PLOGI. Once the retries are exhausted, invoke rport offline so that existing logic of rport re-discovery can kick-in. Also fixed a bug in rport.c where one less retry was happening. Signed-off-by: Jing Huang Signed-off-by: James Bottomley --- drivers/scsi/bfa/rport.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'drivers/scsi/bfa/rport.c') diff --git a/drivers/scsi/bfa/rport.c b/drivers/scsi/bfa/rport.c index 2796403222e1..4e1fff21a5bc 100644 --- a/drivers/scsi/bfa/rport.c +++ b/drivers/scsi/bfa/rport.c @@ -36,8 +36,6 @@ BFA_TRC_FILE(FCS, RPORT); -#define BFA_FCS_RPORT_MAX_RETRIES (5) - /* In millisecs */ static u32 bfa_fcs_rport_del_timeout = BFA_FCS_RPORT_DEF_DEL_TIMEOUT * 1000; @@ -356,8 +354,8 @@ bfa_fcs_rport_sm_plogi_retry(struct bfa_fcs_rport_s *rport, */ case RPSM_EVENT_TIMEOUT: - rport->plogi_retries++; if (rport->plogi_retries < BFA_FCS_RPORT_MAX_RETRIES) { + rport->plogi_retries++; bfa_sm_set_state(rport, bfa_fcs_rport_sm_plogi_sending); bfa_fcs_rport_send_plogi(rport, NULL); } else { -- cgit