[SCSI] qla2xxx: Add hardware trace-logging support.
Recent ISPs have a region within FLASH which acts as a repository
for the logging of serious hardware and software failures.
Currently, the region is large enough to support up to 255
entries.
Signed-off-by: Andrew Vasquez <andrew.vasquez@qlogic.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
diff --git a/drivers/scsi/qla2xxx/qla_def.h b/drivers/scsi/qla2xxx/qla_def.h
index 35c730a..13ffeda 100644
--- a/drivers/scsi/qla2xxx/qla_def.h
+++ b/drivers/scsi/qla2xxx/qla_def.h
@@ -2118,6 +2118,7 @@
/* Work events. */
enum qla_work_type {
QLA_EVT_AEN,
+ QLA_EVT_HWE_LOG,
};
@@ -2132,6 +2133,10 @@
enum fc_host_event_code code;
u32 data;
} aen;
+ struct {
+ uint16_t code;
+ uint16_t d1, d2, d3;
+ } hwe;
} u;
};
@@ -2173,6 +2178,7 @@
uint32_t vsan_enabled :1;
uint32_t npiv_supported :1;
uint32_t fce_enabled :1;
+ uint32_t hw_event_marker_found :1;
} flags;
atomic_t loop_state;
@@ -2478,6 +2484,10 @@
uint64_t fce_wr, fce_rd;
struct mutex fce_mutex;
+ uint32_t hw_event_start;
+ uint32_t hw_event_ptr;
+ uint32_t hw_event_pause_errors;
+
uint8_t host_str[16];
uint32_t pci_attr;
uint16_t chip_revision;