Lines Matching refs:job

295 	struct bsg_job *job;  in lpfc_bsg_send_mgmt_cmd_cmp()  local
308 job = dd_data->set_job; in lpfc_bsg_send_mgmt_cmd_cmp()
309 if (job) { in lpfc_bsg_send_mgmt_cmd_cmp()
310 bsg_reply = job->reply; in lpfc_bsg_send_mgmt_cmd_cmp()
312 job->dd_data = NULL; in lpfc_bsg_send_mgmt_cmd_cmp()
332 if (job) { in lpfc_bsg_send_mgmt_cmd_cmp()
351 lpfc_bsg_copy_data(rmp, &job->reply_payload, in lpfc_bsg_send_mgmt_cmd_cmp()
366 if (job) { in lpfc_bsg_send_mgmt_cmd_cmp()
368 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_send_mgmt_cmd_cmp()
379 lpfc_bsg_send_mgmt_cmd(struct bsg_job *job) in lpfc_bsg_send_mgmt_cmd() argument
381 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_send_mgmt_cmd()
382 struct lpfc_rport_data *rdata = fc_bsg_to_rport(job)->dd_data; in lpfc_bsg_send_mgmt_cmd()
385 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_send_mgmt_cmd()
434 cmp = lpfc_alloc_bsg_buffers(phba, job->request_payload.payload_len, in lpfc_bsg_send_mgmt_cmd()
440 lpfc_bsg_copy_data(cmp, &job->request_payload, in lpfc_bsg_send_mgmt_cmd()
441 job->request_payload.payload_len, 1); in lpfc_bsg_send_mgmt_cmd()
445 rmp = lpfc_alloc_bsg_buffers(phba, job->reply_payload.payload_len, 0, in lpfc_bsg_send_mgmt_cmd()
472 dd_data->set_job = job; in lpfc_bsg_send_mgmt_cmd()
475 job->dd_data = dd_data; in lpfc_bsg_send_mgmt_cmd()
527 job->dd_data = NULL; in lpfc_bsg_send_mgmt_cmd()
554 struct bsg_job *job; in lpfc_bsg_rport_els_cmp() local
571 job = dd_data->set_job; in lpfc_bsg_rport_els_cmp()
572 if (job) { in lpfc_bsg_rport_els_cmp()
573 bsg_reply = job->reply; in lpfc_bsg_rport_els_cmp()
575 job->dd_data = NULL; in lpfc_bsg_rport_els_cmp()
594 if (job) { in lpfc_bsg_rport_els_cmp()
598 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_rport_els_cmp()
599 job->reply_payload.sg_cnt, in lpfc_bsg_rport_els_cmp()
629 if (job) { in lpfc_bsg_rport_els_cmp()
631 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_rport_els_cmp()
642 lpfc_bsg_rport_els(struct bsg_job *job) in lpfc_bsg_rport_els() argument
644 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_rport_els()
646 struct lpfc_rport_data *rdata = fc_bsg_to_rport(job)->dd_data; in lpfc_bsg_rport_els()
648 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_rport_els()
649 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_rport_els()
666 if (job->request_payload.payload_len > FCELSSIZE) { in lpfc_bsg_rport_els()
681 cmdsize = job->request_payload.payload_len; in lpfc_bsg_rport_els()
701 sg_copy_to_buffer(job->request_payload.sg_list, in lpfc_bsg_rport_els()
702 job->request_payload.sg_cnt, in lpfc_bsg_rport_els()
718 dd_data->set_job = job; in lpfc_bsg_rport_els()
722 job->dd_data = dd_data; in lpfc_bsg_rport_els()
764 job->dd_data = NULL; in lpfc_bsg_rport_els()
906 struct bsg_job *job = NULL; in lpfc_bsg_ct_unsol_event() local
1093 job = dd_data->set_job; in lpfc_bsg_ct_unsol_event()
1096 if (job) { in lpfc_bsg_ct_unsol_event()
1097 bsg_reply = job->reply; in lpfc_bsg_ct_unsol_event()
1101 job->dd_data = NULL; in lpfc_bsg_ct_unsol_event()
1104 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_ct_unsol_event()
1166 lpfc_bsg_hba_set_event(struct bsg_job *job) in lpfc_bsg_hba_set_event() argument
1168 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_hba_set_event()
1170 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_hba_set_event()
1178 if (job->request_len < in lpfc_bsg_hba_set_event()
1233 dd_data->set_job = job; /* for unsolicited command */ in lpfc_bsg_hba_set_event()
1234 job->dd_data = dd_data; /* for fc transport timeout callback*/ in lpfc_bsg_hba_set_event()
1240 job->dd_data = NULL; in lpfc_bsg_hba_set_event()
1249 lpfc_bsg_hba_get_event(struct bsg_job *job) in lpfc_bsg_hba_get_event() argument
1251 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_hba_get_event()
1253 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_hba_get_event()
1254 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_hba_get_event()
1262 if (job->request_len < in lpfc_bsg_hba_get_event()
1300 if (evt_dat->len > job->request_payload.payload_len) { in lpfc_bsg_hba_get_event()
1301 evt_dat->len = job->request_payload.payload_len; in lpfc_bsg_hba_get_event()
1305 job->request_payload.payload_len); in lpfc_bsg_hba_get_event()
1312 sg_copy_from_buffer(job->request_payload.sg_list, in lpfc_bsg_hba_get_event()
1313 job->request_payload.sg_cnt, in lpfc_bsg_hba_get_event()
1326 job->dd_data = NULL; in lpfc_bsg_hba_get_event()
1328 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_hba_get_event()
1333 job->dd_data = NULL; in lpfc_bsg_hba_get_event()
1361 struct bsg_job *job; in lpfc_issue_ct_rsp_cmp() local
1373 job = dd_data->set_job; in lpfc_issue_ct_rsp_cmp()
1374 if (job) { in lpfc_issue_ct_rsp_cmp()
1376 job->dd_data = NULL; in lpfc_issue_ct_rsp_cmp()
1394 if (job) { in lpfc_issue_ct_rsp_cmp()
1395 bsg_reply = job->reply; in lpfc_issue_ct_rsp_cmp()
1426 if (job) { in lpfc_issue_ct_rsp_cmp()
1428 bsg_job_done(job, bsg_reply->result, in lpfc_issue_ct_rsp_cmp()
1444 lpfc_issue_ct_rsp(struct lpfc_hba *phba, struct bsg_job *job, uint32_t tag, in lpfc_issue_ct_rsp() argument
1521 dd_data->set_job = job; in lpfc_issue_ct_rsp()
1529 job->dd_data = dd_data; in lpfc_issue_ct_rsp()
1554 job->dd_data = NULL; in lpfc_issue_ct_rsp()
1570 lpfc_bsg_send_mgmt_rsp(struct bsg_job *job) in lpfc_bsg_send_mgmt_rsp() argument
1572 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_send_mgmt_rsp()
1574 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_send_mgmt_rsp()
1575 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_send_mgmt_rsp()
1583 (unsigned long)job->request_payload.payload_len; in lpfc_bsg_send_mgmt_rsp()
1609 cmp = lpfc_alloc_bsg_buffers(phba, job->request_payload.payload_len, in lpfc_bsg_send_mgmt_rsp()
1615 lpfc_bsg_copy_data(cmp, &job->request_payload, in lpfc_bsg_send_mgmt_rsp()
1616 job->request_payload.payload_len, 1); in lpfc_bsg_send_mgmt_rsp()
1618 rc = lpfc_issue_ct_rsp(phba, job, tag, cmp, bmp, bpl_entries); in lpfc_bsg_send_mgmt_rsp()
1634 job->dd_data = NULL; in lpfc_bsg_send_mgmt_rsp()
1735 lpfc_sli3_bsg_diag_loopback_mode(struct lpfc_hba *phba, struct bsg_job *job) in lpfc_sli3_bsg_diag_loopback_mode() argument
1737 struct fc_bsg_request *bsg_request = job->request; in lpfc_sli3_bsg_diag_loopback_mode()
1738 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_sli3_bsg_diag_loopback_mode()
1750 if (job->request_len < sizeof(struct fc_bsg_request) + in lpfc_sli3_bsg_diag_loopback_mode()
1755 job->request_len, in lpfc_sli3_bsg_diag_loopback_mode()
1844 bsg_job_done(job, bsg_reply->result, in lpfc_sli3_bsg_diag_loopback_mode()
2001 lpfc_sli4_bsg_diag_loopback_mode(struct lpfc_hba *phba, struct bsg_job *job) in lpfc_sli4_bsg_diag_loopback_mode() argument
2003 struct fc_bsg_request *bsg_request = job->request; in lpfc_sli4_bsg_diag_loopback_mode()
2004 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_sli4_bsg_diag_loopback_mode()
2012 if (job->request_len < sizeof(struct fc_bsg_request) + in lpfc_sli4_bsg_diag_loopback_mode()
2017 job->request_len, in lpfc_sli4_bsg_diag_loopback_mode()
2206 bsg_job_done(job, bsg_reply->result, in lpfc_sli4_bsg_diag_loopback_mode()
2219 lpfc_bsg_diag_loopback_mode(struct bsg_job *job) in lpfc_bsg_diag_loopback_mode() argument
2226 shost = fc_bsg_to_shost(job); in lpfc_bsg_diag_loopback_mode()
2237 rc = lpfc_sli3_bsg_diag_loopback_mode(phba, job); in lpfc_bsg_diag_loopback_mode()
2240 rc = lpfc_sli4_bsg_diag_loopback_mode(phba, job); in lpfc_bsg_diag_loopback_mode()
2255 lpfc_sli4_bsg_diag_mode_end(struct bsg_job *job) in lpfc_sli4_bsg_diag_mode_end() argument
2257 struct fc_bsg_request *bsg_request = job->request; in lpfc_sli4_bsg_diag_mode_end()
2258 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_sli4_bsg_diag_mode_end()
2266 shost = fc_bsg_to_shost(job); in lpfc_sli4_bsg_diag_mode_end()
2321 bsg_job_done(job, bsg_reply->result, in lpfc_sli4_bsg_diag_mode_end()
2334 lpfc_sli4_bsg_link_diag_test(struct bsg_job *job) in lpfc_sli4_bsg_link_diag_test() argument
2336 struct fc_bsg_request *bsg_request = job->request; in lpfc_sli4_bsg_link_diag_test()
2337 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_sli4_bsg_link_diag_test()
2350 shost = fc_bsg_to_shost(job); in lpfc_sli4_bsg_link_diag_test()
2370 if (job->request_len < sizeof(struct fc_bsg_request) + in lpfc_sli4_bsg_link_diag_test()
2375 job->request_len, in lpfc_sli4_bsg_link_diag_test()
2440 if (job->reply_len < sizeof(*bsg_reply) + sizeof(*diag_status_reply)) { in lpfc_sli4_bsg_link_diag_test()
2446 job->reply_len); in lpfc_sli4_bsg_link_diag_test()
2470 bsg_job_done(job, bsg_reply->result, in lpfc_sli4_bsg_link_diag_test()
3022 lpfc_bsg_diag_loopback_run(struct bsg_job *job) in lpfc_bsg_diag_loopback_run() argument
3024 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_diag_loopback_run()
3025 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_diag_loopback_run()
3055 if (job->request_len < in lpfc_bsg_diag_loopback_run()
3064 if (job->request_payload.payload_len != in lpfc_bsg_diag_loopback_run()
3065 job->reply_payload.payload_len) { in lpfc_bsg_diag_loopback_run()
3082 size = job->request_payload.payload_len; in lpfc_bsg_diag_loopback_run()
3114 sg_copy_to_buffer(job->request_payload.sg_list, in lpfc_bsg_diag_loopback_run()
3115 job->request_payload.sg_cnt, in lpfc_bsg_diag_loopback_run()
3273 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_diag_loopback_run()
3274 job->reply_payload.sg_cnt, in lpfc_bsg_diag_loopback_run()
3307 job->dd_data = NULL; in lpfc_bsg_diag_loopback_run()
3310 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_diag_loopback_run()
3320 lpfc_bsg_get_dfc_rev(struct bsg_job *job) in lpfc_bsg_get_dfc_rev() argument
3322 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_get_dfc_rev()
3323 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_get_dfc_rev()
3328 if (job->request_len < in lpfc_bsg_get_dfc_rev()
3340 if (job->reply_len < sizeof(*bsg_reply) + sizeof(*event_reply)) { in lpfc_bsg_get_dfc_rev()
3353 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_get_dfc_rev()
3374 struct bsg_job *job; in lpfc_bsg_issue_mbox_cmpl() local
3392 job = dd_data->set_job; in lpfc_bsg_issue_mbox_cmpl()
3393 if (job) { in lpfc_bsg_issue_mbox_cmpl()
3395 job->dd_data = NULL; in lpfc_bsg_issue_mbox_cmpl()
3401 if (job) { in lpfc_bsg_issue_mbox_cmpl()
3402 bsg_reply = job->reply; in lpfc_bsg_issue_mbox_cmpl()
3403 size = job->reply_payload.payload_len; in lpfc_bsg_issue_mbox_cmpl()
3405 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_issue_mbox_cmpl()
3406 job->reply_payload.sg_cnt, in lpfc_bsg_issue_mbox_cmpl()
3417 if (job) { in lpfc_bsg_issue_mbox_cmpl()
3419 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_issue_mbox_cmpl()
3546 struct bsg_job *job; in lpfc_bsg_issue_mbox_ext_handle_job() local
3560 job = dd_data->set_job; in lpfc_bsg_issue_mbox_ext_handle_job()
3561 if (job) { in lpfc_bsg_issue_mbox_ext_handle_job()
3562 bsg_reply = job->reply; in lpfc_bsg_issue_mbox_ext_handle_job()
3564 job->dd_data = NULL; in lpfc_bsg_issue_mbox_ext_handle_job()
3591 if (job) { in lpfc_bsg_issue_mbox_ext_handle_job()
3592 size = job->reply_payload.payload_len; in lpfc_bsg_issue_mbox_ext_handle_job()
3594 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_issue_mbox_ext_handle_job()
3595 job->reply_payload.sg_cnt, in lpfc_bsg_issue_mbox_ext_handle_job()
3623 return job; in lpfc_bsg_issue_mbox_ext_handle_job()
3637 struct bsg_job *job; in lpfc_bsg_issue_read_mbox_ext_cmpl() local
3640 job = lpfc_bsg_issue_mbox_ext_handle_job(phba, pmboxq); in lpfc_bsg_issue_read_mbox_ext_cmpl()
3643 if (!job) in lpfc_bsg_issue_read_mbox_ext_cmpl()
3658 if (job) { in lpfc_bsg_issue_read_mbox_ext_cmpl()
3659 bsg_reply = job->reply; in lpfc_bsg_issue_read_mbox_ext_cmpl()
3660 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_issue_read_mbox_ext_cmpl()
3677 struct bsg_job *job; in lpfc_bsg_issue_write_mbox_ext_cmpl() local
3680 job = lpfc_bsg_issue_mbox_ext_handle_job(phba, pmboxq); in lpfc_bsg_issue_write_mbox_ext_cmpl()
3683 if (!job) in lpfc_bsg_issue_write_mbox_ext_cmpl()
3696 if (job) { in lpfc_bsg_issue_write_mbox_ext_cmpl()
3697 bsg_reply = job->reply; in lpfc_bsg_issue_write_mbox_ext_cmpl()
3698 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_issue_write_mbox_ext_cmpl()
3809 lpfc_bsg_sli_cfg_read_cmd_ext(struct lpfc_hba *phba, struct bsg_job *job, in lpfc_bsg_sli_cfg_read_cmd_ext() argument
3813 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_sli_cfg_read_cmd_ext()
3945 dd_data->set_job = job; in lpfc_bsg_sli_cfg_read_cmd_ext()
3948 job->dd_data = dd_data; in lpfc_bsg_sli_cfg_read_cmd_ext()
3998 lpfc_bsg_sli_cfg_write_cmd_ext(struct lpfc_hba *phba, struct bsg_job *job, in lpfc_bsg_sli_cfg_write_cmd_ext() argument
4002 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_sli_cfg_write_cmd_ext()
4003 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_sli_cfg_write_cmd_ext()
4117 dd_data->set_job = job; in lpfc_bsg_sli_cfg_write_cmd_ext()
4120 job->dd_data = dd_data; in lpfc_bsg_sli_cfg_write_cmd_ext()
4142 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_sli_cfg_write_cmd_ext()
4165 lpfc_bsg_handle_sli_cfg_mbox(struct lpfc_hba *phba, struct bsg_job *job, in lpfc_bsg_handle_sli_cfg_mbox() argument
4192 rc = lpfc_bsg_sli_cfg_read_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4202 rc = lpfc_bsg_sli_cfg_write_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4223 rc = lpfc_bsg_sli_cfg_read_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4254 rc = lpfc_bsg_sli_cfg_read_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4262 rc = lpfc_bsg_sli_cfg_write_cmd_ext(phba, job, in lpfc_bsg_handle_sli_cfg_mbox()
4315 lpfc_bsg_read_ebuf_get(struct lpfc_hba *phba, struct bsg_job *job) in lpfc_bsg_read_ebuf_get() argument
4317 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_read_ebuf_get()
4356 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_read_ebuf_get()
4357 job->reply_payload.sg_cnt, in lpfc_bsg_read_ebuf_get()
4370 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_read_ebuf_get()
4386 lpfc_bsg_write_ebuf_set(struct lpfc_hba *phba, struct bsg_job *job, in lpfc_bsg_write_ebuf_set() argument
4389 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_write_ebuf_set()
4404 size = job->request_payload.payload_len; in lpfc_bsg_write_ebuf_set()
4405 sg_copy_to_buffer(job->request_payload.sg_list, in lpfc_bsg_write_ebuf_set()
4406 job->request_payload.sg_cnt, in lpfc_bsg_write_ebuf_set()
4465 dd_data->set_job = job; in lpfc_bsg_write_ebuf_set()
4468 job->dd_data = dd_data; in lpfc_bsg_write_ebuf_set()
4489 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_write_ebuf_set()
4512 lpfc_bsg_handle_sli_cfg_ebuf(struct lpfc_hba *phba, struct bsg_job *job, in lpfc_bsg_handle_sli_cfg_ebuf() argument
4530 rc = lpfc_bsg_read_ebuf_get(phba, job); in lpfc_bsg_handle_sli_cfg_ebuf()
4542 rc = lpfc_bsg_write_ebuf_set(phba, job, dmabuf); in lpfc_bsg_handle_sli_cfg_ebuf()
4557 lpfc_bsg_handle_sli_cfg_ext(struct lpfc_hba *phba, struct bsg_job *job, in lpfc_bsg_handle_sli_cfg_ext() argument
4560 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_handle_sli_cfg_ext()
4578 rc = lpfc_bsg_handle_sli_cfg_mbox(phba, job, dmabuf); in lpfc_bsg_handle_sli_cfg_ext()
4601 rc = lpfc_bsg_handle_sli_cfg_ebuf(phba, job, dmabuf); in lpfc_bsg_handle_sli_cfg_ext()
4635 lpfc_bsg_issue_mbox(struct lpfc_hba *phba, struct bsg_job *job, in lpfc_bsg_issue_mbox() argument
4638 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_issue_mbox()
4639 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_issue_mbox()
4661 if (job->reply_payload.payload_len > BSG_MBOX_SIZE || in lpfc_bsg_issue_mbox()
4662 job->request_payload.payload_len > BSG_MBOX_SIZE) { in lpfc_bsg_issue_mbox()
4694 size = job->request_payload.payload_len; in lpfc_bsg_issue_mbox()
4695 sg_copy_to_buffer(job->request_payload.sg_list, in lpfc_bsg_issue_mbox()
4696 job->request_payload.sg_cnt, pmbx, size); in lpfc_bsg_issue_mbox()
4700 rc = lpfc_bsg_handle_sli_cfg_ext(phba, job, dmabuf); in lpfc_bsg_issue_mbox()
4880 dd_data->set_job = job; in lpfc_bsg_issue_mbox()
4887 job->dd_data = dd_data; in lpfc_bsg_issue_mbox()
4900 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_issue_mbox()
4901 job->reply_payload.sg_cnt, in lpfc_bsg_issue_mbox()
4928 lpfc_bsg_mbox_cmd(struct bsg_job *job) in lpfc_bsg_mbox_cmd() argument
4930 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_mbox_cmd()
4931 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_mbox_cmd()
4932 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_mbox_cmd()
4939 if (job->request_len < in lpfc_bsg_mbox_cmd()
4945 (int)(job->request_len - in lpfc_bsg_mbox_cmd()
4954 rc = lpfc_bsg_issue_mbox(phba, job, vport); in lpfc_bsg_mbox_cmd()
4959 job->dd_data = NULL; in lpfc_bsg_mbox_cmd()
4960 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_mbox_cmd()
4968 job->dd_data = NULL; in lpfc_bsg_mbox_cmd()
4975 lpfc_forced_link_speed(struct bsg_job *job) in lpfc_forced_link_speed() argument
4977 struct Scsi_Host *shost = fc_bsg_to_shost(job); in lpfc_forced_link_speed()
4980 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_forced_link_speed()
4984 if (job->request_len < in lpfc_forced_link_speed()
4997 if (job->reply_len < sizeof(*bsg_reply) + sizeof(*forced_reply)) { in lpfc_forced_link_speed()
5011 bsg_job_done(job, bsg_reply->result, in lpfc_forced_link_speed()
5044 lpfc_bsg_get_ras_config(struct bsg_job *job) in lpfc_bsg_get_ras_config() argument
5046 struct Scsi_Host *shost = fc_bsg_to_shost(job); in lpfc_bsg_get_ras_config()
5048 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_get_ras_config()
5054 if (job->request_len < in lpfc_bsg_get_ras_config()
5089 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_get_ras_config()
5101 lpfc_bsg_set_ras_config(struct bsg_job *job) in lpfc_bsg_set_ras_config() argument
5103 struct Scsi_Host *shost = fc_bsg_to_shost(job); in lpfc_bsg_set_ras_config()
5107 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_set_ras_config()
5109 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_set_ras_config()
5113 if (job->request_len < in lpfc_bsg_set_ras_config()
5175 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_set_ras_config()
5189 lpfc_bsg_get_ras_lwpd(struct bsg_job *job) in lpfc_bsg_get_ras_lwpd() argument
5191 struct Scsi_Host *shost = fc_bsg_to_shost(job); in lpfc_bsg_get_ras_lwpd()
5196 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_get_ras_lwpd()
5204 if (job->request_len < in lpfc_bsg_get_ras_lwpd()
5237 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_get_ras_lwpd()
5250 lpfc_bsg_get_ras_fwlog(struct bsg_job *job) in lpfc_bsg_get_ras_fwlog() argument
5252 struct Scsi_Host *shost = fc_bsg_to_shost(job); in lpfc_bsg_get_ras_fwlog()
5255 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_get_ras_fwlog()
5256 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_get_ras_fwlog()
5279 if (job->request_len < in lpfc_bsg_get_ras_fwlog()
5315 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_bsg_get_ras_fwlog()
5316 job->reply_payload.sg_cnt, in lpfc_bsg_get_ras_fwlog()
5324 bsg_job_done(job, bsg_reply->result, in lpfc_bsg_get_ras_fwlog()
5331 lpfc_get_trunk_info(struct bsg_job *job) in lpfc_get_trunk_info() argument
5333 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_get_trunk_info()
5335 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_get_trunk_info()
5339 if (job->request_len < in lpfc_get_trunk_info()
5351 if (job->reply_len < sizeof(*bsg_reply) + sizeof(*event_reply)) { in lpfc_get_trunk_info()
5396 bsg_job_done(job, bsg_reply->result, in lpfc_get_trunk_info()
5403 lpfc_get_cgnbuf_info(struct bsg_job *job) in lpfc_get_cgnbuf_info() argument
5405 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_get_cgnbuf_info()
5407 struct fc_bsg_request *bsg_request = job->request; in lpfc_get_cgnbuf_info()
5408 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_get_cgnbuf_info()
5415 if (job->request_len < sizeof(struct fc_bsg_request) + in lpfc_get_cgnbuf_info()
5471 sg_copy_from_buffer(job->reply_payload.sg_list, in lpfc_get_cgnbuf_info()
5472 job->reply_payload.sg_cnt, in lpfc_get_cgnbuf_info()
5480 bsg_job_done(job, bsg_reply->result, in lpfc_get_cgnbuf_info()
5493 lpfc_bsg_hst_vendor(struct bsg_job *job) in lpfc_bsg_hst_vendor() argument
5495 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_hst_vendor()
5496 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_hst_vendor()
5502 rc = lpfc_bsg_hba_set_event(job); in lpfc_bsg_hst_vendor()
5505 rc = lpfc_bsg_hba_get_event(job); in lpfc_bsg_hst_vendor()
5508 rc = lpfc_bsg_send_mgmt_rsp(job); in lpfc_bsg_hst_vendor()
5511 rc = lpfc_bsg_diag_loopback_mode(job); in lpfc_bsg_hst_vendor()
5514 rc = lpfc_sli4_bsg_diag_mode_end(job); in lpfc_bsg_hst_vendor()
5517 rc = lpfc_bsg_diag_loopback_run(job); in lpfc_bsg_hst_vendor()
5520 rc = lpfc_sli4_bsg_link_diag_test(job); in lpfc_bsg_hst_vendor()
5523 rc = lpfc_bsg_get_dfc_rev(job); in lpfc_bsg_hst_vendor()
5526 rc = lpfc_bsg_mbox_cmd(job); in lpfc_bsg_hst_vendor()
5529 rc = lpfc_forced_link_speed(job); in lpfc_bsg_hst_vendor()
5532 rc = lpfc_bsg_get_ras_lwpd(job); in lpfc_bsg_hst_vendor()
5535 rc = lpfc_bsg_get_ras_fwlog(job); in lpfc_bsg_hst_vendor()
5538 rc = lpfc_bsg_get_ras_config(job); in lpfc_bsg_hst_vendor()
5541 rc = lpfc_bsg_set_ras_config(job); in lpfc_bsg_hst_vendor()
5544 rc = lpfc_get_trunk_info(job); in lpfc_bsg_hst_vendor()
5547 rc = lpfc_get_cgnbuf_info(job); in lpfc_bsg_hst_vendor()
5565 lpfc_bsg_request(struct bsg_job *job) in lpfc_bsg_request() argument
5567 struct fc_bsg_request *bsg_request = job->request; in lpfc_bsg_request()
5568 struct fc_bsg_reply *bsg_reply = job->reply; in lpfc_bsg_request()
5575 rc = lpfc_bsg_hst_vendor(job); in lpfc_bsg_request()
5578 rc = lpfc_bsg_rport_els(job); in lpfc_bsg_request()
5581 rc = lpfc_bsg_send_mgmt_cmd(job); in lpfc_bsg_request()
5602 lpfc_bsg_timeout(struct bsg_job *job) in lpfc_bsg_timeout() argument
5604 struct lpfc_vport *vport = shost_priv(fc_bsg_to_shost(job)); in lpfc_bsg_timeout()
5628 dd_data = (struct bsg_job_data *)job->dd_data; in lpfc_bsg_timeout()
5631 job->dd_data = NULL; in lpfc_bsg_timeout()