summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/lpfc/lpfc_els.c
diff options
context:
space:
mode:
authorJames Smart2011-03-11 22:06:12 +0100
committerJames Bottomley2011-03-23 17:36:09 +0100
commit9940b97bb30d7435c881418c809ed652eb329583 (patch)
treed274c01b97553711c10f0d862b460aa3cd00ba02 /drivers/scsi/lpfc/lpfc_els.c
parent[SCSI] lpfc 8.3.22: T10-DIF corrections (diff)
downloadkernel-qcow2-linux-9940b97bb30d7435c881418c809ed652eb329583.tar.gz
kernel-qcow2-linux-9940b97bb30d7435c881418c809ed652eb329583.tar.xz
kernel-qcow2-linux-9940b97bb30d7435c881418c809ed652eb329583.zip
[SCSI] lpfc 8.3.22: Add support for PCI Adapter Failure
Periodically poll adapter registers to detect pci adapter failure (reads return -1). On failure, take port offline, set error indicators and wake up worker threads. Threads will take adapter offline. Signed-off-by: Alex Iannicelli <alex.iannicelli@emulex.com> Signed-off-by: James Smart <james.smart@emulex.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_els.c')
-rw-r--r--drivers/scsi/lpfc/lpfc_els.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/lpfc/lpfc_els.c b/drivers/scsi/lpfc/lpfc_els.c
index 8e28edf9801e..735028fedda5 100644
--- a/drivers/scsi/lpfc/lpfc_els.c
+++ b/drivers/scsi/lpfc/lpfc_els.c
@@ -89,7 +89,8 @@ lpfc_els_chk_latt(struct lpfc_vport *vport)
return 0;
/* Read the HBA Host Attention Register */
- ha_copy = readl(phba->HAregaddr);
+ if (lpfc_readl(phba->HAregaddr, &ha_copy))
+ return 1;
if (!(ha_copy & HA_LATT))
return 0;