diff options
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_crtn.h')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_crtn.h | 43 |
1 files changed, 36 insertions, 7 deletions
diff --git a/drivers/scsi/lpfc/lpfc_crtn.h b/drivers/scsi/lpfc/lpfc_crtn.h index 0830f37409a3..5087c4211b43 100644 --- a/drivers/scsi/lpfc/lpfc_crtn.h +++ b/drivers/scsi/lpfc/lpfc_crtn.h | |||
@@ -1,7 +1,7 @@ | |||
1 | /******************************************************************* | 1 | /******************************************************************* |
2 | * This file is part of the Emulex Linux Device Driver for * | 2 | * This file is part of the Emulex Linux Device Driver for * |
3 | * Fibre Channel Host Bus Adapters. * | 3 | * Fibre Channel Host Bus Adapters. * |
4 | * Copyright (C) 2004-2008 Emulex. All rights reserved. * | 4 | * Copyright (C) 2004-2010 Emulex. All rights reserved. * |
5 | * EMULEX and SLI are trademarks of Emulex. * | 5 | * EMULEX and SLI are trademarks of Emulex. * |
6 | * www.emulex.com * | 6 | * www.emulex.com * |
7 | * * | 7 | * * |
@@ -44,16 +44,27 @@ int lpfc_reg_rpi(struct lpfc_hba *, uint16_t, uint32_t, uint8_t *, | |||
44 | void lpfc_unreg_login(struct lpfc_hba *, uint16_t, uint32_t, LPFC_MBOXQ_t *); | 44 | void lpfc_unreg_login(struct lpfc_hba *, uint16_t, uint32_t, LPFC_MBOXQ_t *); |
45 | void lpfc_unreg_did(struct lpfc_hba *, uint16_t, uint32_t, LPFC_MBOXQ_t *); | 45 | void lpfc_unreg_did(struct lpfc_hba *, uint16_t, uint32_t, LPFC_MBOXQ_t *); |
46 | void lpfc_reg_vpi(struct lpfc_vport *, LPFC_MBOXQ_t *); | 46 | void lpfc_reg_vpi(struct lpfc_vport *, LPFC_MBOXQ_t *); |
47 | void lpfc_register_new_vport(struct lpfc_hba *, struct lpfc_vport *, | ||
48 | struct lpfc_nodelist *); | ||
47 | void lpfc_unreg_vpi(struct lpfc_hba *, uint16_t, LPFC_MBOXQ_t *); | 49 | void lpfc_unreg_vpi(struct lpfc_hba *, uint16_t, LPFC_MBOXQ_t *); |
48 | void lpfc_init_link(struct lpfc_hba *, LPFC_MBOXQ_t *, uint32_t, uint32_t); | 50 | void lpfc_init_link(struct lpfc_hba *, LPFC_MBOXQ_t *, uint32_t, uint32_t); |
49 | void lpfc_request_features(struct lpfc_hba *, struct lpfcMboxq *); | 51 | void lpfc_request_features(struct lpfc_hba *, struct lpfcMboxq *); |
52 | void lpfc_supported_pages(struct lpfcMboxq *); | ||
53 | void lpfc_sli4_params(struct lpfcMboxq *); | ||
54 | int lpfc_pc_sli4_params_get(struct lpfc_hba *, LPFC_MBOXQ_t *); | ||
50 | 55 | ||
51 | struct lpfc_vport *lpfc_find_vport_by_did(struct lpfc_hba *, uint32_t); | 56 | struct lpfc_vport *lpfc_find_vport_by_did(struct lpfc_hba *, uint32_t); |
57 | void lpfc_cleanup_rcv_buffers(struct lpfc_vport *); | ||
58 | void lpfc_rcv_seq_check_edtov(struct lpfc_vport *); | ||
52 | void lpfc_cleanup_rpis(struct lpfc_vport *, int); | 59 | void lpfc_cleanup_rpis(struct lpfc_vport *, int); |
60 | void lpfc_cleanup_pending_mbox(struct lpfc_vport *); | ||
53 | int lpfc_linkdown(struct lpfc_hba *); | 61 | int lpfc_linkdown(struct lpfc_hba *); |
54 | void lpfc_linkdown_port(struct lpfc_vport *); | 62 | void lpfc_linkdown_port(struct lpfc_vport *); |
55 | void lpfc_port_link_failure(struct lpfc_vport *); | 63 | void lpfc_port_link_failure(struct lpfc_vport *); |
56 | void lpfc_mbx_cmpl_read_la(struct lpfc_hba *, LPFC_MBOXQ_t *); | 64 | void lpfc_mbx_cmpl_read_la(struct lpfc_hba *, LPFC_MBOXQ_t *); |
65 | void lpfc_init_vpi_cmpl(struct lpfc_hba *, LPFC_MBOXQ_t *); | ||
66 | void lpfc_cancel_all_vport_retry_delay_timer(struct lpfc_hba *); | ||
67 | void lpfc_retry_pport_discovery(struct lpfc_hba *); | ||
57 | 68 | ||
58 | void lpfc_mbx_cmpl_reg_login(struct lpfc_hba *, LPFC_MBOXQ_t *); | 69 | void lpfc_mbx_cmpl_reg_login(struct lpfc_hba *, LPFC_MBOXQ_t *); |
59 | void lpfc_mbx_cmpl_dflt_rpi(struct lpfc_hba *, LPFC_MBOXQ_t *); | 70 | void lpfc_mbx_cmpl_dflt_rpi(struct lpfc_hba *, LPFC_MBOXQ_t *); |
@@ -71,6 +82,7 @@ void lpfc_set_disctmo(struct lpfc_vport *); | |||
71 | int lpfc_can_disctmo(struct lpfc_vport *); | 82 | int lpfc_can_disctmo(struct lpfc_vport *); |
72 | int lpfc_unreg_rpi(struct lpfc_vport *, struct lpfc_nodelist *); | 83 | int lpfc_unreg_rpi(struct lpfc_vport *, struct lpfc_nodelist *); |
73 | void lpfc_unreg_all_rpis(struct lpfc_vport *); | 84 | void lpfc_unreg_all_rpis(struct lpfc_vport *); |
85 | void lpfc_unreg_hba_rpis(struct lpfc_hba *); | ||
74 | void lpfc_unreg_default_rpis(struct lpfc_vport *); | 86 | void lpfc_unreg_default_rpis(struct lpfc_vport *); |
75 | void lpfc_issue_reg_vpi(struct lpfc_hba *, struct lpfc_vport *); | 87 | void lpfc_issue_reg_vpi(struct lpfc_hba *, struct lpfc_vport *); |
76 | 88 | ||
@@ -97,7 +109,7 @@ int lpfc_disc_state_machine(struct lpfc_vport *, struct lpfc_nodelist *, void *, | |||
97 | 109 | ||
98 | void lpfc_do_scr_ns_plogi(struct lpfc_hba *, struct lpfc_vport *); | 110 | void lpfc_do_scr_ns_plogi(struct lpfc_hba *, struct lpfc_vport *); |
99 | int lpfc_check_sparm(struct lpfc_vport *, struct lpfc_nodelist *, | 111 | int lpfc_check_sparm(struct lpfc_vport *, struct lpfc_nodelist *, |
100 | struct serv_parm *, uint32_t); | 112 | struct serv_parm *, uint32_t, int); |
101 | int lpfc_els_abort(struct lpfc_hba *, struct lpfc_nodelist *); | 113 | int lpfc_els_abort(struct lpfc_hba *, struct lpfc_nodelist *); |
102 | void lpfc_more_plogi(struct lpfc_vport *); | 114 | void lpfc_more_plogi(struct lpfc_vport *); |
103 | void lpfc_more_adisc(struct lpfc_vport *); | 115 | void lpfc_more_adisc(struct lpfc_vport *); |
@@ -144,6 +156,8 @@ void lpfc_hb_timeout_handler(struct lpfc_hba *); | |||
144 | 156 | ||
145 | void lpfc_ct_unsol_event(struct lpfc_hba *, struct lpfc_sli_ring *, | 157 | void lpfc_ct_unsol_event(struct lpfc_hba *, struct lpfc_sli_ring *, |
146 | struct lpfc_iocbq *); | 158 | struct lpfc_iocbq *); |
159 | void lpfc_sli4_ct_abort_unsol_event(struct lpfc_hba *, struct lpfc_sli_ring *, | ||
160 | struct lpfc_iocbq *); | ||
147 | int lpfc_ns_cmd(struct lpfc_vport *, int, uint8_t, uint32_t); | 161 | int lpfc_ns_cmd(struct lpfc_vport *, int, uint8_t, uint32_t); |
148 | int lpfc_fdmi_cmd(struct lpfc_vport *, struct lpfc_nodelist *, int); | 162 | int lpfc_fdmi_cmd(struct lpfc_vport *, struct lpfc_nodelist *, int); |
149 | void lpfc_fdmi_tmo(unsigned long); | 163 | void lpfc_fdmi_tmo(unsigned long); |
@@ -188,11 +202,12 @@ int lpfc_mbox_tmo_val(struct lpfc_hba *, int); | |||
188 | void lpfc_init_vfi(struct lpfcMboxq *, struct lpfc_vport *); | 202 | void lpfc_init_vfi(struct lpfcMboxq *, struct lpfc_vport *); |
189 | void lpfc_reg_vfi(struct lpfcMboxq *, struct lpfc_vport *, dma_addr_t); | 203 | void lpfc_reg_vfi(struct lpfcMboxq *, struct lpfc_vport *, dma_addr_t); |
190 | void lpfc_init_vpi(struct lpfc_hba *, struct lpfcMboxq *, uint16_t); | 204 | void lpfc_init_vpi(struct lpfc_hba *, struct lpfcMboxq *, uint16_t); |
191 | void lpfc_unreg_vfi(struct lpfcMboxq *, uint16_t); | 205 | void lpfc_unreg_vfi(struct lpfcMboxq *, struct lpfc_vport *); |
192 | void lpfc_reg_fcfi(struct lpfc_hba *, struct lpfcMboxq *); | 206 | void lpfc_reg_fcfi(struct lpfc_hba *, struct lpfcMboxq *); |
193 | void lpfc_unreg_fcfi(struct lpfcMboxq *, uint16_t); | 207 | void lpfc_unreg_fcfi(struct lpfcMboxq *, uint16_t); |
194 | void lpfc_resume_rpi(struct lpfcMboxq *, struct lpfc_nodelist *); | 208 | void lpfc_resume_rpi(struct lpfcMboxq *, struct lpfc_nodelist *); |
195 | int lpfc_check_pending_fcoe_event(struct lpfc_hba *, uint8_t); | 209 | int lpfc_check_pending_fcoe_event(struct lpfc_hba *, uint8_t); |
210 | void lpfc_issue_init_vpi(struct lpfc_vport *); | ||
196 | 211 | ||
197 | void lpfc_config_hbq(struct lpfc_hba *, uint32_t, struct lpfc_hbq_init *, | 212 | void lpfc_config_hbq(struct lpfc_hba *, uint32_t, struct lpfc_hbq_init *, |
198 | uint32_t , LPFC_MBOXQ_t *); | 213 | uint32_t , LPFC_MBOXQ_t *); |
@@ -202,7 +217,15 @@ struct hbq_dmabuf *lpfc_sli4_rb_alloc(struct lpfc_hba *); | |||
202 | void lpfc_sli4_rb_free(struct lpfc_hba *, struct hbq_dmabuf *); | 217 | void lpfc_sli4_rb_free(struct lpfc_hba *, struct hbq_dmabuf *); |
203 | void lpfc_sli4_build_dflt_fcf_record(struct lpfc_hba *, struct fcf_record *, | 218 | void lpfc_sli4_build_dflt_fcf_record(struct lpfc_hba *, struct fcf_record *, |
204 | uint16_t); | 219 | uint16_t); |
220 | void lpfc_unregister_fcf(struct lpfc_hba *); | ||
221 | void lpfc_unregister_fcf_rescan(struct lpfc_hba *); | ||
205 | void lpfc_unregister_unused_fcf(struct lpfc_hba *); | 222 | void lpfc_unregister_unused_fcf(struct lpfc_hba *); |
223 | int lpfc_sli4_redisc_fcf_table(struct lpfc_hba *); | ||
224 | void lpfc_fcf_redisc_wait_start_timer(struct lpfc_hba *); | ||
225 | void lpfc_sli4_fcf_dead_failthrough(struct lpfc_hba *); | ||
226 | uint16_t lpfc_sli4_fcf_rr_next_index_get(struct lpfc_hba *); | ||
227 | int lpfc_sli4_fcf_rr_index_set(struct lpfc_hba *, uint16_t); | ||
228 | void lpfc_sli4_fcf_rr_index_clear(struct lpfc_hba *, uint16_t); | ||
206 | 229 | ||
207 | int lpfc_mem_alloc(struct lpfc_hba *, int align); | 230 | int lpfc_mem_alloc(struct lpfc_hba *, int align); |
208 | void lpfc_mem_free(struct lpfc_hba *); | 231 | void lpfc_mem_free(struct lpfc_hba *); |
@@ -212,7 +235,10 @@ void lpfc_stop_vport_timers(struct lpfc_vport *); | |||
212 | void lpfc_poll_timeout(unsigned long ptr); | 235 | void lpfc_poll_timeout(unsigned long ptr); |
213 | void lpfc_poll_start_timer(struct lpfc_hba *); | 236 | void lpfc_poll_start_timer(struct lpfc_hba *); |
214 | void lpfc_poll_eratt(unsigned long); | 237 | void lpfc_poll_eratt(unsigned long); |
215 | void lpfc_sli_poll_fcp_ring(struct lpfc_hba *); | 238 | int |
239 | lpfc_sli_handle_fast_ring_event(struct lpfc_hba *, | ||
240 | struct lpfc_sli_ring *, uint32_t); | ||
241 | |||
216 | struct lpfc_iocbq * lpfc_sli_get_iocbq(struct lpfc_hba *); | 242 | struct lpfc_iocbq * lpfc_sli_get_iocbq(struct lpfc_hba *); |
217 | void lpfc_sli_release_iocbq(struct lpfc_hba *, struct lpfc_iocbq *); | 243 | void lpfc_sli_release_iocbq(struct lpfc_hba *, struct lpfc_iocbq *); |
218 | uint16_t lpfc_sli_next_iotag(struct lpfc_hba *, struct lpfc_iocbq *); | 244 | uint16_t lpfc_sli_next_iotag(struct lpfc_hba *, struct lpfc_iocbq *); |
@@ -235,7 +261,7 @@ void lpfc_sli_mbox_sys_shutdown(struct lpfc_hba *); | |||
235 | int lpfc_sli_check_eratt(struct lpfc_hba *); | 261 | int lpfc_sli_check_eratt(struct lpfc_hba *); |
236 | void lpfc_sli_handle_slow_ring_event(struct lpfc_hba *, | 262 | void lpfc_sli_handle_slow_ring_event(struct lpfc_hba *, |
237 | struct lpfc_sli_ring *, uint32_t); | 263 | struct lpfc_sli_ring *, uint32_t); |
238 | int lpfc_sli4_handle_received_buffer(struct lpfc_hba *); | 264 | void lpfc_sli4_handle_received_buffer(struct lpfc_hba *, struct hbq_dmabuf *); |
239 | void lpfc_sli_def_mbox_cmpl(struct lpfc_hba *, LPFC_MBOXQ_t *); | 265 | void lpfc_sli_def_mbox_cmpl(struct lpfc_hba *, LPFC_MBOXQ_t *); |
240 | int lpfc_sli_issue_iocb(struct lpfc_hba *, uint32_t, | 266 | int lpfc_sli_issue_iocb(struct lpfc_hba *, uint32_t, |
241 | struct lpfc_iocbq *, uint32_t); | 267 | struct lpfc_iocbq *, uint32_t); |
@@ -358,10 +384,13 @@ void lpfc_free_fast_evt(struct lpfc_hba *, struct lpfc_fast_path_event *); | |||
358 | void lpfc_create_static_vport(struct lpfc_hba *); | 384 | void lpfc_create_static_vport(struct lpfc_hba *); |
359 | void lpfc_stop_hba_timers(struct lpfc_hba *); | 385 | void lpfc_stop_hba_timers(struct lpfc_hba *); |
360 | void lpfc_stop_port(struct lpfc_hba *); | 386 | void lpfc_stop_port(struct lpfc_hba *); |
387 | void __lpfc_sli4_stop_fcf_redisc_wait_timer(struct lpfc_hba *); | ||
388 | void lpfc_sli4_stop_fcf_redisc_wait_timer(struct lpfc_hba *); | ||
361 | void lpfc_parse_fcoe_conf(struct lpfc_hba *, uint8_t *, uint32_t); | 389 | void lpfc_parse_fcoe_conf(struct lpfc_hba *, uint8_t *, uint32_t); |
362 | int lpfc_parse_vpd(struct lpfc_hba *, uint8_t *, int); | 390 | int lpfc_parse_vpd(struct lpfc_hba *, uint8_t *, int); |
363 | void lpfc_start_fdiscs(struct lpfc_hba *phba); | 391 | void lpfc_start_fdiscs(struct lpfc_hba *phba); |
364 | 392 | struct lpfc_vport *lpfc_find_vport_by_vpid(struct lpfc_hba *, uint16_t); | |
393 | struct lpfc_sglq *__lpfc_get_active_sglq(struct lpfc_hba *, uint16_t); | ||
365 | #define ScsiResult(host_code, scsi_code) (((host_code) << 16) | scsi_code) | 394 | #define ScsiResult(host_code, scsi_code) (((host_code) << 16) | scsi_code) |
366 | #define HBA_EVENT_RSCN 5 | 395 | #define HBA_EVENT_RSCN 5 |
367 | #define HBA_EVENT_LINK_UP 2 | 396 | #define HBA_EVENT_LINK_UP 2 |
@@ -370,5 +399,5 @@ void lpfc_start_fdiscs(struct lpfc_hba *phba); | |||
370 | /* functions to support SGIOv4/bsg interface */ | 399 | /* functions to support SGIOv4/bsg interface */ |
371 | int lpfc_bsg_request(struct fc_bsg_job *); | 400 | int lpfc_bsg_request(struct fc_bsg_job *); |
372 | int lpfc_bsg_timeout(struct fc_bsg_job *); | 401 | int lpfc_bsg_timeout(struct fc_bsg_job *); |
373 | void lpfc_bsg_ct_unsol_event(struct lpfc_hba *, struct lpfc_sli_ring *, | 402 | int lpfc_bsg_ct_unsol_event(struct lpfc_hba *, struct lpfc_sli_ring *, |
374 | struct lpfc_iocbq *); | 403 | struct lpfc_iocbq *); |