qla2x00.h
来自「这个linux源代码是很全面的~基本完整了~使用c编译的~由于时间问题我没有亲自」· C头文件 代码 · 共 1,767 行 · 第 1/5 页
H
1,767 行
#define FSTATE_P2P_CHOOSE_LOOP 2#define FSTATE_P2P_RCV_UNIDEN_LIP 3#define FSTATE_FATAL_ERROR 4#define FSTATE_LOOP_BACK_CONN 5/* * Port Database structure definition * Little endian except where noted. */#define PORT_DATABASE_SIZE 128 /* bytes */typedef struct { uint8_t options; uint8_t control; uint8_t master_state; uint8_t slave_state;#define PD_STATE_DISCOVERY 0#define PD_STATE_WAIT_DISCOVERY_ACK 1#define PD_STATE_PORT_LOGIN 2#define PD_STATE_WAIT_PORT_LOGIN_ACK 3#define PD_STATE_PROCESS_LOGIN 4#define PD_STATE_WAIT_PROCESS_LOGIN_ACK 5#define PD_STATE_PORT_LOGGED_IN 6#define PD_STATE_PORT_UNAVAILABLE 7#define PD_STATE_PROCESS_LOGOUT 8#define PD_STATE_WAIT_PROCESS_LOGOUT_ACK 9#define PD_STATE_PORT_LOGOUT 10#define PD_STATE_WAIT_PORT_LOGOUT_ACK 11 uint8_t reserved[2]; uint8_t hard_address; uint8_t reserved_1; uint8_t port_id[4]; uint8_t node_name[8]; /* Big endian. */ uint8_t port_name[8]; /* Big endian. */ uint16_t execution_throttle; uint16_t execution_count; uint8_t reset_count; uint8_t reserved_2; uint16_t resource_allocation; uint16_t current_allocation; uint16_t queue_head; uint16_t queue_tail; uint16_t transmit_execution_list_next; uint16_t transmit_execution_list_previous; uint16_t common_features; uint16_t total_concurrent_sequences; uint16_t RO_by_information_category; uint8_t recipient; uint8_t initiator; uint16_t receive_data_size; uint16_t concurrent_sequences; uint16_t open_sequences_per_exchange; uint16_t lun_abort_flags; uint16_t lun_stop_flags; uint16_t stop_queue_head; uint16_t stop_queue_tail; uint16_t port_retry_timer; uint16_t next_sequence_id; uint16_t frame_count; uint16_t PRLI_payload_length; uint8_t prli_svc_param_word_0[2]; /* Big endian */ /* Bits 15-0 of word 0 */ uint8_t prli_svc_param_word_3[2]; /* Big endian */ /* Bits 15-0 of word 3 */ uint16_t loop_id; uint16_t extended_lun_info_list_pointer; uint16_t extended_lun_stop_list_pointer;} port_database_t;/* * ISP Initialization Control Block. */typedef struct{ uint8_t version; #define ICB_VERSION 1 uint8_t reserved_1; struct { uint8_t enable_hard_loop_id :1; uint8_t enable_fairness :1; uint8_t enable_full_duplex :1; uint8_t enable_fast_posting :1; uint8_t enable_target_mode :1; uint8_t disable_initiator_mode :1; uint8_t enable_adisc :1; uint8_t enable_lun_response :1; uint8_t enable_port_update_event :1; uint8_t disable_initial_lip :1; uint8_t enable_decending_soft_assign :1; uint8_t previous_assigned_addressing :1; uint8_t enable_stop_q_on_full :1; uint8_t enable_full_login_on_lip :1; uint8_t node_name_option :1; uint8_t expanded_ifwcb :1; }firmware_options; uint16_t frame_length; uint16_t iocb_allocation; uint16_t execution_throttle; uint8_t retry_count; uint8_t retry_delay;/* TODO: Fix ISP2100 portname/nodename *///#if defined(ISP2100)// uint8_t node_name[WWN_SIZE];//#else uint8_t port_name[WWN_SIZE];////#endif uint16_t adapter_hard_loop_id; uint8_t inquiry_data; uint8_t login_timeout;/* TODO: Fix ISP2100 portname/nodename *///#if defined(ISP2100)// uint8_t reserved_2[8];//#else uint8_t node_name[WWN_SIZE];//#endif uint16_t request_q_outpointer; uint16_t response_q_inpointer; uint16_t request_q_length; uint16_t response_q_length; uint32_t request_q_address[2]; uint32_t response_q_address[2]; uint16_t lun_enables; uint8_t command_resource_count; uint8_t immediate_notify_resource_count; uint16_t timeout; uint16_t reserved_3; struct { uint8_t operation_mode :4; uint8_t connection_options :3; #define LOOP 0 #define P2P 1 #define LOOP_P2P 2 #define P2P_LOOP 3 uint8_t nonpart_if_hard_addr_failed :1; /* Bit 7 */ uint8_t enable_class2 :1; /* Bit 8 */ uint8_t enable_ack0 :1; /* Bit 9 */ uint8_t unused_10 :1; /* bit 10 */ uint8_t unused_11 :1; /* bit 11 */ uint8_t enable_fc_tape :1; /* bit 12 */ uint8_t enable_fc_confirm :1; /* bit 13 */ uint8_t enable_cmd_q_target_mode :1; /* bit 14 */ uint8_t unused_15 :1; /* bit 15 */ }additional_firmware_options; uint8_t response_accum_timer; uint8_t interrupt_delay_timer; uint16_t reserved_4[14];}init_cb_t;/* * ISP Get/Set Target Parameters mailbox command control flags. *//* * Get Link Status mailbox command return buffer. */typedef struct{ uint32_t link_fail_cnt; uint32_t loss_sync_cnt; uint32_t loss_sig_cnt; uint32_t prim_seq_err_cnt; uint32_t inval_xmit_word_cnt; uint32_t inval_crc_cnt;} link_stat_t;/* * NVRAM Command values. */#define NV_START_BIT BIT_2#define NV_WRITE_OP (BIT_26+BIT_24)#define NV_READ_OP (BIT_26+BIT_25)#define NV_ERASE_OP (BIT_26+BIT_25+BIT_24)#define NV_MASK_OP (BIT_26+BIT_25+BIT_24)#define NV_DELAY_COUNT 10/* * ISP2100 NVRAM structure definitions. */typedef struct{ /* * NVRAM header */ uint8_t id[4]; uint8_t nvram_version; uint8_t reserved_0; /* * NVRAM RISC parameter block */ uint8_t parameter_block_version; uint8_t reserved_1; struct { uint8_t enable_hard_loop_id :1; uint8_t enable_fairness :1; uint8_t enable_full_duplex :1; uint8_t enable_fast_posting :1; uint8_t enable_target_mode :1; uint8_t disable_initiator_mode :1; uint8_t enable_adisc :1; uint8_t enable_lun_response :1; uint8_t enable_port_update_event :1; uint8_t disable_initial_lip :1; uint8_t enable_decending_soft_assign :1; uint8_t previous_assigned_addressing :1; uint8_t enable_stop_q_on_full :1; uint8_t enable_full_login_on_lip :1; uint8_t node_name_option :1; uint8_t expanded_ifwcb :1; }firmware_options; uint16_t frame_payload_size; uint16_t max_iocb_allocation; uint16_t execution_throttle; uint8_t retry_count; uint8_t retry_delay; uint8_t port_name[WWN_SIZE]; uint16_t adapter_hard_loop_id; uint8_t inquiry_data; uint8_t login_timeout; uint8_t node_name[WWN_SIZE]; /* Expanded RISC parameter block */ struct {#if OLD uint8_t operation_mode :4; uint8_t connection_options :3; uint8_t enable_fc_tape :1; uint8_t enable_class2 :1; uint8_t enable_fc_confirm :1; uint8_t enable_ack0 :1; uint8_t enable_command_reference_num :1; uint8_t nonpart_if_hard_addr_failed :1; uint8_t enable_read_xfr_rdy :1; uint8_t unused_14 :1; uint8_t unused_15 :1;#endif uint8_t operation_mode :4; uint8_t connection_options :3; uint8_t nonpart_if_hard_addr_failed :1; uint8_t enable_class2 :1; uint8_t enable_ack0 :1; uint8_t unused_10 :1; uint8_t unused_11 :1; uint8_t enable_fc_tape :1; uint8_t enable_fc_confirm :1; uint8_t enable_command_reference_num :1; }additional_firmware_options; uint8_t response_accum_timer; uint8_t interrupt_delay_timer; uint16_t reserved_2[14]; /* * NVRAM host parameter block */ struct { uint8_t unused_0 :1; uint8_t disable_bios :1; uint8_t disable_luns :1; uint8_t enable_selectable_boot :1; uint8_t disable_risc_code_load :1; uint8_t set_cache_line_size_1 :1; uint8_t pci_parity_disable :1; uint8_t enable_extended_logging :1; uint8_t enable_64bit_addressing :1; uint8_t enable_lip_reset :1; uint8_t enable_lip_full_login :1; uint8_t enable_target_reset :1; uint8_t enable_database_storage :1; uint8_t unused_13 :1; uint8_t unused_14 :1; uint8_t unused_15 :1; }host_p; uint8_t boot_node_name[WWN_SIZE]; uint8_t boot_lun_number; uint8_t reset_delay; uint8_t port_down_retry_count; uint8_t reserved_3; uint16_t maximum_luns_per_target; uint16_t reserved_6[7]; /* Offset 100 */ uint16_t reserved_7[25]; /* Offset 150 */ uint16_t reserved_8[25]; /* Offset 200 */ uint8_t oem_id; uint8_t oem_spare0; uint8_t oem_string[6]; uint8_t oem_part[8]; uint8_t oem_fru[8]; uint8_t oem_ec[8]; /* Offset 232 */ struct { uint8_t external_gbic :1; uint8_t risc_ram_parity :1; uint8_t buffer_plus_module :1; uint8_t multi_chip_hba :1; uint8_t unused_1 :1; uint8_t unused_2 :1; uint8_t unused_3 :1; uint8_t unused_4 :1; uint8_t unused_5 :1; uint8_t unused_6 :1; uint8_t unused_7 :1; uint8_t unused_8 :1; uint8_t unused_9 :1; uint8_t unused_10 :1; uint8_t unused_11 :1; uint8_t unused_12 :1; }hba_features; uint16_t reserved_9; uint16_t reserved_10; uint16_t reserved_11; uint16_t reserved_12; uint16_t reserved_13; /* Subsystem ID must be at offset 244 */ uint16_t subsystem_vendor_id; uint16_t reserved_14; /* Subsystem device ID must be at offset 248 */ uint16_t subsystem_device_id; uint16_t reserved_15[2]; uint8_t reserved_16; uint8_t checksum;
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?