Lines Matching refs:job
300 struct fc_bsg_job *job; in lpfc_bsg_send_mgmt_cmd_cmp() local
313 job = dd_data->set_job; in lpfc_bsg_send_mgmt_cmd_cmp()
314 if (job) { in lpfc_bsg_send_mgmt_cmd_cmp()
316 job->dd_data = NULL; in lpfc_bsg_send_mgmt_cmd_cmp()
334 if (job) { in lpfc_bsg_send_mgmt_cmd_cmp()
353 job->reply->reply_payload_rcv_len = in lpfc_bsg_send_mgmt_cmd_cmp()
354 lpfc_bsg_copy_data(rmp, &job->reply_payload, in lpfc_bsg_send_mgmt_cmd_cmp()
369 if (job) { in lpfc_bsg_send_mgmt_cmd_cmp()
370 job->reply->result = rc; in lpfc_bsg_send_mgmt_cmd_cmp()
371 job->job_done(job); in lpfc_bsg_send_mgmt_cmd_cmp()
381 lpfc_bsg_send_mgmt_cmd(struct fc_bsg_job *job) in lpfc_bsg_send_mgmt_cmd() argument
383 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_send_mgmt_cmd()
385 struct lpfc_rport_data *rdata = job->rport->dd_data; in lpfc_bsg_send_mgmt_cmd()
401 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_send_mgmt_cmd()
445 cmp = lpfc_alloc_bsg_buffers(phba, job->request_payload.payload_len, in lpfc_bsg_send_mgmt_cmd()
451 lpfc_bsg_copy_data(cmp, &job->request_payload, in lpfc_bsg_send_mgmt_cmd()
452 job->request_payload.payload_len, 1); in lpfc_bsg_send_mgmt_cmd()
456 rmp = lpfc_alloc_bsg_buffers(phba, job->reply_payload.payload_len, 0, in lpfc_bsg_send_mgmt_cmd()
493 dd_data->set_job = job; in lpfc_bsg_send_mgmt_cmd()
497 job->dd_data = dd_data; in lpfc_bsg_send_mgmt_cmd()
527 job->dd_data = NULL; in lpfc_bsg_send_mgmt_cmd()
545 job->reply->result = rc; in lpfc_bsg_send_mgmt_cmd()
546 job->dd_data = NULL; in lpfc_bsg_send_mgmt_cmd()
573 struct fc_bsg_job *job; in lpfc_bsg_rport_els_cmp() local
589 job = dd_data->set_job; in lpfc_bsg_rport_els_cmp()
590 if (job) { in lpfc_bsg_rport_els_cmp()
592 job->dd_data = NULL; in lpfc_bsg_rport_els_cmp()
609 if (job) { in lpfc_bsg_rport_els_cmp()
612 job->reply->reply_payload_rcv_len = in lpfc_bsg_rport_els_cmp()
613 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_rport_els_cmp()
614 job->reply_payload.sg_cnt, in lpfc_bsg_rport_els_cmp()
618 job->reply->reply_payload_rcv_len = in lpfc_bsg_rport_els_cmp()
622 els_reply = &job->reply->reply_data.ctels_reply; in lpfc_bsg_rport_els_cmp()
639 if (job) { in lpfc_bsg_rport_els_cmp()
640 job->reply->result = rc; in lpfc_bsg_rport_els_cmp()
641 job->job_done(job); in lpfc_bsg_rport_els_cmp()
651 lpfc_bsg_rport_els(struct fc_bsg_job *job) in lpfc_bsg_rport_els() argument
653 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_rport_els()
655 struct lpfc_rport_data *rdata = job->rport->dd_data; in lpfc_bsg_rport_els()
667 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_rport_els()
673 if (job->request_payload.payload_len > FCELSSIZE) { in lpfc_bsg_rport_els()
687 elscmd = job->request->rqst_data.r_els.els_code; in lpfc_bsg_rport_els()
688 cmdsize = job->request_payload.payload_len; in lpfc_bsg_rport_els()
712 sg_copy_to_buffer(job->request_payload.sg_list, in lpfc_bsg_rport_els()
713 job->request_payload.sg_cnt, in lpfc_bsg_rport_els()
726 dd_data->set_job = job; in lpfc_bsg_rport_els()
730 job->dd_data = dd_data; in lpfc_bsg_rport_els()
760 job->dd_data = NULL; in lpfc_bsg_rport_els()
774 job->reply->result = rc; in lpfc_bsg_rport_els()
775 job->dd_data = NULL; in lpfc_bsg_rport_els()
921 struct fc_bsg_job *job = NULL; in lpfc_bsg_ct_unsol_event() local
1121 job = dd_data->set_job; in lpfc_bsg_ct_unsol_event()
1124 if (job) { in lpfc_bsg_ct_unsol_event()
1125 job->reply->reply_payload_rcv_len = size; in lpfc_bsg_ct_unsol_event()
1127 job->reply->result = 0; in lpfc_bsg_ct_unsol_event()
1128 job->dd_data = NULL; in lpfc_bsg_ct_unsol_event()
1131 job->job_done(job); in lpfc_bsg_ct_unsol_event()
1192 lpfc_bsg_hba_set_event(struct fc_bsg_job *job) in lpfc_bsg_hba_set_event() argument
1194 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_hba_set_event()
1203 if (job->request_len < in lpfc_bsg_hba_set_event()
1213 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_hba_set_event()
1258 dd_data->set_job = job; /* for unsolicited command */ in lpfc_bsg_hba_set_event()
1259 job->dd_data = dd_data; /* for fc transport timeout callback*/ in lpfc_bsg_hba_set_event()
1267 job->dd_data = NULL; in lpfc_bsg_hba_set_event()
1276 lpfc_bsg_hba_get_event(struct fc_bsg_job *job) in lpfc_bsg_hba_get_event() argument
1278 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_hba_get_event()
1287 if (job->request_len < in lpfc_bsg_hba_get_event()
1297 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_hba_get_event()
1300 job->reply->reply_data.vendor_reply.vendor_rsp; in lpfc_bsg_hba_get_event()
1320 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_hba_get_event()
1325 if (evt_dat->len > job->request_payload.payload_len) { in lpfc_bsg_hba_get_event()
1326 evt_dat->len = job->request_payload.payload_len; in lpfc_bsg_hba_get_event()
1330 job->request_payload.payload_len); in lpfc_bsg_hba_get_event()
1336 job->reply->reply_payload_rcv_len = in lpfc_bsg_hba_get_event()
1337 sg_copy_from_buffer(job->request_payload.sg_list, in lpfc_bsg_hba_get_event()
1338 job->request_payload.sg_cnt, in lpfc_bsg_hba_get_event()
1341 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_hba_get_event()
1351 job->dd_data = NULL; in lpfc_bsg_hba_get_event()
1352 job->reply->result = 0; in lpfc_bsg_hba_get_event()
1353 job->job_done(job); in lpfc_bsg_hba_get_event()
1357 job->dd_data = NULL; in lpfc_bsg_hba_get_event()
1358 job->reply->result = rc; in lpfc_bsg_hba_get_event()
1385 struct fc_bsg_job *job; in lpfc_issue_ct_rsp_cmp() local
1396 job = dd_data->set_job; in lpfc_issue_ct_rsp_cmp()
1397 if (job) { in lpfc_issue_ct_rsp_cmp()
1399 job->dd_data = NULL; in lpfc_issue_ct_rsp_cmp()
1415 if (job) { in lpfc_issue_ct_rsp_cmp()
1433 job->reply->reply_payload_rcv_len = 0; in lpfc_issue_ct_rsp_cmp()
1446 if (job) { in lpfc_issue_ct_rsp_cmp()
1447 job->reply->result = rc; in lpfc_issue_ct_rsp_cmp()
1448 job->job_done(job); in lpfc_issue_ct_rsp_cmp()
1462 lpfc_issue_ct_rsp(struct lpfc_hba *phba, struct fc_bsg_job *job, uint32_t tag, in lpfc_issue_ct_rsp() argument
1563 dd_data->set_job = job; in lpfc_issue_ct_rsp()
1567 job->dd_data = dd_data; in lpfc_issue_ct_rsp()
1593 job->dd_data = NULL; in lpfc_issue_ct_rsp()
1608 lpfc_bsg_send_mgmt_rsp(struct fc_bsg_job *job) in lpfc_bsg_send_mgmt_rsp() argument
1610 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_send_mgmt_rsp()
1613 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_send_mgmt_rsp()
1619 (unsigned long)job->request_payload.payload_len; in lpfc_bsg_send_mgmt_rsp()
1623 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_send_mgmt_rsp()
1645 cmp = lpfc_alloc_bsg_buffers(phba, job->request_payload.payload_len, in lpfc_bsg_send_mgmt_rsp()
1651 lpfc_bsg_copy_data(cmp, &job->request_payload, in lpfc_bsg_send_mgmt_rsp()
1652 job->request_payload.payload_len, 1); in lpfc_bsg_send_mgmt_rsp()
1654 rc = lpfc_issue_ct_rsp(phba, job, tag, cmp, bmp, bpl_entries); in lpfc_bsg_send_mgmt_rsp()
1669 job->reply->result = rc; in lpfc_bsg_send_mgmt_rsp()
1670 job->dd_data = NULL; in lpfc_bsg_send_mgmt_rsp()
1765 lpfc_sli3_bsg_diag_loopback_mode(struct lpfc_hba *phba, struct fc_bsg_job *job) in lpfc_sli3_bsg_diag_loopback_mode() argument
1776 job->reply->reply_payload_rcv_len = 0; in lpfc_sli3_bsg_diag_loopback_mode()
1778 if (job->request_len < sizeof(struct fc_bsg_request) + in lpfc_sli3_bsg_diag_loopback_mode()
1783 job->request_len, in lpfc_sli3_bsg_diag_loopback_mode()
1796 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_sli3_bsg_diag_loopback_mode()
1869 job->reply->result = rc; in lpfc_sli3_bsg_diag_loopback_mode()
1872 job->job_done(job); in lpfc_sli3_bsg_diag_loopback_mode()
2020 lpfc_sli4_bsg_diag_loopback_mode(struct lpfc_hba *phba, struct fc_bsg_job *job) in lpfc_sli4_bsg_diag_loopback_mode() argument
2027 job->reply->reply_payload_rcv_len = 0; in lpfc_sli4_bsg_diag_loopback_mode()
2029 if (job->request_len < sizeof(struct fc_bsg_request) + in lpfc_sli4_bsg_diag_loopback_mode()
2034 job->request_len, in lpfc_sli4_bsg_diag_loopback_mode()
2059 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_sli4_bsg_diag_loopback_mode()
2156 job->reply->result = rc; in lpfc_sli4_bsg_diag_loopback_mode()
2159 job->job_done(job); in lpfc_sli4_bsg_diag_loopback_mode()
2171 lpfc_bsg_diag_loopback_mode(struct fc_bsg_job *job) in lpfc_bsg_diag_loopback_mode() argument
2178 shost = job->shost; in lpfc_bsg_diag_loopback_mode()
2181 vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_diag_loopback_mode()
2189 rc = lpfc_sli3_bsg_diag_loopback_mode(phba, job); in lpfc_bsg_diag_loopback_mode()
2192 rc = lpfc_sli4_bsg_diag_loopback_mode(phba, job); in lpfc_bsg_diag_loopback_mode()
2207 lpfc_sli4_bsg_diag_mode_end(struct fc_bsg_job *job) in lpfc_sli4_bsg_diag_mode_end() argument
2216 shost = job->shost; in lpfc_sli4_bsg_diag_mode_end()
2219 vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_sli4_bsg_diag_mode_end()
2237 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_sli4_bsg_diag_mode_end()
2268 job->reply->result = rc; in lpfc_sli4_bsg_diag_mode_end()
2271 job->job_done(job); in lpfc_sli4_bsg_diag_mode_end()
2283 lpfc_sli4_bsg_link_diag_test(struct fc_bsg_job *job) in lpfc_sli4_bsg_link_diag_test() argument
2297 shost = job->shost; in lpfc_sli4_bsg_link_diag_test()
2302 vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_sli4_bsg_link_diag_test()
2323 if (job->request_len < sizeof(struct fc_bsg_request) + in lpfc_sli4_bsg_link_diag_test()
2328 job->request_len, in lpfc_sli4_bsg_link_diag_test()
2340 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_sli4_bsg_link_diag_test()
2390 job->reply->reply_data.vendor_reply.vendor_rsp; in lpfc_sli4_bsg_link_diag_test()
2392 if (job->reply_len < in lpfc_sli4_bsg_link_diag_test()
2399 job->reply_len); in lpfc_sli4_bsg_link_diag_test()
2418 job->reply->result = rc; in lpfc_sli4_bsg_link_diag_test()
2421 job->job_done(job); in lpfc_sli4_bsg_link_diag_test()
2987 lpfc_bsg_diag_loopback_run(struct fc_bsg_job *job) in lpfc_bsg_diag_loopback_run() argument
2989 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_diag_loopback_run()
3018 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_diag_loopback_run()
3020 if (job->request_len < in lpfc_bsg_diag_loopback_run()
3029 if (job->request_payload.payload_len != in lpfc_bsg_diag_loopback_run()
3030 job->reply_payload.payload_len) { in lpfc_bsg_diag_loopback_run()
3035 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_diag_loopback_run()
3049 size = job->request_payload.payload_len; in lpfc_bsg_diag_loopback_run()
3081 sg_copy_to_buffer(job->request_payload.sg_list, in lpfc_bsg_diag_loopback_run()
3082 job->request_payload.sg_cnt, in lpfc_bsg_diag_loopback_run()
3244 job->reply->reply_payload_rcv_len = in lpfc_bsg_diag_loopback_run()
3245 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_diag_loopback_run()
3246 job->reply_payload.sg_cnt, in lpfc_bsg_diag_loopback_run()
3248 job->reply->reply_payload_rcv_len = size; in lpfc_bsg_diag_loopback_run()
3278 job->reply->result = rc; in lpfc_bsg_diag_loopback_run()
3279 job->dd_data = NULL; in lpfc_bsg_diag_loopback_run()
3282 job->job_done(job); in lpfc_bsg_diag_loopback_run()
3291 lpfc_bsg_get_dfc_rev(struct fc_bsg_job *job) in lpfc_bsg_get_dfc_rev() argument
3293 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_get_dfc_rev()
3299 if (job->request_len < in lpfc_bsg_get_dfc_rev()
3309 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_get_dfc_rev()
3312 job->reply->reply_data.vendor_reply.vendor_rsp; in lpfc_bsg_get_dfc_rev()
3314 if (job->reply_len < in lpfc_bsg_get_dfc_rev()
3326 job->reply->result = rc; in lpfc_bsg_get_dfc_rev()
3328 job->job_done(job); in lpfc_bsg_get_dfc_rev()
3347 struct fc_bsg_job *job; in lpfc_bsg_issue_mbox_cmpl() local
3365 job = dd_data->set_job; in lpfc_bsg_issue_mbox_cmpl()
3366 if (job) { in lpfc_bsg_issue_mbox_cmpl()
3368 job->dd_data = NULL; in lpfc_bsg_issue_mbox_cmpl()
3374 if (job) { in lpfc_bsg_issue_mbox_cmpl()
3375 size = job->reply_payload.payload_len; in lpfc_bsg_issue_mbox_cmpl()
3376 job->reply->reply_payload_rcv_len = in lpfc_bsg_issue_mbox_cmpl()
3377 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_issue_mbox_cmpl()
3378 job->reply_payload.sg_cnt, in lpfc_bsg_issue_mbox_cmpl()
3389 if (job) { in lpfc_bsg_issue_mbox_cmpl()
3390 job->reply->result = 0; in lpfc_bsg_issue_mbox_cmpl()
3391 job->job_done(job); in lpfc_bsg_issue_mbox_cmpl()
3525 struct fc_bsg_job *job; in lpfc_bsg_issue_mbox_ext_handle_job() local
3538 job = dd_data->set_job; in lpfc_bsg_issue_mbox_ext_handle_job()
3539 if (job) { in lpfc_bsg_issue_mbox_ext_handle_job()
3541 job->dd_data = NULL; in lpfc_bsg_issue_mbox_ext_handle_job()
3568 if (job) { in lpfc_bsg_issue_mbox_ext_handle_job()
3569 size = job->reply_payload.payload_len; in lpfc_bsg_issue_mbox_ext_handle_job()
3570 job->reply->reply_payload_rcv_len = in lpfc_bsg_issue_mbox_ext_handle_job()
3571 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_issue_mbox_ext_handle_job()
3572 job->reply_payload.sg_cnt, in lpfc_bsg_issue_mbox_ext_handle_job()
3576 job->reply->result = 0; in lpfc_bsg_issue_mbox_ext_handle_job()
3600 return job; in lpfc_bsg_issue_mbox_ext_handle_job()
3614 struct fc_bsg_job *job; in lpfc_bsg_issue_read_mbox_ext_cmpl() local
3616 job = lpfc_bsg_issue_mbox_ext_handle_job(phba, pmboxq); in lpfc_bsg_issue_read_mbox_ext_cmpl()
3619 if (!job) in lpfc_bsg_issue_read_mbox_ext_cmpl()
3634 if (job) in lpfc_bsg_issue_read_mbox_ext_cmpl()
3635 job->job_done(job); in lpfc_bsg_issue_read_mbox_ext_cmpl()
3651 struct fc_bsg_job *job; in lpfc_bsg_issue_write_mbox_ext_cmpl() local
3653 job = lpfc_bsg_issue_mbox_ext_handle_job(phba, pmboxq); in lpfc_bsg_issue_write_mbox_ext_cmpl()
3656 if (!job) in lpfc_bsg_issue_write_mbox_ext_cmpl()
3669 if (job) in lpfc_bsg_issue_write_mbox_ext_cmpl()
3670 job->job_done(job); in lpfc_bsg_issue_write_mbox_ext_cmpl()
3779 lpfc_bsg_sli_cfg_read_cmd_ext(struct lpfc_hba *phba, struct fc_bsg_job *job, in lpfc_bsg_sli_cfg_read_cmd_ext() argument
3795 (struct dfc_mbox_req *)job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_sli_cfg_read_cmd_ext()
3914 dd_data->set_job = job; in lpfc_bsg_sli_cfg_read_cmd_ext()
3917 job->dd_data = dd_data; in lpfc_bsg_sli_cfg_read_cmd_ext()
3966 lpfc_bsg_sli_cfg_write_cmd_ext(struct lpfc_hba *phba, struct fc_bsg_job *job, in lpfc_bsg_sli_cfg_write_cmd_ext() argument
3980 (struct dfc_mbox_req *)job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_sli_cfg_write_cmd_ext()
4083 dd_data->set_job = job; in lpfc_bsg_sli_cfg_write_cmd_ext()
4086 job->dd_data = dd_data; in lpfc_bsg_sli_cfg_write_cmd_ext()
4107 job->reply->result = 0; in lpfc_bsg_sli_cfg_write_cmd_ext()
4108 job->job_done(job); in lpfc_bsg_sli_cfg_write_cmd_ext()
4130 lpfc_bsg_handle_sli_cfg_mbox(struct lpfc_hba *phba, struct fc_bsg_job *job, in lpfc_bsg_handle_sli_cfg_mbox() argument
4157 rc = lpfc_bsg_sli_cfg_read_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4167 rc = lpfc_bsg_sli_cfg_write_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4186 rc = lpfc_bsg_sli_cfg_read_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4217 rc = lpfc_bsg_sli_cfg_read_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4225 rc = lpfc_bsg_sli_cfg_write_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4278 lpfc_bsg_read_ebuf_get(struct lpfc_hba *phba, struct fc_bsg_job *job) in lpfc_bsg_read_ebuf_get() argument
4317 job->reply->reply_payload_rcv_len = in lpfc_bsg_read_ebuf_get()
4318 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_read_ebuf_get()
4319 job->reply_payload.sg_cnt, in lpfc_bsg_read_ebuf_get()
4331 job->reply->result = 0; in lpfc_bsg_read_ebuf_get()
4332 job->job_done(job); in lpfc_bsg_read_ebuf_get()
4346 lpfc_bsg_write_ebuf_set(struct lpfc_hba *phba, struct fc_bsg_job *job, in lpfc_bsg_write_ebuf_set() argument
4373 size = job->request_payload.payload_len; in lpfc_bsg_write_ebuf_set()
4374 sg_copy_to_buffer(job->request_payload.sg_list, in lpfc_bsg_write_ebuf_set()
4375 job->request_payload.sg_cnt, in lpfc_bsg_write_ebuf_set()
4427 dd_data->set_job = job; in lpfc_bsg_write_ebuf_set()
4430 job->dd_data = dd_data; in lpfc_bsg_write_ebuf_set()
4450 job->reply->result = 0; in lpfc_bsg_write_ebuf_set()
4451 job->job_done(job); in lpfc_bsg_write_ebuf_set()
4471 lpfc_bsg_handle_sli_cfg_ebuf(struct lpfc_hba *phba, struct fc_bsg_job *job, in lpfc_bsg_handle_sli_cfg_ebuf() argument
4489 rc = lpfc_bsg_read_ebuf_get(phba, job); in lpfc_bsg_handle_sli_cfg_ebuf()
4501 rc = lpfc_bsg_write_ebuf_set(phba, job, dmabuf); in lpfc_bsg_handle_sli_cfg_ebuf()
4516 lpfc_bsg_handle_sli_cfg_ext(struct lpfc_hba *phba, struct fc_bsg_job *job, in lpfc_bsg_handle_sli_cfg_ext() argument
4523 (struct dfc_mbox_req *)job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_handle_sli_cfg_ext()
4536 rc = lpfc_bsg_handle_sli_cfg_mbox(phba, job, dmabuf); in lpfc_bsg_handle_sli_cfg_ext()
4559 rc = lpfc_bsg_handle_sli_cfg_ebuf(phba, job, dmabuf); in lpfc_bsg_handle_sli_cfg_ext()
4593 lpfc_bsg_issue_mbox(struct lpfc_hba *phba, struct fc_bsg_job *job, in lpfc_bsg_issue_mbox() argument
4615 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_issue_mbox()
4618 if (job->reply_payload.payload_len > BSG_MBOX_SIZE || in lpfc_bsg_issue_mbox()
4619 job->request_payload.payload_len > BSG_MBOX_SIZE) { in lpfc_bsg_issue_mbox()
4634 (struct dfc_mbox_req *)job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_issue_mbox()
4651 size = job->request_payload.payload_len; in lpfc_bsg_issue_mbox()
4652 sg_copy_to_buffer(job->request_payload.sg_list, in lpfc_bsg_issue_mbox()
4653 job->request_payload.sg_cnt, pmbx, size); in lpfc_bsg_issue_mbox()
4657 rc = lpfc_bsg_handle_sli_cfg_ext(phba, job, dmabuf); in lpfc_bsg_issue_mbox()
4839 dd_data->set_job = job; in lpfc_bsg_issue_mbox()
4846 job->dd_data = dd_data; in lpfc_bsg_issue_mbox()
4858 job->reply->reply_payload_rcv_len = in lpfc_bsg_issue_mbox()
4859 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_issue_mbox()
4860 job->reply_payload.sg_cnt, in lpfc_bsg_issue_mbox()
4887 lpfc_bsg_mbox_cmd(struct fc_bsg_job *job) in lpfc_bsg_mbox_cmd() argument
4889 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_mbox_cmd()
4895 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_mbox_cmd()
4896 if (job->request_len < in lpfc_bsg_mbox_cmd()
4902 (int)(job->request_len - in lpfc_bsg_mbox_cmd()
4906 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_bsg_mbox_cmd()
4911 rc = lpfc_bsg_issue_mbox(phba, job, vport); in lpfc_bsg_mbox_cmd()
4915 job->reply->result = 0; in lpfc_bsg_mbox_cmd()
4916 job->dd_data = NULL; in lpfc_bsg_mbox_cmd()
4917 job->job_done(job); in lpfc_bsg_mbox_cmd()
4923 job->reply->result = rc; in lpfc_bsg_mbox_cmd()
4924 job->dd_data = NULL; in lpfc_bsg_mbox_cmd()
4953 struct fc_bsg_job *job; in lpfc_bsg_menlo_cmd_cmp() local
4971 job = dd_data->set_job; in lpfc_bsg_menlo_cmd_cmp()
4972 if (job) { in lpfc_bsg_menlo_cmd_cmp()
4974 job->dd_data = NULL; in lpfc_bsg_menlo_cmd_cmp()
4980 if (job) { in lpfc_bsg_menlo_cmd_cmp()
4987 job->reply->reply_data.vendor_reply.vendor_rsp; in lpfc_bsg_menlo_cmd_cmp()
5007 job->reply->reply_payload_rcv_len = in lpfc_bsg_menlo_cmd_cmp()
5008 lpfc_bsg_copy_data(rmp, &job->reply_payload, in lpfc_bsg_menlo_cmd_cmp()
5023 if (job) { in lpfc_bsg_menlo_cmd_cmp()
5024 job->reply->result = rc; in lpfc_bsg_menlo_cmd_cmp()
5025 job->job_done(job); in lpfc_bsg_menlo_cmd_cmp()
5041 lpfc_menlo_cmd(struct fc_bsg_job *job) in lpfc_menlo_cmd() argument
5043 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_menlo_cmd()
5057 job->reply->reply_payload_rcv_len = 0; in lpfc_menlo_cmd()
5059 if (job->request_len < in lpfc_menlo_cmd()
5069 if (job->reply_len < in lpfc_menlo_cmd()
5087 job->request->rqst_data.h_vendor.vendor_cmd; in lpfc_menlo_cmd()
5090 job->reply->reply_data.vendor_reply.vendor_rsp; in lpfc_menlo_cmd()
5117 cmp = lpfc_alloc_bsg_buffers(phba, job->request_payload.payload_len, in lpfc_menlo_cmd()
5123 lpfc_bsg_copy_data(cmp, &job->request_payload, in lpfc_menlo_cmd()
5124 job->request_payload.payload_len, 1); in lpfc_menlo_cmd()
5128 rmp = lpfc_alloc_bsg_buffers(phba, job->reply_payload.payload_len, 0, in lpfc_menlo_cmd()
5177 dd_data->set_job = job; in lpfc_menlo_cmd()
5180 job->dd_data = dd_data; in lpfc_menlo_cmd()
5201 job->reply->result = rc; in lpfc_menlo_cmd()
5202 job->dd_data = NULL; in lpfc_menlo_cmd()
5211 lpfc_bsg_hst_vendor(struct fc_bsg_job *job) in lpfc_bsg_hst_vendor() argument
5213 int command = job->request->rqst_data.h_vendor.vendor_cmd[0]; in lpfc_bsg_hst_vendor()
5218 rc = lpfc_bsg_hba_set_event(job); in lpfc_bsg_hst_vendor()
5221 rc = lpfc_bsg_hba_get_event(job); in lpfc_bsg_hst_vendor()
5224 rc = lpfc_bsg_send_mgmt_rsp(job); in lpfc_bsg_hst_vendor()
5227 rc = lpfc_bsg_diag_loopback_mode(job); in lpfc_bsg_hst_vendor()
5230 rc = lpfc_sli4_bsg_diag_mode_end(job); in lpfc_bsg_hst_vendor()
5233 rc = lpfc_bsg_diag_loopback_run(job); in lpfc_bsg_hst_vendor()
5236 rc = lpfc_sli4_bsg_link_diag_test(job); in lpfc_bsg_hst_vendor()
5239 rc = lpfc_bsg_get_dfc_rev(job); in lpfc_bsg_hst_vendor()
5242 rc = lpfc_bsg_mbox_cmd(job); in lpfc_bsg_hst_vendor()
5246 rc = lpfc_menlo_cmd(job); in lpfc_bsg_hst_vendor()
5250 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_hst_vendor()
5252 job->reply->result = rc; in lpfc_bsg_hst_vendor()
5264 lpfc_bsg_request(struct fc_bsg_job *job) in lpfc_bsg_request() argument
5269 msgcode = job->request->msgcode; in lpfc_bsg_request()
5272 rc = lpfc_bsg_hst_vendor(job); in lpfc_bsg_request()
5275 rc = lpfc_bsg_rport_els(job); in lpfc_bsg_request()
5278 rc = lpfc_bsg_send_mgmt_cmd(job); in lpfc_bsg_request()
5282 job->reply->reply_payload_rcv_len = 0; in lpfc_bsg_request()
5284 job->reply->result = rc; in lpfc_bsg_request()
5299 lpfc_bsg_timeout(struct fc_bsg_job *job) in lpfc_bsg_timeout() argument
5301 struct lpfc_vport *vport = (struct lpfc_vport *)job->shost->hostdata; in lpfc_bsg_timeout()
5321 dd_data = (struct bsg_job_data *)job->dd_data; in lpfc_bsg_timeout()
5324 job->dd_data = NULL; in lpfc_bsg_timeout()