aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/lpfc/lpfc_hw.h
diff options
context:
space:
mode:
authorJames Smart <James.Smart@Emulex.Com>2007-06-17 20:56:39 -0400
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2007-06-17 23:38:11 -0400
commit858c9f6c19c6f9bf86cbbc64ce0d17c61d6131b8 (patch)
tree9591b15b4424066023e375ad0aa33fdd37e1c452 /drivers/scsi/lpfc/lpfc_hw.h
parent92d7f7b0cde3ad2260e7462b40867b57efd49851 (diff)
[SCSI] lpfc: bug fixes
Following the NPIV support, the following changes have been accumulated in the testing and qualification of the driver: - Fix affinity of ELS ring to slow/deferred event processing - Fix Ring attention masks - Defer dev_loss_tmo timeout handling to worker thread - Consolidate link down error classification for better error checking - Remove unused/deprecated nlp_initiator_tmr timer - Fix for async scan - move adapter init code back into pci_probe_one context. Fix async scan interfaces. - Expand validation of ability to create vports - Extract VPI resource cnt from firmware - Tuning of Login/Reject policies to better deal with overwhelmned targets - Misc ELS and discovery fixes - Export the npiv_enable attribute to sysfs - Mailbox handling fix - Add debugfs support - A few other small misc fixes: - wrong return values, double-frees, bad locking - Added adapter failure heartbeat Signed-off-by: James Smart <James.Smart@emulex.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_hw.h')
-rw-r--r--drivers/scsi/lpfc/lpfc_hw.h21
1 files changed, 18 insertions, 3 deletions
diff --git a/drivers/scsi/lpfc/lpfc_hw.h b/drivers/scsi/lpfc/lpfc_hw.h
index 7fab93d34367..c2fb59f595f3 100644
--- a/drivers/scsi/lpfc/lpfc_hw.h
+++ b/drivers/scsi/lpfc/lpfc_hw.h
@@ -1278,6 +1278,7 @@ typedef struct { /* FireFly BIU registers */
1278#define MBX_KILL_BOARD 0x24 1278#define MBX_KILL_BOARD 0x24
1279#define MBX_CONFIG_FARP 0x25 1279#define MBX_CONFIG_FARP 0x25
1280#define MBX_BEACON 0x2A 1280#define MBX_BEACON 0x2A
1281#define MBX_HEARTBEAT 0x31
1281 1282
1282#define MBX_CONFIG_HBQ 0x7C 1283#define MBX_CONFIG_HBQ 0x7C
1283#define MBX_LOAD_AREA 0x81 1284#define MBX_LOAD_AREA 0x81
@@ -1777,8 +1778,6 @@ typedef struct {
1777#define LMT_4Gb 0x040 1778#define LMT_4Gb 0x040
1778#define LMT_8Gb 0x080 1779#define LMT_8Gb 0x080
1779#define LMT_10Gb 0x100 1780#define LMT_10Gb 0x100
1780
1781
1782 uint32_t rsvd2; 1781 uint32_t rsvd2;
1783 uint32_t rsvd3; 1782 uint32_t rsvd3;
1784 uint32_t max_xri; 1783 uint32_t max_xri;
@@ -1787,7 +1786,10 @@ typedef struct {
1787 uint32_t avail_xri; 1786 uint32_t avail_xri;
1788 uint32_t avail_iocb; 1787 uint32_t avail_iocb;
1789 uint32_t avail_rpi; 1788 uint32_t avail_rpi;
1790 uint32_t default_rpi; 1789 uint32_t max_vpi;
1790 uint32_t rsvd4;
1791 uint32_t rsvd5;
1792 uint32_t avail_vpi;
1791} READ_CONFIG_VAR; 1793} READ_CONFIG_VAR;
1792 1794
1793/* Structure for MB Command READ_RCONFIG (12) */ 1795/* Structure for MB Command READ_RCONFIG (12) */
@@ -3171,3 +3173,16 @@ lpfc_is_LC_HBA(unsigned short device)
3171 else 3173 else
3172 return 0; 3174 return 0;
3173} 3175}
3176
3177/*
3178 * Determine if an IOCB failed because of a link event or firmware reset.
3179 */
3180
3181static inline int
3182lpfc_error_lost_link(IOCB_t *iocbp)
3183{
3184 return (iocbp->ulpStatus == IOSTAT_LOCAL_REJECT &&
3185 (iocbp->un.ulpWord[4] == IOERR_SLI_ABORTED ||
3186 iocbp->un.ulpWord[4] == IOERR_LINK_DOWN ||
3187 iocbp->un.ulpWord[4] == IOERR_SLI_DOWN));
3188}