ql4_def.h 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586
  1. /*
  2. * QLogic iSCSI HBA Driver
  3. * Copyright (c) 2003-2006 QLogic Corporation
  4. *
  5. * See LICENSE.qla4xxx for copyright and licensing details.
  6. */
  7. #ifndef __QL4_DEF_H
  8. #define __QL4_DEF_H
  9. #include <linux/kernel.h>
  10. #include <linux/init.h>
  11. #include <linux/types.h>
  12. #include <linux/module.h>
  13. #include <linux/list.h>
  14. #include <linux/pci.h>
  15. #include <linux/dma-mapping.h>
  16. #include <linux/sched.h>
  17. #include <linux/slab.h>
  18. #include <linux/dmapool.h>
  19. #include <linux/mempool.h>
  20. #include <linux/spinlock.h>
  21. #include <linux/workqueue.h>
  22. #include <linux/delay.h>
  23. #include <linux/interrupt.h>
  24. #include <linux/mutex.h>
  25. #include <net/tcp.h>
  26. #include <scsi/scsi.h>
  27. #include <scsi/scsi_host.h>
  28. #include <scsi/scsi_device.h>
  29. #include <scsi/scsi_cmnd.h>
  30. #include <scsi/scsi_transport.h>
  31. #include <scsi/scsi_transport_iscsi.h>
  32. #ifndef PCI_DEVICE_ID_QLOGIC_ISP4010
  33. #define PCI_DEVICE_ID_QLOGIC_ISP4010 0x4010
  34. #endif
  35. #ifndef PCI_DEVICE_ID_QLOGIC_ISP4022
  36. #define PCI_DEVICE_ID_QLOGIC_ISP4022 0x4022
  37. #endif /* */
  38. #define QLA_SUCCESS 0
  39. #define QLA_ERROR 1
  40. /*
  41. * Data bit definitions
  42. */
  43. #define BIT_0 0x1
  44. #define BIT_1 0x2
  45. #define BIT_2 0x4
  46. #define BIT_3 0x8
  47. #define BIT_4 0x10
  48. #define BIT_5 0x20
  49. #define BIT_6 0x40
  50. #define BIT_7 0x80
  51. #define BIT_8 0x100
  52. #define BIT_9 0x200
  53. #define BIT_10 0x400
  54. #define BIT_11 0x800
  55. #define BIT_12 0x1000
  56. #define BIT_13 0x2000
  57. #define BIT_14 0x4000
  58. #define BIT_15 0x8000
  59. #define BIT_16 0x10000
  60. #define BIT_17 0x20000
  61. #define BIT_18 0x40000
  62. #define BIT_19 0x80000
  63. #define BIT_20 0x100000
  64. #define BIT_21 0x200000
  65. #define BIT_22 0x400000
  66. #define BIT_23 0x800000
  67. #define BIT_24 0x1000000
  68. #define BIT_25 0x2000000
  69. #define BIT_26 0x4000000
  70. #define BIT_27 0x8000000
  71. #define BIT_28 0x10000000
  72. #define BIT_29 0x20000000
  73. #define BIT_30 0x40000000
  74. #define BIT_31 0x80000000
  75. /*
  76. * Host adapter default definitions
  77. ***********************************/
  78. #define MAX_HBAS 16
  79. #define MAX_BUSES 1
  80. #define MAX_TARGETS (MAX_PRST_DEV_DB_ENTRIES + MAX_DEV_DB_ENTRIES)
  81. #define MAX_LUNS 0xffff
  82. #define MAX_AEN_ENTRIES 256 /* should be > EXT_DEF_MAX_AEN_QUEUE */
  83. #define MAX_DDB_ENTRIES (MAX_PRST_DEV_DB_ENTRIES + MAX_DEV_DB_ENTRIES)
  84. #define MAX_PDU_ENTRIES 32
  85. #define INVALID_ENTRY 0xFFFF
  86. #define MAX_CMDS_TO_RISC 1024
  87. #define MAX_SRBS MAX_CMDS_TO_RISC
  88. #define MBOX_AEN_REG_COUNT 5
  89. #define MAX_INIT_RETRIES 5
  90. #define IOCB_HIWAT_CUSHION 16
  91. /*
  92. * Buffer sizes
  93. */
  94. #define REQUEST_QUEUE_DEPTH MAX_CMDS_TO_RISC
  95. #define RESPONSE_QUEUE_DEPTH 64
  96. #define QUEUE_SIZE 64
  97. #define DMA_BUFFER_SIZE 512
  98. /*
  99. * Misc
  100. */
  101. #define MAC_ADDR_LEN 6 /* in bytes */
  102. #define IP_ADDR_LEN 4 /* in bytes */
  103. #define DRIVER_NAME "qla4xxx"
  104. #define MAX_LINKED_CMDS_PER_LUN 3
  105. #define MAX_REQS_SERVICED_PER_INTR 16
  106. #define ISCSI_IPADDR_SIZE 4 /* IP address size */
  107. #define ISCSI_ALIAS_SIZE 32 /* ISCSI Alais name size */
  108. #define ISCSI_NAME_SIZE 255 /* ISCSI Name size -
  109. * usually a string */
  110. #define LSDW(x) ((u32)((u64)(x)))
  111. #define MSDW(x) ((u32)((((u64)(x)) >> 16) >> 16))
  112. /*
  113. * Retry & Timeout Values
  114. */
  115. #define MBOX_TOV 60
  116. #define SOFT_RESET_TOV 30
  117. #define RESET_INTR_TOV 3
  118. #define SEMAPHORE_TOV 10
  119. #define ADAPTER_INIT_TOV 120
  120. #define ADAPTER_RESET_TOV 180
  121. #define EXTEND_CMD_TOV 60
  122. #define WAIT_CMD_TOV 30
  123. #define EH_WAIT_CMD_TOV 120
  124. #define FIRMWARE_UP_TOV 60
  125. #define RESET_FIRMWARE_TOV 30
  126. #define LOGOUT_TOV 10
  127. #define IOCB_TOV_MARGIN 10
  128. #define RELOGIN_TOV 18
  129. #define ISNS_DEREG_TOV 5
  130. #define MAX_RESET_HA_RETRIES 2
  131. /*
  132. * SCSI Request Block structure (srb) that is placed
  133. * on cmd->SCp location of every I/O [We have 22 bytes available]
  134. */
  135. struct srb {
  136. struct list_head list; /* (8) */
  137. struct scsi_qla_host *ha; /* HA the SP is queued on */
  138. struct ddb_entry *ddb;
  139. uint16_t flags; /* (1) Status flags. */
  140. #define SRB_DMA_VALID BIT_3 /* DMA Buffer mapped. */
  141. #define SRB_GOT_SENSE BIT_4 /* sense data recieved. */
  142. uint8_t state; /* (1) Status flags. */
  143. #define SRB_NO_QUEUE_STATE 0 /* Request is in between states */
  144. #define SRB_FREE_STATE 1
  145. #define SRB_ACTIVE_STATE 3
  146. #define SRB_ACTIVE_TIMEOUT_STATE 4
  147. #define SRB_SUSPENDED_STATE 7 /* Request in suspended state */
  148. struct scsi_cmnd *cmd; /* (4) SCSI command block */
  149. dma_addr_t dma_handle; /* (4) for unmap of single transfers */
  150. atomic_t ref_count; /* reference count for this srb */
  151. uint32_t fw_ddb_index;
  152. uint8_t err_id; /* error id */
  153. #define SRB_ERR_PORT 1 /* Request failed because "port down" */
  154. #define SRB_ERR_LOOP 2 /* Request failed because "loop down" */
  155. #define SRB_ERR_DEVICE 3 /* Request failed because "device error" */
  156. #define SRB_ERR_OTHER 4
  157. uint16_t reserved;
  158. uint16_t iocb_tov;
  159. uint16_t iocb_cnt; /* Number of used iocbs */
  160. uint16_t cc_stat;
  161. u_long r_start; /* Time we recieve a cmd from OS */
  162. u_long u_start; /* Time when we handed the cmd to F/W */
  163. };
  164. /*
  165. * Device Database (DDB) structure
  166. */
  167. struct ddb_entry {
  168. struct list_head list; /* ddb list */
  169. struct scsi_qla_host *ha;
  170. struct iscsi_cls_session *sess;
  171. struct iscsi_cls_conn *conn;
  172. atomic_t state; /* DDB State */
  173. unsigned long flags; /* DDB Flags */
  174. unsigned long dev_scan_wait_to_start_relogin;
  175. unsigned long dev_scan_wait_to_complete_relogin;
  176. uint16_t os_target_id; /* Target ID */
  177. uint16_t fw_ddb_index; /* DDB firmware index */
  178. uint8_t reserved[2];
  179. uint32_t fw_ddb_device_state; /* F/W Device State -- see ql4_fw.h */
  180. uint32_t CmdSn;
  181. uint16_t target_session_id;
  182. uint16_t connection_id;
  183. uint16_t exe_throttle; /* Max mumber of cmds outstanding
  184. * simultaneously */
  185. uint16_t task_mgmt_timeout; /* Min time for task mgmt cmds to
  186. * complete */
  187. uint16_t default_relogin_timeout; /* Max time to wait for
  188. * relogin to complete */
  189. uint16_t tcp_source_port_num;
  190. uint32_t default_time2wait; /* Default Min time between
  191. * relogins (+aens) */
  192. atomic_t port_down_timer; /* Device connection timer */
  193. atomic_t retry_relogin_timer; /* Min Time between relogins
  194. * (4000 only) */
  195. atomic_t relogin_timer; /* Max Time to wait for relogin to complete */
  196. atomic_t relogin_retry_count; /* Num of times relogin has been
  197. * retried */
  198. uint16_t port;
  199. uint32_t tpgt;
  200. uint8_t ip_addr[ISCSI_IPADDR_SIZE];
  201. uint8_t iscsi_name[ISCSI_NAME_SIZE]; /* 72 x48 */
  202. uint8_t iscsi_alias[0x20];
  203. };
  204. /*
  205. * DDB states.
  206. */
  207. #define DDB_STATE_DEAD 0 /* We can no longer talk to
  208. * this device */
  209. #define DDB_STATE_ONLINE 1 /* Device ready to accept
  210. * commands */
  211. #define DDB_STATE_MISSING 2 /* Device logged off, trying
  212. * to re-login */
  213. /*
  214. * DDB flags.
  215. */
  216. #define DF_RELOGIN 0 /* Relogin to device */
  217. #define DF_NO_RELOGIN 1 /* Do not relogin if IOCTL
  218. * logged it out */
  219. #define DF_ISNS_DISCOVERED 2 /* Device was discovered via iSNS */
  220. #define DF_FO_MASKED 3
  221. /*
  222. * Asynchronous Event Queue structure
  223. */
  224. struct aen {
  225. uint32_t mbox_sts[MBOX_AEN_REG_COUNT];
  226. };
  227. #include "ql4_fw.h"
  228. #include "ql4_nvram.h"
  229. /*
  230. * Linux Host Adapter structure
  231. */
  232. struct scsi_qla_host {
  233. /* Linux adapter configuration data */
  234. struct Scsi_Host *host; /* pointer to host data */
  235. uint32_t tot_ddbs;
  236. unsigned long flags;
  237. #define AF_ONLINE 0 /* 0x00000001 */
  238. #define AF_INIT_DONE 1 /* 0x00000002 */
  239. #define AF_MBOX_COMMAND 2 /* 0x00000004 */
  240. #define AF_MBOX_COMMAND_DONE 3 /* 0x00000008 */
  241. #define AF_INTERRUPTS_ON 6 /* 0x00000040 Not Used */
  242. #define AF_GET_CRASH_RECORD 7 /* 0x00000080 */
  243. #define AF_LINK_UP 8 /* 0x00000100 */
  244. #define AF_TOPCAT_CHIP_PRESENT 9 /* 0x00000200 */
  245. #define AF_IRQ_ATTACHED 10 /* 0x00000400 */
  246. #define AF_ISNS_CMD_IN_PROCESS 12 /* 0x00001000 */
  247. #define AF_ISNS_CMD_DONE 13 /* 0x00002000 */
  248. unsigned long dpc_flags;
  249. #define DPC_RESET_HA 1 /* 0x00000002 */
  250. #define DPC_RETRY_RESET_HA 2 /* 0x00000004 */
  251. #define DPC_RELOGIN_DEVICE 3 /* 0x00000008 */
  252. #define DPC_RESET_HA_DESTROY_DDB_LIST 4 /* 0x00000010 */
  253. #define DPC_RESET_HA_INTR 5 /* 0x00000020 */
  254. #define DPC_ISNS_RESTART 7 /* 0x00000080 */
  255. #define DPC_AEN 9 /* 0x00000200 */
  256. #define DPC_GET_DHCP_IP_ADDR 15 /* 0x00008000 */
  257. uint16_t iocb_cnt;
  258. uint16_t iocb_hiwat;
  259. /* SRB cache. */
  260. #define SRB_MIN_REQ 128
  261. mempool_t *srb_mempool;
  262. /* pci information */
  263. struct pci_dev *pdev;
  264. struct isp_reg __iomem *reg; /* Base I/O address */
  265. unsigned long pio_address;
  266. unsigned long pio_length;
  267. #define MIN_IOBASE_LEN 0x100
  268. uint16_t req_q_count;
  269. uint8_t marker_needed;
  270. uint8_t rsvd1;
  271. unsigned long host_no;
  272. /* NVRAM registers */
  273. struct eeprom_data *nvram;
  274. spinlock_t hardware_lock ____cacheline_aligned;
  275. spinlock_t list_lock;
  276. uint32_t eeprom_cmd_data;
  277. /* Counters for general statistics */
  278. uint64_t adapter_error_count;
  279. uint64_t device_error_count;
  280. uint64_t total_io_count;
  281. uint64_t total_mbytes_xferred;
  282. uint64_t link_failure_count;
  283. uint64_t invalid_crc_count;
  284. uint32_t spurious_int_count;
  285. uint32_t aborted_io_count;
  286. uint32_t io_timeout_count;
  287. uint32_t mailbox_timeout_count;
  288. uint32_t seconds_since_last_intr;
  289. uint32_t seconds_since_last_heartbeat;
  290. uint32_t mac_index;
  291. /* Info Needed for Management App */
  292. /* --- From GetFwVersion --- */
  293. uint32_t firmware_version[2];
  294. uint32_t patch_number;
  295. uint32_t build_number;
  296. /* --- From Init_FW --- */
  297. /* init_cb_t *init_cb; */
  298. uint16_t firmware_options;
  299. uint16_t tcp_options;
  300. uint8_t ip_address[IP_ADDR_LEN];
  301. uint8_t subnet_mask[IP_ADDR_LEN];
  302. uint8_t gateway[IP_ADDR_LEN];
  303. uint8_t alias[32];
  304. uint8_t name_string[256];
  305. uint8_t heartbeat_interval;
  306. uint8_t rsvd;
  307. /* --- From FlashSysInfo --- */
  308. uint8_t my_mac[MAC_ADDR_LEN];
  309. uint8_t serial_number[16];
  310. /* --- From GetFwState --- */
  311. uint32_t firmware_state;
  312. uint32_t board_id;
  313. uint32_t addl_fw_state;
  314. /* Linux kernel thread */
  315. struct workqueue_struct *dpc_thread;
  316. struct work_struct dpc_work;
  317. /* Linux timer thread */
  318. struct timer_list timer;
  319. uint32_t timer_active;
  320. /* Recovery Timers */
  321. uint32_t port_down_retry_count;
  322. uint32_t discovery_wait;
  323. atomic_t check_relogin_timeouts;
  324. uint32_t retry_reset_ha_cnt;
  325. uint32_t isp_reset_timer; /* reset test timer */
  326. uint32_t nic_reset_timer; /* simulated nic reset test timer */
  327. int eh_start;
  328. struct list_head free_srb_q;
  329. uint16_t free_srb_q_count;
  330. uint16_t num_srbs_allocated;
  331. /* DMA Memory Block */
  332. void *queues;
  333. dma_addr_t queues_dma;
  334. unsigned long queues_len;
  335. #define MEM_ALIGN_VALUE \
  336. ((max(REQUEST_QUEUE_DEPTH, RESPONSE_QUEUE_DEPTH)) * \
  337. sizeof(struct queue_entry))
  338. /* request and response queue variables */
  339. dma_addr_t request_dma;
  340. struct queue_entry *request_ring;
  341. struct queue_entry *request_ptr;
  342. dma_addr_t response_dma;
  343. struct queue_entry *response_ring;
  344. struct queue_entry *response_ptr;
  345. dma_addr_t shadow_regs_dma;
  346. struct shadow_regs *shadow_regs;
  347. uint16_t request_in; /* Current indexes. */
  348. uint16_t request_out;
  349. uint16_t response_in;
  350. uint16_t response_out;
  351. /* aen queue variables */
  352. uint16_t aen_q_count; /* Number of available aen_q entries */
  353. uint16_t aen_in; /* Current indexes */
  354. uint16_t aen_out;
  355. struct aen aen_q[MAX_AEN_ENTRIES];
  356. /* This mutex protects several threads to do mailbox commands
  357. * concurrently.
  358. */
  359. struct mutex mbox_sem;
  360. wait_queue_head_t mailbox_wait_queue;
  361. /* temporary mailbox status registers */
  362. volatile uint8_t mbox_status_count;
  363. volatile uint32_t mbox_status[MBOX_REG_COUNT];
  364. /* local device database list (contains internal ddb entries) */
  365. struct list_head ddb_list;
  366. /* Map ddb_list entry by FW ddb index */
  367. struct ddb_entry *fw_ddb_index_map[MAX_DDB_ENTRIES];
  368. };
  369. static inline int is_qla4010(struct scsi_qla_host *ha)
  370. {
  371. return ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP4010;
  372. }
  373. static inline int is_qla4022(struct scsi_qla_host *ha)
  374. {
  375. return ha->pdev->device == PCI_DEVICE_ID_QLOGIC_ISP4022;
  376. }
  377. static inline int adapter_up(struct scsi_qla_host *ha)
  378. {
  379. return (test_bit(AF_ONLINE, &ha->flags) != 0) &&
  380. (test_bit(AF_LINK_UP, &ha->flags) != 0);
  381. }
  382. static inline struct scsi_qla_host* to_qla_host(struct Scsi_Host *shost)
  383. {
  384. return (struct scsi_qla_host *)shost->hostdata;
  385. }
  386. static inline void __iomem* isp_semaphore(struct scsi_qla_host *ha)
  387. {
  388. return (is_qla4022(ha) ?
  389. &ha->reg->u1.isp4022.semaphore :
  390. &ha->reg->u1.isp4010.nvram);
  391. }
  392. static inline void __iomem* isp_nvram(struct scsi_qla_host *ha)
  393. {
  394. return (is_qla4022(ha) ?
  395. &ha->reg->u1.isp4022.nvram :
  396. &ha->reg->u1.isp4010.nvram);
  397. }
  398. static inline void __iomem* isp_ext_hw_conf(struct scsi_qla_host *ha)
  399. {
  400. return (is_qla4022(ha) ?
  401. &ha->reg->u2.isp4022.p0.ext_hw_conf :
  402. &ha->reg->u2.isp4010.ext_hw_conf);
  403. }
  404. static inline void __iomem* isp_port_status(struct scsi_qla_host *ha)
  405. {
  406. return (is_qla4022(ha) ?
  407. &ha->reg->u2.isp4022.p0.port_status :
  408. &ha->reg->u2.isp4010.port_status);
  409. }
  410. static inline void __iomem* isp_port_ctrl(struct scsi_qla_host *ha)
  411. {
  412. return (is_qla4022(ha) ?
  413. &ha->reg->u2.isp4022.p0.port_ctrl :
  414. &ha->reg->u2.isp4010.port_ctrl);
  415. }
  416. static inline void __iomem* isp_port_error_status(struct scsi_qla_host *ha)
  417. {
  418. return (is_qla4022(ha) ?
  419. &ha->reg->u2.isp4022.p0.port_err_status :
  420. &ha->reg->u2.isp4010.port_err_status);
  421. }
  422. static inline void __iomem * isp_gp_out(struct scsi_qla_host *ha)
  423. {
  424. return (is_qla4022(ha) ?
  425. &ha->reg->u2.isp4022.p0.gp_out :
  426. &ha->reg->u2.isp4010.gp_out);
  427. }
  428. static inline int eeprom_ext_hw_conf_offset(struct scsi_qla_host *ha)
  429. {
  430. return (is_qla4022(ha) ?
  431. offsetof(struct eeprom_data, isp4022.ext_hw_conf) / 2 :
  432. offsetof(struct eeprom_data, isp4010.ext_hw_conf) / 2);
  433. }
  434. int ql4xxx_sem_spinlock(struct scsi_qla_host * ha, u32 sem_mask, u32 sem_bits);
  435. void ql4xxx_sem_unlock(struct scsi_qla_host * ha, u32 sem_mask);
  436. int ql4xxx_sem_lock(struct scsi_qla_host * ha, u32 sem_mask, u32 sem_bits);
  437. static inline int ql4xxx_lock_flash(struct scsi_qla_host *a)
  438. {
  439. if (is_qla4022(a))
  440. return ql4xxx_sem_spinlock(a, QL4022_FLASH_SEM_MASK,
  441. (QL4022_RESOURCE_BITS_BASE_CODE |
  442. (a->mac_index)) << 13);
  443. else
  444. return ql4xxx_sem_spinlock(a, QL4010_FLASH_SEM_MASK,
  445. QL4010_FLASH_SEM_BITS);
  446. }
  447. static inline void ql4xxx_unlock_flash(struct scsi_qla_host *a)
  448. {
  449. if (is_qla4022(a))
  450. ql4xxx_sem_unlock(a, QL4022_FLASH_SEM_MASK);
  451. else
  452. ql4xxx_sem_unlock(a, QL4010_FLASH_SEM_MASK);
  453. }
  454. static inline int ql4xxx_lock_nvram(struct scsi_qla_host *a)
  455. {
  456. if (is_qla4022(a))
  457. return ql4xxx_sem_spinlock(a, QL4022_NVRAM_SEM_MASK,
  458. (QL4022_RESOURCE_BITS_BASE_CODE |
  459. (a->mac_index)) << 10);
  460. else
  461. return ql4xxx_sem_spinlock(a, QL4010_NVRAM_SEM_MASK,
  462. QL4010_NVRAM_SEM_BITS);
  463. }
  464. static inline void ql4xxx_unlock_nvram(struct scsi_qla_host *a)
  465. {
  466. if (is_qla4022(a))
  467. ql4xxx_sem_unlock(a, QL4022_NVRAM_SEM_MASK);
  468. else
  469. ql4xxx_sem_unlock(a, QL4010_NVRAM_SEM_MASK);
  470. }
  471. static inline int ql4xxx_lock_drvr(struct scsi_qla_host *a)
  472. {
  473. if (is_qla4022(a))
  474. return ql4xxx_sem_lock(a, QL4022_DRVR_SEM_MASK,
  475. (QL4022_RESOURCE_BITS_BASE_CODE |
  476. (a->mac_index)) << 1);
  477. else
  478. return ql4xxx_sem_lock(a, QL4010_DRVR_SEM_MASK,
  479. QL4010_DRVR_SEM_BITS);
  480. }
  481. static inline void ql4xxx_unlock_drvr(struct scsi_qla_host *a)
  482. {
  483. if (is_qla4022(a))
  484. ql4xxx_sem_unlock(a, QL4022_DRVR_SEM_MASK);
  485. else
  486. ql4xxx_sem_unlock(a, QL4010_DRVR_SEM_MASK);
  487. }
  488. /*---------------------------------------------------------------------------*/
  489. /* Defines for qla4xxx_initialize_adapter() and qla4xxx_recover_adapter() */
  490. #define PRESERVE_DDB_LIST 0
  491. #define REBUILD_DDB_LIST 1
  492. /* Defines for process_aen() */
  493. #define PROCESS_ALL_AENS 0
  494. #define FLUSH_DDB_CHANGED_AENS 1
  495. #define RELOGIN_DDB_CHANGED_AENS 2
  496. #include "ql4_version.h"
  497. #include "ql4_glbl.h"
  498. #include "ql4_dbg.h"
  499. #include "ql4_inline.h"
  500. #endif /*_QLA4XXX_H */