aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/libfc/fc_lport.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-12-17 16:38:48 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2009-12-17 16:38:48 -0800
commitfc6f0700d5cd54b5f8b30c4f0d93b06a6ba04b81 (patch)
treeed0f6fa02690d08a2b9b57f8735d13f11fd1140f /drivers/scsi/libfc/fc_lport.c
parentdbfc985195410dad803c845743c63cd73bd1fe32 (diff)
parent53ca353594a254e6bd45ccf2d405aa31bcbb7091 (diff)
downloadkernel_samsung_smdk4412-fc6f0700d5cd54b5f8b30c4f0d93b06a6ba04b81.zip
kernel_samsung_smdk4412-fc6f0700d5cd54b5f8b30c4f0d93b06a6ba04b81.tar.gz
kernel_samsung_smdk4412-fc6f0700d5cd54b5f8b30c4f0d93b06a6ba04b81.tar.bz2
Merge git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi-misc-2.6: (40 commits) [SCSI] 3w-9xxx fix bug in sgl loading [SCSI] fcoe, libfc: adds enable/disable for fcoe interface [SCSI] libfc: reduce hold time on SCSI host lock [SCSI] libfc: remote port gets stuck in restart state without really restarting [SCSI] pm8001: misc code cleanup [SCSI] pm8001: enable read HBA SAS address from VPD [SCSI] pm8001: do not reset local sata as it will not be found if reset [SCSI] pm8001: bit set pm8001_ha->flags [SCSI] pm8001:fix potential NULL pointer dereference [SCSI] pm8001: set SSC down-spreading only to get less errors on some 6G device. [SCSI] pm8001: fix endian issues with SAS address [SCSI] pm8001: enhance error handle for IO patch [SCSI] pm8001: Fix for sata io circular lock dependency. [SCSI] hpsa: add driver for HP Smart Array controllers. [SCSI] cxgb3i: always use negative errno in case of error [SCSI] bnx2i: minor code cleanup and update driver version [SCSI] bnx2i: Task management ABORT TASK fixes [SCSI] bnx2i: update CQ arming algorith for 5771x chipsets [SCSI] bnx2i: Adjust sq_size module parametr to power of 2 only if a non-zero value is specified [SCSI] bnx2i: Add 5771E device support to bnx2i driver ...
Diffstat (limited to 'drivers/scsi/libfc/fc_lport.c')
-rw-r--r--drivers/scsi/libfc/fc_lport.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/scsi/libfc/fc_lport.c b/drivers/scsi/libfc/fc_lport.c
index 74338c8..0b16502 100644
--- a/drivers/scsi/libfc/fc_lport.c
+++ b/drivers/scsi/libfc/fc_lport.c
@@ -537,7 +537,9 @@ int fc_fabric_login(struct fc_lport *lport)
int rc = -1;
mutex_lock(&lport->lp_mutex);
- if (lport->state == LPORT_ST_DISABLED) {
+ if (lport->state == LPORT_ST_DISABLED ||
+ lport->state == LPORT_ST_LOGO) {
+ fc_lport_state_enter(lport, LPORT_ST_RESET);
fc_lport_enter_reset(lport);
rc = 0;
}
@@ -967,6 +969,9 @@ static void fc_lport_enter_reset(struct fc_lport *lport)
FC_LPORT_DBG(lport, "Entered RESET state from %s state\n",
fc_lport_state(lport));
+ if (lport->state == LPORT_ST_DISABLED || lport->state == LPORT_ST_LOGO)
+ return;
+
if (lport->vport) {
if (lport->link_up)
fc_vport_set_state(lport->vport, FC_VPORT_INITIALIZING);