• Home
  • Raw
  • Download

Lines Matching refs:timewait_info

214 	struct cm_timewait_info *timewait_info;  member
570 *timewait_info) in cm_insert_remote_id() argument
575 __be64 remote_ca_guid = timewait_info->remote_ca_guid; in cm_insert_remote_id()
576 __be32 remote_id = timewait_info->work.remote_id; in cm_insert_remote_id()
593 timewait_info->inserted_remote_id = 1; in cm_insert_remote_id()
594 rb_link_node(&timewait_info->remote_id_node, parent, link); in cm_insert_remote_id()
595 rb_insert_color(&timewait_info->remote_id_node, &cm.remote_id_table); in cm_insert_remote_id()
603 struct cm_timewait_info *timewait_info; in cm_find_remote_id() local
606 timewait_info = rb_entry(node, struct cm_timewait_info, in cm_find_remote_id()
608 if (be32_lt(remote_id, timewait_info->work.remote_id)) in cm_find_remote_id()
610 else if (be32_gt(remote_id, timewait_info->work.remote_id)) in cm_find_remote_id()
612 else if (be64_lt(remote_ca_guid, timewait_info->remote_ca_guid)) in cm_find_remote_id()
614 else if (be64_gt(remote_ca_guid, timewait_info->remote_ca_guid)) in cm_find_remote_id()
617 return timewait_info; in cm_find_remote_id()
623 *timewait_info) in cm_insert_remote_qpn() argument
628 __be64 remote_ca_guid = timewait_info->remote_ca_guid; in cm_insert_remote_qpn()
629 __be32 remote_qpn = timewait_info->remote_qpn; in cm_insert_remote_qpn()
646 timewait_info->inserted_remote_qp = 1; in cm_insert_remote_qpn()
647 rb_link_node(&timewait_info->remote_qp_node, parent, link); in cm_insert_remote_qpn()
648 rb_insert_color(&timewait_info->remote_qp_node, &cm.remote_qp_table); in cm_insert_remote_qpn()
773 static void cm_cleanup_timewait(struct cm_timewait_info *timewait_info) in cm_cleanup_timewait() argument
775 if (timewait_info->inserted_remote_id) { in cm_cleanup_timewait()
776 rb_erase(&timewait_info->remote_id_node, &cm.remote_id_table); in cm_cleanup_timewait()
777 timewait_info->inserted_remote_id = 0; in cm_cleanup_timewait()
780 if (timewait_info->inserted_remote_qp) { in cm_cleanup_timewait()
781 rb_erase(&timewait_info->remote_qp_node, &cm.remote_qp_table); in cm_cleanup_timewait()
782 timewait_info->inserted_remote_qp = 0; in cm_cleanup_timewait()
788 struct cm_timewait_info *timewait_info; in cm_create_timewait_info() local
790 timewait_info = kzalloc(sizeof *timewait_info, GFP_KERNEL); in cm_create_timewait_info()
791 if (!timewait_info) in cm_create_timewait_info()
794 timewait_info->work.local_id = local_id; in cm_create_timewait_info()
795 INIT_DELAYED_WORK(&timewait_info->work.work, cm_work_handler); in cm_create_timewait_info()
796 timewait_info->work.cm_event.event = IB_CM_TIMEWAIT_EXIT; in cm_create_timewait_info()
797 return timewait_info; in cm_create_timewait_info()
806 cm_cleanup_timewait(cm_id_priv->timewait_info); in cm_enter_timewait()
807 list_add_tail(&cm_id_priv->timewait_info->list, &cm.timewait_list); in cm_enter_timewait()
817 queue_delayed_work(cm.wq, &cm_id_priv->timewait_info->work.work, in cm_enter_timewait()
819 cm_id_priv->timewait_info = NULL; in cm_enter_timewait()
827 if (cm_id_priv->timewait_info) { in cm_reset_to_idle()
829 cm_cleanup_timewait(cm_id_priv->timewait_info); in cm_reset_to_idle()
831 kfree(cm_id_priv->timewait_info); in cm_reset_to_idle()
832 cm_id_priv->timewait_info = NULL; in cm_reset_to_idle()
1128 cm_id_priv->timewait_info = cm_create_timewait_info(cm_id_priv-> in ib_send_cm_req()
1130 if (IS_ERR(cm_id_priv->timewait_info)) { in ib_send_cm_req()
1131 ret = PTR_ERR(cm_id_priv->timewait_info); in ib_send_cm_req()
1183 error1: kfree(cm_id_priv->timewait_info); in ib_send_cm_req()
1439 struct cm_timewait_info *timewait_info; in cm_match_req() local
1446 timewait_info = cm_insert_remote_id(cm_id_priv->timewait_info); in cm_match_req()
1447 if (timewait_info) { in cm_match_req()
1448 cur_cm_id_priv = cm_get_id(timewait_info->work.local_id, in cm_match_req()
1449 timewait_info->work.remote_id); in cm_match_req()
1459 timewait_info = cm_insert_remote_qpn(cm_id_priv->timewait_info); in cm_match_req()
1460 if (timewait_info) { in cm_match_req()
1461 cm_cleanup_timewait(cm_id_priv->timewait_info); in cm_match_req()
1474 cm_cleanup_timewait(cm_id_priv->timewait_info); in cm_match_req()
1536 cm_id_priv->timewait_info = cm_create_timewait_info(cm_id_priv-> in cm_req_handler()
1538 if (IS_ERR(cm_id_priv->timewait_info)) { in cm_req_handler()
1539 ret = PTR_ERR(cm_id_priv->timewait_info); in cm_req_handler()
1542 cm_id_priv->timewait_info->work.remote_id = req_msg->local_comm_id; in cm_req_handler()
1543 cm_id_priv->timewait_info->remote_ca_guid = req_msg->local_ca_guid; in cm_req_handler()
1544 cm_id_priv->timewait_info->remote_qpn = cm_req_get_local_qpn(req_msg); in cm_req_handler()
1549 kfree(cm_id_priv->timewait_info); in cm_req_handler()
1838 cm_id_priv->timewait_info->work.remote_id = rep_msg->local_comm_id; in cm_rep_handler()
1839 cm_id_priv->timewait_info->remote_ca_guid = rep_msg->local_ca_guid; in cm_rep_handler()
1840 cm_id_priv->timewait_info->remote_qpn = cm_rep_get_qpn(rep_msg, cm_id_priv->qp_type); in cm_rep_handler()
1844 if (cm_insert_remote_id(cm_id_priv->timewait_info)) { in cm_rep_handler()
1851 if (cm_insert_remote_qpn(cm_id_priv->timewait_info)) { in cm_rep_handler()
1852 rb_erase(&cm_id_priv->timewait_info->remote_id_node, in cm_rep_handler()
1854 cm_id_priv->timewait_info->inserted_remote_id = 0; in cm_rep_handler()
2309 struct cm_timewait_info *timewait_info; in cm_acquire_rejected_id() local
2317 timewait_info = cm_find_remote_id( *((__be64 *) rej_msg->ari), in cm_acquire_rejected_id()
2319 if (!timewait_info) { in cm_acquire_rejected_id()
2324 (timewait_info->work.local_id ^ in cm_acquire_rejected_id()
2865 struct cm_timewait_info *timewait_info; in cm_timewait_handler() local
2869 timewait_info = (struct cm_timewait_info *)work; in cm_timewait_handler()
2871 list_del(&timewait_info->list); in cm_timewait_handler()
2874 cm_id_priv = cm_acquire_id(timewait_info->work.local_id, in cm_timewait_handler()
2875 timewait_info->work.remote_id); in cm_timewait_handler()
2881 cm_id_priv->remote_qpn != timewait_info->remote_qpn) { in cm_timewait_handler()
3878 struct cm_timewait_info *timewait_info, *tmp; in ib_cm_cleanup() local
3881 list_for_each_entry(timewait_info, &cm.timewait_list, list) in ib_cm_cleanup()
3882 cancel_delayed_work(&timewait_info->work.work); in ib_cm_cleanup()
3888 list_for_each_entry_safe(timewait_info, tmp, &cm.timewait_list, list) { in ib_cm_cleanup()
3889 list_del(&timewait_info->list); in ib_cm_cleanup()
3890 kfree(timewait_info); in ib_cm_cleanup()