diff options
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_fw.h')
| -rw-r--r-- | drivers/scsi/qla2xxx/qla_fw.h | 106 |
1 files changed, 105 insertions, 1 deletions
diff --git a/drivers/scsi/qla2xxx/qla_fw.h b/drivers/scsi/qla2xxx/qla_fw.h index 42c5587cc50c..93f833960147 100644 --- a/drivers/scsi/qla2xxx/qla_fw.h +++ b/drivers/scsi/qla2xxx/qla_fw.h | |||
| @@ -400,6 +400,7 @@ struct cmd_type_6 { | |||
| 400 | struct scsi_lun lun; /* FCP LUN (BE). */ | 400 | struct scsi_lun lun; /* FCP LUN (BE). */ |
| 401 | 401 | ||
| 402 | uint16_t control_flags; /* Control flags. */ | 402 | uint16_t control_flags; /* Control flags. */ |
| 403 | #define CF_DIF_SEG_DESCR_ENABLE BIT_3 | ||
| 403 | #define CF_DATA_SEG_DESCR_ENABLE BIT_2 | 404 | #define CF_DATA_SEG_DESCR_ENABLE BIT_2 |
| 404 | #define CF_READ_DATA BIT_1 | 405 | #define CF_READ_DATA BIT_1 |
| 405 | #define CF_WRITE_DATA BIT_0 | 406 | #define CF_WRITE_DATA BIT_0 |
| @@ -466,6 +467,43 @@ struct cmd_type_7 { | |||
| 466 | uint32_t dseg_0_len; /* Data segment 0 length. */ | 467 | uint32_t dseg_0_len; /* Data segment 0 length. */ |
| 467 | }; | 468 | }; |
| 468 | 469 | ||
| 470 | #define COMMAND_TYPE_CRC_2 0x6A /* Command Type CRC_2 (Type 6) | ||
| 471 | * (T10-DIF) */ | ||
| 472 | struct cmd_type_crc_2 { | ||
| 473 | uint8_t entry_type; /* Entry type. */ | ||
| 474 | uint8_t entry_count; /* Entry count. */ | ||
| 475 | uint8_t sys_define; /* System defined. */ | ||
| 476 | uint8_t entry_status; /* Entry Status. */ | ||
| 477 | |||
| 478 | uint32_t handle; /* System handle. */ | ||
| 479 | |||
| 480 | uint16_t nport_handle; /* N_PORT handle. */ | ||
| 481 | uint16_t timeout; /* Command timeout. */ | ||
| 482 | |||
| 483 | uint16_t dseg_count; /* Data segment count. */ | ||
| 484 | |||
| 485 | uint16_t fcp_rsp_dseg_len; /* FCP_RSP DSD length. */ | ||
| 486 | |||
| 487 | struct scsi_lun lun; /* FCP LUN (BE). */ | ||
| 488 | |||
| 489 | uint16_t control_flags; /* Control flags. */ | ||
| 490 | |||
| 491 | uint16_t fcp_cmnd_dseg_len; /* Data segment length. */ | ||
| 492 | uint32_t fcp_cmnd_dseg_address[2]; /* Data segment address. */ | ||
| 493 | |||
| 494 | uint32_t fcp_rsp_dseg_address[2]; /* Data segment address. */ | ||
| 495 | |||
| 496 | uint32_t byte_count; /* Total byte count. */ | ||
| 497 | |||
| 498 | uint8_t port_id[3]; /* PortID of destination port. */ | ||
| 499 | uint8_t vp_index; | ||
| 500 | |||
| 501 | uint32_t crc_context_address[2]; /* Data segment address. */ | ||
| 502 | uint16_t crc_context_len; /* Data segment length. */ | ||
| 503 | uint16_t reserved_1; /* MUST be set to 0. */ | ||
| 504 | }; | ||
| 505 | |||
| 506 | |||
| 469 | /* | 507 | /* |
| 470 | * ISP queue - status entry structure definition. | 508 | * ISP queue - status entry structure definition. |
| 471 | */ | 509 | */ |
| @@ -496,10 +534,17 @@ struct sts_entry_24xx { | |||
| 496 | 534 | ||
| 497 | uint32_t sense_len; /* FCP SENSE length. */ | 535 | uint32_t sense_len; /* FCP SENSE length. */ |
| 498 | uint32_t rsp_data_len; /* FCP response data length. */ | 536 | uint32_t rsp_data_len; /* FCP response data length. */ |
| 499 | |||
| 500 | uint8_t data[28]; /* FCP response/sense information. */ | 537 | uint8_t data[28]; /* FCP response/sense information. */ |
| 538 | /* | ||
| 539 | * If DIF Error is set in comp_status, these additional fields are | ||
| 540 | * defined: | ||
| 541 | * &data[10] : uint8_t report_runt_bg[2]; - computed guard | ||
| 542 | * &data[12] : uint8_t actual_dif[8]; - DIF Data recieved | ||
| 543 | * &data[20] : uint8_t expected_dif[8]; - DIF Data computed | ||
| 544 | */ | ||
| 501 | }; | 545 | }; |
| 502 | 546 | ||
| 547 | |||
| 503 | /* | 548 | /* |
| 504 | * Status entry completion status | 549 | * Status entry completion status |
| 505 | */ | 550 | */ |
| @@ -841,6 +886,8 @@ struct device_reg_24xx { | |||
| 841 | #define FA_HW_EVENT_ENTRY_SIZE 4 | 886 | #define FA_HW_EVENT_ENTRY_SIZE 4 |
| 842 | #define FA_NPIV_CONF0_ADDR 0x5C000 | 887 | #define FA_NPIV_CONF0_ADDR 0x5C000 |
| 843 | #define FA_NPIV_CONF1_ADDR 0x5D000 | 888 | #define FA_NPIV_CONF1_ADDR 0x5D000 |
| 889 | #define FA_FCP_PRIO0_ADDR 0x10000 | ||
| 890 | #define FA_FCP_PRIO1_ADDR 0x12000 | ||
| 844 | 891 | ||
| 845 | /* | 892 | /* |
| 846 | * Flash Error Log Event Codes. | 893 | * Flash Error Log Event Codes. |
| @@ -1274,6 +1321,8 @@ struct qla_flt_header { | |||
| 1274 | #define FLT_REG_NPIV_CONF_0 0x29 | 1321 | #define FLT_REG_NPIV_CONF_0 0x29 |
| 1275 | #define FLT_REG_NPIV_CONF_1 0x2a | 1322 | #define FLT_REG_NPIV_CONF_1 0x2a |
| 1276 | #define FLT_REG_GOLD_FW 0x2f | 1323 | #define FLT_REG_GOLD_FW 0x2f |
| 1324 | #define FLT_REG_FCP_PRIO_0 0x87 | ||
| 1325 | #define FLT_REG_FCP_PRIO_1 0x88 | ||
| 1277 | 1326 | ||
| 1278 | struct qla_flt_region { | 1327 | struct qla_flt_region { |
| 1279 | uint32_t code; | 1328 | uint32_t code; |
| @@ -1750,6 +1799,61 @@ struct ex_init_cb_81xx { | |||
| 1750 | #define FARX_ACCESS_FLASH_CONF_81XX 0x7FFD0000 | 1799 | #define FARX_ACCESS_FLASH_CONF_81XX 0x7FFD0000 |
| 1751 | #define FARX_ACCESS_FLASH_DATA_81XX 0x7F800000 | 1800 | #define FARX_ACCESS_FLASH_DATA_81XX 0x7F800000 |
| 1752 | 1801 | ||
| 1802 | /* FCP priority config defines *************************************/ | ||
| 1803 | /* operations */ | ||
| 1804 | #define QLFC_FCP_PRIO_DISABLE 0x0 | ||
| 1805 | #define QLFC_FCP_PRIO_ENABLE 0x1 | ||
| 1806 | #define QLFC_FCP_PRIO_GET_CONFIG 0x2 | ||
| 1807 | #define QLFC_FCP_PRIO_SET_CONFIG 0x3 | ||
| 1808 | |||
| 1809 | struct qla_fcp_prio_entry { | ||
| 1810 | uint16_t flags; /* Describes parameter(s) in FCP */ | ||
| 1811 | /* priority entry that are valid */ | ||
| 1812 | #define FCP_PRIO_ENTRY_VALID 0x1 | ||
| 1813 | #define FCP_PRIO_ENTRY_TAG_VALID 0x2 | ||
| 1814 | #define FCP_PRIO_ENTRY_SPID_VALID 0x4 | ||
| 1815 | #define FCP_PRIO_ENTRY_DPID_VALID 0x8 | ||
| 1816 | #define FCP_PRIO_ENTRY_LUNB_VALID 0x10 | ||
| 1817 | #define FCP_PRIO_ENTRY_LUNE_VALID 0x20 | ||
| 1818 | #define FCP_PRIO_ENTRY_SWWN_VALID 0x40 | ||
| 1819 | #define FCP_PRIO_ENTRY_DWWN_VALID 0x80 | ||
| 1820 | uint8_t tag; /* Priority value */ | ||
| 1821 | uint8_t reserved; /* Reserved for future use */ | ||
| 1822 | uint32_t src_pid; /* Src port id. high order byte */ | ||
| 1823 | /* unused; -1 (wild card) */ | ||
| 1824 | uint32_t dst_pid; /* Src port id. high order byte */ | ||
| 1825 | /* unused; -1 (wild card) */ | ||
| 1826 | uint16_t lun_beg; /* 1st lun num of lun range. */ | ||
| 1827 | /* -1 (wild card) */ | ||
| 1828 | uint16_t lun_end; /* 2nd lun num of lun range. */ | ||
| 1829 | /* -1 (wild card) */ | ||
| 1830 | uint8_t src_wwpn[8]; /* Source WWPN: -1 (wild card) */ | ||
| 1831 | uint8_t dst_wwpn[8]; /* Destination WWPN: -1 (wild card) */ | ||
| 1832 | }; | ||
| 1833 | |||
| 1834 | struct qla_fcp_prio_cfg { | ||
| 1835 | uint8_t signature[4]; /* "HQOS" signature of config data */ | ||
| 1836 | uint16_t version; /* 1: Initial version */ | ||
| 1837 | uint16_t length; /* config data size in num bytes */ | ||
| 1838 | uint16_t checksum; /* config data bytes checksum */ | ||
| 1839 | uint16_t num_entries; /* Number of entries */ | ||
| 1840 | uint16_t size_of_entry; /* Size of each entry in num bytes */ | ||
| 1841 | uint8_t attributes; /* enable/disable, persistence */ | ||
| 1842 | #define FCP_PRIO_ATTR_DISABLE 0x0 | ||
| 1843 | #define FCP_PRIO_ATTR_ENABLE 0x1 | ||
| 1844 | #define FCP_PRIO_ATTR_PERSIST 0x2 | ||
| 1845 | uint8_t reserved; /* Reserved for future use */ | ||
| 1846 | #define FCP_PRIO_CFG_HDR_SIZE 0x10 | ||
| 1847 | struct qla_fcp_prio_entry entry[1]; /* fcp priority entries */ | ||
| 1848 | #define FCP_PRIO_CFG_ENTRY_SIZE 0x20 | ||
| 1849 | }; | ||
| 1850 | |||
| 1851 | #define FCP_PRIO_CFG_SIZE (32*1024) /* fcp prio data per port*/ | ||
| 1852 | |||
| 1853 | /* 25XX Support ****************************************************/ | ||
| 1854 | #define FA_FCP_PRIO0_ADDR_25 0x3C000 | ||
| 1855 | #define FA_FCP_PRIO1_ADDR_25 0x3E000 | ||
| 1856 | |||
| 1753 | /* 81XX Flash locations -- occupies second 2MB region. */ | 1857 | /* 81XX Flash locations -- occupies second 2MB region. */ |
| 1754 | #define FA_BOOT_CODE_ADDR_81 0x80000 | 1858 | #define FA_BOOT_CODE_ADDR_81 0x80000 |
| 1755 | #define FA_RISC_CODE_ADDR_81 0xA0000 | 1859 | #define FA_RISC_CODE_ADDR_81 0xA0000 |
