diff options
Diffstat (limited to 'drivers/scsi/qla2xxx/qla_gbl.h')
-rw-r--r-- | drivers/scsi/qla2xxx/qla_gbl.h | 126 |
1 files changed, 123 insertions, 3 deletions
diff --git a/drivers/scsi/qla2xxx/qla_gbl.h b/drivers/scsi/qla2xxx/qla_gbl.h index 3a89bc514e2b..8217c3bcbc2e 100644 --- a/drivers/scsi/qla2xxx/qla_gbl.h +++ b/drivers/scsi/qla2xxx/qla_gbl.h | |||
@@ -44,6 +44,7 @@ extern int qla2x00_local_device_login(scsi_qla_host_t *, fc_port_t *); | |||
44 | extern void qla2x00_update_fcports(scsi_qla_host_t *); | 44 | extern void qla2x00_update_fcports(scsi_qla_host_t *); |
45 | 45 | ||
46 | extern int qla2x00_abort_isp(scsi_qla_host_t *); | 46 | extern int qla2x00_abort_isp(scsi_qla_host_t *); |
47 | extern void qla2x00_abort_isp_cleanup(scsi_qla_host_t *); | ||
47 | 48 | ||
48 | extern void qla2x00_update_fcport(scsi_qla_host_t *, fc_port_t *); | 49 | extern void qla2x00_update_fcport(scsi_qla_host_t *, fc_port_t *); |
49 | 50 | ||
@@ -55,10 +56,20 @@ extern void qla84xx_put_chip(struct scsi_qla_host *); | |||
55 | extern int qla2x00_async_login(struct scsi_qla_host *, fc_port_t *, | 56 | extern int qla2x00_async_login(struct scsi_qla_host *, fc_port_t *, |
56 | uint16_t *); | 57 | uint16_t *); |
57 | extern int qla2x00_async_logout(struct scsi_qla_host *, fc_port_t *); | 58 | extern int qla2x00_async_logout(struct scsi_qla_host *, fc_port_t *); |
58 | extern int qla2x00_async_login_done(struct scsi_qla_host *, fc_port_t *, | 59 | extern int qla2x00_async_adisc(struct scsi_qla_host *, fc_port_t *, |
59 | uint16_t *); | 60 | uint16_t *); |
60 | extern int qla2x00_async_logout_done(struct scsi_qla_host *, fc_port_t *, | 61 | extern int qla2x00_async_tm_cmd(fc_port_t *, uint32_t, uint32_t, uint32_t); |
62 | extern int qla2x00_async_marker(fc_port_t *, uint16_t, uint8_t); | ||
63 | extern void qla2x00_async_login_done(struct scsi_qla_host *, fc_port_t *, | ||
61 | uint16_t *); | 64 | uint16_t *); |
65 | extern void qla2x00_async_logout_done(struct scsi_qla_host *, fc_port_t *, | ||
66 | uint16_t *); | ||
67 | extern void qla2x00_async_adisc_done(struct scsi_qla_host *, fc_port_t *, | ||
68 | uint16_t *); | ||
69 | extern void qla2x00_async_tm_cmd_done(struct scsi_qla_host *, fc_port_t *, | ||
70 | struct srb_iocb *); | ||
71 | extern void qla2x00_async_marker_done(struct scsi_qla_host *, fc_port_t *, | ||
72 | struct srb_iocb *); | ||
62 | 73 | ||
63 | extern fc_port_t * | 74 | extern fc_port_t * |
64 | qla2x00_alloc_fcport(scsi_qla_host_t *, gfp_t ); | 75 | qla2x00_alloc_fcport(scsi_qla_host_t *, gfp_t ); |
@@ -79,6 +90,13 @@ extern int ql2xmaxqueues; | |||
79 | extern int ql2xmultique_tag; | 90 | extern int ql2xmultique_tag; |
80 | extern int ql2xfwloadbin; | 91 | extern int ql2xfwloadbin; |
81 | extern int ql2xetsenable; | 92 | extern int ql2xetsenable; |
93 | extern int ql2xshiftctondsd; | ||
94 | extern int ql2xdbwr; | ||
95 | extern int ql2xdontresethba; | ||
96 | extern int ql2xasynctmfenable; | ||
97 | extern int ql2xenabledif; | ||
98 | extern int ql2xenablehba_err_chk; | ||
99 | extern int ql2xtargetreset; | ||
82 | 100 | ||
83 | extern int qla2x00_loop_reset(scsi_qla_host_t *); | 101 | extern int qla2x00_loop_reset(scsi_qla_host_t *); |
84 | extern void qla2x00_abort_all_cmds(scsi_qla_host_t *, int); | 102 | extern void qla2x00_abort_all_cmds(scsi_qla_host_t *, int); |
@@ -93,6 +111,10 @@ extern int qla2x00_post_async_logout_work(struct scsi_qla_host *, fc_port_t *, | |||
93 | uint16_t *); | 111 | uint16_t *); |
94 | extern int qla2x00_post_async_logout_done_work(struct scsi_qla_host *, | 112 | extern int qla2x00_post_async_logout_done_work(struct scsi_qla_host *, |
95 | fc_port_t *, uint16_t *); | 113 | fc_port_t *, uint16_t *); |
114 | extern int qla2x00_post_async_adisc_work(struct scsi_qla_host *, fc_port_t *, | ||
115 | uint16_t *); | ||
116 | extern int qla2x00_post_async_adisc_done_work(struct scsi_qla_host *, | ||
117 | fc_port_t *, uint16_t *); | ||
96 | extern int qla2x00_post_uevent_work(struct scsi_qla_host *, u32); | 118 | extern int qla2x00_post_uevent_work(struct scsi_qla_host *, u32); |
97 | 119 | ||
98 | extern int qla81xx_restart_mpi_firmware(scsi_qla_host_t *); | 120 | extern int qla81xx_restart_mpi_firmware(scsi_qla_host_t *); |
@@ -135,6 +157,7 @@ extern struct fw_blob *qla2x00_request_firmware(scsi_qla_host_t *); | |||
135 | 157 | ||
136 | extern int qla2x00_wait_for_hba_online(scsi_qla_host_t *); | 158 | extern int qla2x00_wait_for_hba_online(scsi_qla_host_t *); |
137 | extern int qla2x00_wait_for_chip_reset(scsi_qla_host_t *); | 159 | extern int qla2x00_wait_for_chip_reset(scsi_qla_host_t *); |
160 | extern int qla2x00_wait_for_fcoe_ctx_reset(scsi_qla_host_t *); | ||
138 | 161 | ||
139 | extern void qla2xxx_wake_dpc(struct scsi_qla_host *); | 162 | extern void qla2xxx_wake_dpc(struct scsi_qla_host *); |
140 | extern void qla2x00_alert_all_vps(struct rsp_que *, uint16_t *); | 163 | extern void qla2x00_alert_all_vps(struct rsp_que *, uint16_t *); |
@@ -157,6 +180,10 @@ int __qla2x00_marker(struct scsi_qla_host *, struct req_que *, struct rsp_que *, | |||
157 | uint16_t, uint16_t, uint8_t); | 180 | uint16_t, uint16_t, uint8_t); |
158 | extern int qla2x00_start_sp(srb_t *); | 181 | extern int qla2x00_start_sp(srb_t *); |
159 | extern void qla2x00_ctx_sp_free(srb_t *); | 182 | extern void qla2x00_ctx_sp_free(srb_t *); |
183 | extern uint16_t qla24xx_calc_iocbs(uint16_t); | ||
184 | extern void qla24xx_build_scsi_iocbs(srb_t *, struct cmd_type_7 *, uint16_t); | ||
185 | extern int qla24xx_dif_start_scsi(srb_t *); | ||
186 | |||
160 | 187 | ||
161 | /* | 188 | /* |
162 | * Global Function Prototypes in qla_mbx.c source file. | 189 | * Global Function Prototypes in qla_mbx.c source file. |
@@ -328,6 +355,9 @@ extern int | |||
328 | qla2x00_write_ram_word(scsi_qla_host_t *, uint32_t, uint32_t); | 355 | qla2x00_write_ram_word(scsi_qla_host_t *, uint32_t, uint32_t); |
329 | 356 | ||
330 | extern int qla2x00_get_data_rate(scsi_qla_host_t *); | 357 | extern int qla2x00_get_data_rate(scsi_qla_host_t *); |
358 | extern int qla24xx_set_fcp_prio(scsi_qla_host_t *, uint16_t, uint16_t, | ||
359 | uint16_t *); | ||
360 | |||
331 | /* | 361 | /* |
332 | * Global Function Prototypes in qla_isr.c source file. | 362 | * Global Function Prototypes in qla_isr.c source file. |
333 | */ | 363 | */ |
@@ -340,6 +370,7 @@ qla24xx_process_response_queue(struct scsi_qla_host *, struct rsp_que *); | |||
340 | extern int qla2x00_request_irqs(struct qla_hw_data *, struct rsp_que *); | 370 | extern int qla2x00_request_irqs(struct qla_hw_data *, struct rsp_que *); |
341 | extern void qla2x00_free_irqs(scsi_qla_host_t *); | 371 | extern void qla2x00_free_irqs(scsi_qla_host_t *); |
342 | 372 | ||
373 | extern int qla2x00_get_data_rate(scsi_qla_host_t *); | ||
343 | /* | 374 | /* |
344 | * Global Function Prototypes in qla_sup.c source file. | 375 | * Global Function Prototypes in qla_sup.c source file. |
345 | */ | 376 | */ |
@@ -384,6 +415,7 @@ extern int qla2xxx_get_flash_info(scsi_qla_host_t *); | |||
384 | extern int qla2xxx_get_vpd_field(scsi_qla_host_t *, char *, char *, size_t); | 415 | extern int qla2xxx_get_vpd_field(scsi_qla_host_t *, char *, char *, size_t); |
385 | 416 | ||
386 | extern void qla2xxx_flash_npiv_conf(scsi_qla_host_t *); | 417 | extern void qla2xxx_flash_npiv_conf(scsi_qla_host_t *); |
418 | extern int qla24xx_read_fcp_prio_cfg(scsi_qla_host_t *); | ||
387 | 419 | ||
388 | /* | 420 | /* |
389 | * Global Function Prototypes in qla_dbg.c source file. | 421 | * Global Function Prototypes in qla_dbg.c source file. |
@@ -395,6 +427,7 @@ extern void qla25xx_fw_dump(scsi_qla_host_t *, int); | |||
395 | extern void qla81xx_fw_dump(scsi_qla_host_t *, int); | 427 | extern void qla81xx_fw_dump(scsi_qla_host_t *, int); |
396 | extern void qla2x00_dump_regs(scsi_qla_host_t *); | 428 | extern void qla2x00_dump_regs(scsi_qla_host_t *); |
397 | extern void qla2x00_dump_buffer(uint8_t *, uint32_t); | 429 | extern void qla2x00_dump_buffer(uint8_t *, uint32_t); |
430 | extern void qla2x00_dump_buffer_zipped(uint8_t *, uint32_t); | ||
398 | 431 | ||
399 | /* | 432 | /* |
400 | * Global Function Prototypes in qla_gs.c source file. | 433 | * Global Function Prototypes in qla_gs.c source file. |
@@ -430,7 +463,10 @@ extern void qla2x00_init_host_attr(scsi_qla_host_t *); | |||
430 | extern void qla2x00_alloc_sysfs_attr(scsi_qla_host_t *); | 463 | extern void qla2x00_alloc_sysfs_attr(scsi_qla_host_t *); |
431 | extern void qla2x00_free_sysfs_attr(scsi_qla_host_t *); | 464 | extern void qla2x00_free_sysfs_attr(scsi_qla_host_t *); |
432 | extern int qla2x00_loopback_test(scsi_qla_host_t *, struct msg_echo_lb *, uint16_t *); | 465 | extern int qla2x00_loopback_test(scsi_qla_host_t *, struct msg_echo_lb *, uint16_t *); |
433 | extern int qla2x00_echo_test(scsi_qla_host_t *, struct msg_echo_lb *, uint16_t *); | 466 | extern int qla2x00_echo_test(scsi_qla_host_t *, |
467 | struct msg_echo_lb *, uint16_t *); | ||
468 | extern int qla24xx_update_all_fcp_prio(scsi_qla_host_t *); | ||
469 | extern int qla24xx_fcp_prio_cfg_valid(struct qla_fcp_prio_cfg *, uint8_t); | ||
434 | 470 | ||
435 | /* | 471 | /* |
436 | * Global Function Prototypes in qla_dfs.c source file. | 472 | * Global Function Prototypes in qla_dfs.c source file. |
@@ -459,4 +495,88 @@ extern void qla25xx_wrt_req_reg(struct qla_hw_data *, uint16_t, uint16_t); | |||
459 | extern void qla25xx_wrt_rsp_reg(struct qla_hw_data *, uint16_t, uint16_t); | 495 | extern void qla25xx_wrt_rsp_reg(struct qla_hw_data *, uint16_t, uint16_t); |
460 | extern void qla24xx_wrt_rsp_reg(struct qla_hw_data *, uint16_t, uint16_t); | 496 | extern void qla24xx_wrt_rsp_reg(struct qla_hw_data *, uint16_t, uint16_t); |
461 | 497 | ||
498 | /* qla82xx related functions */ | ||
499 | |||
500 | /* PCI related functions */ | ||
501 | extern int qla82xx_pci_config(struct scsi_qla_host *); | ||
502 | extern int qla82xx_pci_mem_read_2M(struct qla_hw_data *, u64, void *, int); | ||
503 | extern int qla82xx_pci_mem_write_2M(struct qla_hw_data *, u64, void *, int); | ||
504 | extern char *qla82xx_pci_info_str(struct scsi_qla_host *, char *); | ||
505 | extern int qla82xx_pci_region_offset(struct pci_dev *, int); | ||
506 | extern int qla82xx_pci_region_len(struct pci_dev *, int); | ||
507 | extern int qla82xx_iospace_config(struct qla_hw_data *); | ||
508 | |||
509 | /* Initialization related functions */ | ||
510 | extern void qla82xx_reset_chip(struct scsi_qla_host *); | ||
511 | extern void qla82xx_config_rings(struct scsi_qla_host *); | ||
512 | extern int qla82xx_nvram_config(struct scsi_qla_host *); | ||
513 | extern int qla82xx_pinit_from_rom(scsi_qla_host_t *); | ||
514 | extern int qla82xx_load_firmware(scsi_qla_host_t *); | ||
515 | extern int qla82xx_reset_hw(scsi_qla_host_t *); | ||
516 | extern int qla82xx_load_risc_blob(scsi_qla_host_t *, uint32_t *); | ||
517 | extern void qla82xx_watchdog(scsi_qla_host_t *); | ||
518 | |||
519 | /* Firmware and flash related functions */ | ||
520 | extern int qla82xx_load_risc(scsi_qla_host_t *, uint32_t *); | ||
521 | extern uint8_t *qla82xx_read_optrom_data(struct scsi_qla_host *, uint8_t *, | ||
522 | uint32_t, uint32_t); | ||
523 | extern int qla82xx_write_optrom_data(struct scsi_qla_host *, uint8_t *, | ||
524 | uint32_t, uint32_t); | ||
525 | |||
526 | /* Mailbox related functions */ | ||
527 | extern int qla82xx_abort_isp(scsi_qla_host_t *); | ||
528 | extern int qla82xx_restart_isp(scsi_qla_host_t *); | ||
529 | |||
530 | /* IOCB related functions */ | ||
531 | extern int qla82xx_start_scsi(srb_t *); | ||
532 | |||
533 | /* Interrupt related */ | ||
534 | extern irqreturn_t qla82xx_intr_handler(int, void *); | ||
535 | extern irqreturn_t qla82xx_msi_handler(int, void *); | ||
536 | extern irqreturn_t qla82xx_msix_default(int, void *); | ||
537 | extern irqreturn_t qla82xx_msix_rsp_q(int, void *); | ||
538 | extern void qla82xx_enable_intrs(struct qla_hw_data *); | ||
539 | extern void qla82xx_disable_intrs(struct qla_hw_data *); | ||
540 | extern void qla82xx_mbx_completion(scsi_qla_host_t *, uint16_t); | ||
541 | extern void qla82xx_poll(int, void *); | ||
542 | extern void qla82xx_init_flags(struct qla_hw_data *); | ||
543 | |||
544 | /* ISP 8021 hardware related */ | ||
545 | extern int qla82xx_crb_win_lock(struct qla_hw_data *); | ||
546 | extern void qla82xx_crb_win_unlock(struct qla_hw_data *); | ||
547 | extern int qla82xx_pci_get_crb_addr_2M(struct qla_hw_data *, ulong *); | ||
548 | extern int qla82xx_wr_32(struct qla_hw_data *, ulong, u32); | ||
549 | extern int qla82xx_rd_32(struct qla_hw_data *, ulong); | ||
550 | extern int qla82xx_rdmem(struct qla_hw_data *, u64, void *, int); | ||
551 | extern int qla82xx_wrmem(struct qla_hw_data *, u64, void *, int); | ||
552 | extern int qla82xx_check_for_bad_spd(struct qla_hw_data *); | ||
553 | extern int qla82xx_load_fw(scsi_qla_host_t *); | ||
554 | extern int qla82xx_rom_lock(struct qla_hw_data *); | ||
555 | extern void qla82xx_rom_unlock(struct qla_hw_data *); | ||
556 | extern int qla82xx_rom_fast_read(struct qla_hw_data *, int , int *); | ||
557 | extern int qla82xx_do_rom_fast_read(struct qla_hw_data *, int, int *); | ||
558 | extern unsigned long qla82xx_decode_crb_addr(unsigned long); | ||
559 | |||
560 | /* ISP 8021 IDC */ | ||
561 | extern void qla82xx_clear_drv_active(struct qla_hw_data *); | ||
562 | extern int qla82xx_idc_lock(struct qla_hw_data *); | ||
563 | extern void qla82xx_idc_unlock(struct qla_hw_data *); | ||
564 | extern int qla82xx_device_state_handler(scsi_qla_host_t *); | ||
565 | |||
566 | extern void qla2x00_set_model_info(scsi_qla_host_t *, uint8_t *, | ||
567 | size_t, char *); | ||
568 | extern int qla82xx_mbx_intr_enable(scsi_qla_host_t *); | ||
569 | extern int qla82xx_mbx_intr_disable(scsi_qla_host_t *); | ||
570 | extern void qla82xx_start_iocbs(srb_t *); | ||
571 | extern int qla82xx_fcoe_ctx_reset(scsi_qla_host_t *); | ||
572 | extern void qla82xx_wait_for_pending_commands(scsi_qla_host_t *); | ||
573 | |||
574 | /* BSG related functions */ | ||
575 | extern int qla24xx_bsg_request(struct fc_bsg_job *); | ||
576 | extern int qla24xx_bsg_timeout(struct fc_bsg_job *); | ||
577 | extern int qla84xx_reset_chip(scsi_qla_host_t *, uint16_t); | ||
578 | extern int qla2x00_issue_iocb_timeout(scsi_qla_host_t *, void *, | ||
579 | dma_addr_t, size_t, uint32_t); | ||
580 | extern int qla2x00_get_idma_speed(scsi_qla_host_t *, uint16_t, | ||
581 | uint16_t *, uint16_t *); | ||
462 | #endif /* _QLA_GBL_H */ | 582 | #endif /* _QLA_GBL_H */ |