Lines Matching defs:hcap

45 static ibt_status_t	ibcm_init_reply_addr(ibcm_hca_info_t *hcap,
150 ibcm_hca_info_t *hcap;
355 if ((hcap = ibcm_find_hca_entry(hca_guid)) == NULL) {
357 "hcap is NULL. Probably hca is not in active state",
365 if ((rdma_in > hcap->hca_max_rdma_in_qp) ||
366 (rdma_out > hcap->hca_max_rdma_out_qp)) {
369 channel, rdma_in, rdma_out, hcap->hca_max_rdma_in_qp,
370 hcap->hca_max_rdma_out_qp);
371 ibcm_dec_hca_acc_cnt(hcap);
378 status = ibt_get_port_state_byguid(hcap->hca_guid, port_no,
383 ibcm_dec_hca_acc_cnt(hcap);
388 status = ibt_index2pkey_byguid(hcap->hca_guid, port_no,
394 ibcm_dec_hca_acc_cnt(hcap);
402 if ((hcap->hca_port_info[port_no - 1].port_ibmf_hdl == NULL) &&
403 ((status = ibcm_hca_reinit_port(hcap, port_no - 1))
408 ibcm_dec_hca_acc_cnt(hcap);
412 ibmf_hdl = hcap->hca_port_info[port_no - 1].port_ibmf_hdl;
431 ibcm_dec_hca_acc_cnt(hcap);
437 status = ibt_get_port_state_byguid(hcap->hca_guid,
444 ibcm_dec_hca_acc_cnt(hcap);
464 if ((status = ibcm_init_reply_addr(hcap, &cm_reply_addr, chan_args,
469 ibcm_dec_hca_acc_cnt(hcap);
483 if ((cm_qp_entry = ibcm_find_qp(hcap, port_no,
487 ibcm_dec_hca_acc_cnt(hcap);
492 if (ibcm_alloc_comid(hcap, &local_comid) != IBCM_SUCCESS) {
494 ibcm_dec_hca_acc_cnt(hcap);
506 ibcm_free_comid(hcap, local_comid);
507 ibcm_dec_hca_acc_cnt(hcap);
518 ibcm_free_comid(hcap, local_comid);
519 ibcm_dec_hca_acc_cnt(hcap);
553 ibcm_free_comid(hcap, local_comid);
554 ibcm_dec_hca_acc_cnt(hcap);
565 rw_enter(&hcap->hca_state_rwlock, RW_WRITER);
567 hcap, &statep);
568 rw_exit(&hcap->hca_state_rwlock);
574 ibcm_inc_hca_res_cnt(hcap);
577 ibcm_dec_hca_acc_cnt(hcap);
684 if (ibcm_override_path_mtu && IBCM_IS_HCA_TAVOR(hcap) &&
736 ibt_ib2usec(hcap->hca_ack_delay)) << 3;
746 hcap->hca_ack_delay);
797 ibt_ib2usec(hcap->hca_ack_delay)) << 3;
822 statep->hcap = hcap;
932 ibcm_init_reply_addr(ibcm_hca_info_t *hcap, ibcm_mad_addr_t *reply_addr,
960 status = ibt_index2pkey_byguid(hcap->hca_guid,
1008 status = ibtl_cm_query_hca_ports_byguid(hcap->hca_guid,
1335 ibcm_hca_info_t *hcap;
1343 hcap = statep->hcap;
1346 if (!IBCM_ACCESS_HCA_OK(hcap)) {
1348 "hcap 0x%p not active", channel, hcap);
1932 ibcm_hca_info_t *hcap;
1951 if ((hcap = ibcm_find_hca_entry(port.hp_hca_guid)) == NULL) {
1952 IBTF_DPRINTF_L2(cmlog, "ibcm_ud_get_dqpn: hcap is NULL");
1963 ibcm_dec_hca_acc_cnt(hcap);
1972 ibcm_dec_hca_acc_cnt(hcap);
1979 if (ibcm_alloc_reqid(hcap, &sidr_entry.srch_req_id) == IBCM_FAILURE) {
1982 ibcm_dec_hca_acc_cnt(hcap);
1986 if ((hcap->hca_port_info[port.hp_port - 1].port_ibmf_hdl == NULL) &&
1987 ((retval = ibcm_hca_reinit_port(hcap, port.hp_port - 1))
1994 ibmf_hdl = hcap->hca_port_info[port.hp_port - 1].port_ibmf_hdl;
1997 if ((cm_qp_entry = ibcm_find_qp(hcap, port.hp_port, ud_pkey)) ==
2001 ibcm_dec_hca_acc_cnt(hcap);
2010 ibcm_dec_hca_acc_cnt(hcap);
2022 rw_enter(&hcap->hca_sidr_list_lock, RW_WRITER);
2024 (void) ibcm_find_sidr_entry(&sidr_entry, hcap, &ud_statep,
2026 rw_exit(&hcap->hca_sidr_list_lock);
2029 ibcm_inc_hca_res_cnt(hcap);
2032 ibcm_dec_hca_acc_cnt(hcap);
2688 ibcm_hca_info_t *hcap;
2711 hcap = ibcm_find_hca_entry(port.hp_hca_guid);
2712 if (hcap == NULL) {
2716 IBTF_DPRINTF_L4(cmlog, "ibt_bind_service: hcap = %p", hcap);
2719 saa_handle = ibcm_get_saa_handle(hcap, port.hp_port);
2723 ibcm_dec_hca_acc_cnt(hcap);
2729 ibcm_dec_hca_acc_cnt(hcap);
2735 ibcm_dec_hca_acc_cnt(hcap);
2746 ibcm_dec_hca_acc_cnt(hcap);
2771 ibcm_dec_hca_acc_cnt(hcap);
2850 ibcm_inc_hca_svc_cnt(hcap);
2851 ibcm_dec_hca_acc_cnt(hcap);
2877 ibcm_dec_hca_acc_cnt(hcap);
2885 ibcm_inc_hca_svc_cnt(hcap);
2886 ibcm_dec_hca_acc_cnt(hcap);
2905 ibcm_hca_info_t *hcap;
2911 hcap = ibcm_find_hca_entry(sbindp->sbind_hcaguid);
2913 /* If there is a service on hca, respective hcap cannot go away */
2914 ASSERT(hcap != NULL);
2939 ibcm_dec_hca_acc_cnt(hcap);
2958 saa_handle = ibcm_get_saa_handle(hcap, port.hp_port);
2996 ibcm_dec_hca_svc_cnt(hcap);
2997 ibcm_dec_hca_acc_cnt(hcap);
3196 ibcm_hca_info_t *hcap;
3268 hcap = NULL;
3273 (hcap = ibcm_find_hca_entry(cm_port.hp_hca_guid)) == NULL) {
3294 saa_handle = ibcm_get_saa_handle(hcap, cm_port.hp_port);
3347 ibcm_dec_hca_acc_cnt(hcap);
3366 new->ar_hcap = hcap;
3372 /* do not call ibcm_dec_hca_acc_cnt(hcap) until deregister */
3499 ibcm_hca_info_t *hcap;
3521 hcap = NULL;
3523 (hcap = ibcm_find_hca_entry(cm_port.hp_hca_guid)) == NULL ||
3524 (saa_handle = ibcm_get_saa_handle(hcap, cm_port.hp_port)) == NULL) {
3525 if (hcap != NULL)
3526 ibcm_dec_hca_acc_cnt(hcap);
3586 ibcm_dec_hca_acc_cnt(hcap);
3694 ibcm_hca_info_t *hcap;
3700 hcap = ibcm_find_hca_entry(sbindp->sbind_hcaguid);
3701 if (hcap == NULL) {
3707 saa_handle = ibcm_get_saa_handle(hcap, sbindp->sbind_port);
3711 ibcm_dec_hca_acc_cnt(hcap);
3748 ibcm_dec_hca_acc_cnt(hcap);
4291 ibcm_hca_info_t *hcap;
4362 hcap = statep->hcap;
4365 if (!IBCM_ACCESS_HCA_OK(hcap))
4371 status = ibt_get_port_state_byguid(hcap->hca_guid, port_no, NULL,
4382 if ((hcap->hca_port_info[port_no - 1].port_ibmf_hdl == NULL) &&
4383 ((status = ibcm_hca_reinit_port(hcap, port_no - 1))
4485 ibt_ib2usec(hcap->hca_ack_delay)) << 3;
4929 ibcm_hca_info_t *hcap;
5028 hcap = ibcm_find_hca_entry(hca_port.hp_hca_guid);
5029 if (hcap == NULL) {
5036 saa_handle = ibcm_get_saa_handle(hcap, hca_port.hp_port);
5121 ibcm_dec_hca_acc_cnt(hcap);
5195 ibcm_hca_info_t *hcap;
5262 hcap = ibcm_find_hca_entry(hca_port.hp_hca_guid);
5263 if (hcap == NULL) {
5269 saa_handle = ibcm_get_saa_handle(hcap, hca_port.hp_port);
5272 ibcm_dec_hca_acc_cnt(hcap);
5298 ibcm_dec_hca_acc_cnt(hcap);
5357 ibcm_hca_info_t *hcap;
5478 hcap = ibcm_find_hca_entry(hport.hp_hca_guid);
5479 if (hcap == NULL) {
5484 saa_handle = ibcm_get_saa_handle(hcap, hport.hp_port);
5487 ibcm_dec_hca_acc_cnt(hcap);
5504 ibcm_dec_hca_acc_cnt(hcap);
5607 ibcm_dec_hca_acc_cnt(hcap);
5658 ibcm_hca_info_t *hcap;
5694 hcap = ibcm_find_hca_entry(hport.hp_hca_guid);
5695 if (hcap == NULL) {
5721 hcap = ibcm_find_hca_entry(guid_array[i]);
5722 if (hcap == NULL) {
5728 num_ports = hcap->hca_num_ports;
5740 saa_handle = ibcm_get_saa_handle(hcap, port);
5758 sgid = hcap->hca_port_info[j].port_sgid0;
5820 ibcm_dec_hca_acc_cnt(hcap);
5863 ibcm_dec_hca_acc_cnt(hcap);
5875 ibcm_dec_hca_acc_cnt(hcap);
5949 ibcm_hca_info_t *hcap;
5976 hcap = ibcm_find_hca_entry(guid_array[i]);
5977 if (hcap == NULL) {
5984 for (j = 0; j < hcap->hca_num_ports; j++) {
5995 saa_handle = ibcm_get_saa_handle(hcap, port);
6018 ibcm_dec_hca_acc_cnt(hcap);
6061 ibcm_dec_hca_acc_cnt(hcap);
6073 ibcm_dec_hca_acc_cnt(hcap);
6101 ibcm_hca_info_t *hcap;
6214 hcap = ibcm_find_hca_entry(guid_array[i]);
6215 if (hcap == NULL) {
6225 for (j = 0; j < hcap->hca_num_ports; j++) {
6237 saa_handle = ibcm_get_saa_handle(hcap, port + 1);
6251 sgid = hcap->hca_port_info[port].port_sgid0;
6289 ibcm_dec_hca_acc_cnt(hcap);
6329 ibcm_dec_hca_acc_cnt(hcap);
6371 ibcm_dec_hca_acc_cnt(hcap);
6436 ibcm_dec_hca_acc_cnt(hcap);
6463 ibcm_dec_hca_acc_cnt(hcap);