- patches.fixes/patch-2.6.11-rc1: 2.6.11-rc1.
[linux-flexiantxendom0-3.2.10.git] / drivers / scsi / qla2xxx / qla_def.h
index 6c94b86..36ae031 100644 (file)
 
 #if defined(CONFIG_SCSI_QLA6312) || defined(CONFIG_SCSI_QLA6312_MODULE)
 #define IS_QLA6312(ha) ((ha)->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP6312)
-#else
-#define IS_QLA6312(ha) 0
-#endif
-
-#if defined(CONFIG_SCSI_QLA6322) || defined(CONFIG_SCSI_QLA6322_MODULE)
 #define IS_QLA6322(ha) ((ha)->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP6322)
 #else
+#define IS_QLA6312(ha) 0
 #define IS_QLA6322(ha) 0
 #endif
 
@@ -346,6 +342,8 @@ typedef volatile struct {
        volatile uint16_t nvram;        /* NVRAM register. */
 #define NVR_DESELECT           0
 #define NVR_BUSY               BIT_15
+#define NVR_WRT_ENABLE         BIT_14  /* Write enable */
+#define NVR_PR_ENABLE          BIT_13  /* Protection register enable */
 #define NVR_DATA_IN            BIT_3
 #define NVR_DATA_OUT           BIT_2
 #define NVR_SELECT             BIT_1
@@ -1026,9 +1024,27 @@ typedef struct {
        uint8_t  special_options[2];
 
        /* Reserved for expanded RISC parameter block */
-       uint8_t reserved_2[24];
+       uint8_t reserved_2[22];
 
        /*
+        * LSB BIT 0 = Tx Sensitivity 1G bit 0
+        * LSB BIT 1 = Tx Sensitivity 1G bit 1
+        * LSB BIT 2 = Tx Sensitivity 1G bit 2
+        * LSB BIT 3 = Tx Sensitivity 1G bit 3
+        * LSB BIT 4 = Rx Sensitivity 1G bit 0
+        * LSB BIT 5 = Rx Sensitivity 1G bit 1
+        * LSB BIT 6 = Rx Sensitivity 1G bit 2
+        * LSB BIT 7 = Rx Sensitivity 1G bit 3
+        *            
+        * MSB BIT 0 = Tx Sensitivity 2G bit 0
+        * MSB BIT 1 = Tx Sensitivity 2G bit 1
+        * MSB BIT 2 = Tx Sensitivity 2G bit 2
+        * MSB BIT 3 = Tx Sensitivity 2G bit 3
+        * MSB BIT 4 = Rx Sensitivity 2G bit 0
+        * MSB BIT 5 = Rx Sensitivity 2G bit 1
+        * MSB BIT 6 = Rx Sensitivity 2G bit 2
+        * MSB BIT 7 = Rx Sensitivity 2G bit 3
+        *
         * LSB BIT 0 = Output Swing 1G bit 0
         * LSB BIT 1 = Output Swing 1G bit 1
         * LSB BIT 2 = Output Swing 1G bit 2
@@ -1047,7 +1063,7 @@ typedef struct {
         * MSB BIT 6 =
         * MSB BIT 7 =
         */
-       uint8_t seriallink_options[2];
+       uint8_t seriallink_options[4];
 
        /*
         * NVRAM host parameter block
@@ -1083,13 +1099,13 @@ typedef struct {
        uint8_t alternate_node_name[WWN_SIZE];
 
        /*
-        * BIT 0 = Boot Zoning
+        * BIT 0 = Selective Login
         * BIT 1 = Alt-Boot Enable
-        * BIT 2 = Report SCSI Path
-        * BIT 3 = unused
-        * BIT 4 = unused
-        * BIT 5 = unused
-        * BIT 6 = unused
+        * BIT 2 =
+        * BIT 3 = Boot Order List
+        * BIT 4 =
+        * BIT 5 = Selective LUN
+        * BIT 6 =
         * BIT 7 = unused
         */
        uint8_t efi_parameters;
@@ -1359,6 +1375,7 @@ typedef struct {
 /*
  * Status entry status flags
  */
+#define SF_ABTS_TERMINATED     BIT_10
 #define SF_LOGOUT_SENT         BIT_13
 
 /*
@@ -1617,6 +1634,7 @@ typedef struct os_lun {
        spinlock_t q_lock;              /* Lun Lock */
 
        unsigned long q_flag;
+#define LUN_MPIO_RESET_CNTS    1       /* Lun */
 #define LUN_MPIO_BUSY          2       /* Lun is changing paths  */
 #define LUN_EXEC_DELAYED       7       /* Lun execution is delayed */
 
@@ -1739,6 +1757,8 @@ typedef struct fc_port {
 #define FCF_MSA_PORT_ACTIVE    BIT_20
 #define FCF_FAILBACK_DISABLE   BIT_21
 #define FCF_FAILOVER_DISABLE   BIT_22
+#define FCF_DSXXX_DEVICE       BIT_23
+#define FCF_AA_EVA_DEVICE      BIT_24
 
 /* No loop ID flag. */
 #define FC_NO_LOOP_ID          0x1000
@@ -2070,6 +2090,7 @@ typedef struct scsi_qla_host {
                uint32_t        enable_lip_reset        :1;
                uint32_t        enable_lip_full_login   :1;
                uint32_t        enable_target_reset     :1;
+               uint32_t        enable_led_scheme       :1;
        } flags;
 
        atomic_t        loop_state;
@@ -2105,6 +2126,7 @@ typedef struct scsi_qla_host {
 #define FCPORT_RESCAN_NEEDED   21      /* IO descriptor processing needed */
 #define IODESC_PROCESS_NEEDED  22      /* IO descriptor processing needed */
 #define IOCTL_ERROR_RECOVERY   23      
+#define LOOP_RESET_NEEDED      24
 
        uint32_t        device_flags;
 #define DFLG_LOCAL_DEVICES             BIT_0
@@ -2347,7 +2369,7 @@ typedef struct scsi_qla_host {
        uint32_t        fw_transfer_size;
 
        uint16_t        fw_options[16];         /* slots: 1,2,3,10,11 */
-       uint8_t         fw_seriallink_options[2];
+       uint8_t         fw_seriallink_options[4];
 
        /* Firmware dump information. */
        void            *fw_dump;