Home
last modified time | relevance | path

Searched refs:p_node (Results 1 – 25 of 64) sorted by relevance

123

/freebsd/contrib/ofed/opensm/opensm/
H A Dosm_node.c54 void osm_node_init_physp(IN osm_node_t * p_node, uint8_t port_num, in osm_node_init_physp() argument
66 CL_ASSERT(port_num < p_node->physp_tbl_size); in osm_node_init_physp()
68 osm_physp_init(&p_node->physp_table[port_num], in osm_node_init_physp()
69 port_guid, port_num, p_node, in osm_node_init_physp()
76 osm_node_t *p_node; in osm_node_new() local
94 p_node = malloc(sizeof(*p_node) + sizeof(osm_physp_t) * size); in osm_node_new()
95 if (!p_node) in osm_node_new()
98 memset(p_node, 0, sizeof(*p_node) + sizeof(osm_physp_t) * size); in osm_node_new()
99 p_node->node_info = *p_ni; in osm_node_new()
100 p_node->physp_tbl_size = size + 1; in osm_node_new()
[all …]
H A Dosm_drop_mgr.c118 if (!p_remote_physp->p_node->sw && in drop_mgr_clean_physp()
125 (p_remote_physp->p_node)), in drop_mgr_clean_physp()
134 cl_ntoh64(osm_node_get_node_guid(p_physp->p_node)), in drop_mgr_clean_physp()
137 (p_remote_physp->p_node)), in drop_mgr_clean_physp()
149 p_physp->p_node->physp_discovered[p_physp->port_num] = 0; in drop_mgr_clean_physp()
153 cl_ntoh64(osm_node_get_node_guid(p_physp->p_node)), in drop_mgr_clean_physp()
170 osm_node_t *p_node; in drop_mgr_remove_port() local
291 p_node = p_port->p_node; in drop_mgr_remove_port()
300 p_node ? p_node->print_desc : "UNKNOWN"); in drop_mgr_remove_port()
306 static void drop_mgr_remove_switch(osm_sm_t * sm, IN osm_node_t * p_node) in drop_mgr_remove_switch() argument
[all …]
H A Dosm_node_info_rcv.c83 cl_ntoh64(p_physp->p_node->node_info.node_guid), in report_duplicated_guid()
85 p_old ? cl_ntoh64(p_old->p_node->node_info.node_guid) : 0, in report_duplicated_guid()
87 p_new ? cl_ntoh64(p_new->p_node->node_info.node_guid) : 0, in report_duplicated_guid()
123 p_physp->p_remote_physp->p_node->node_info.port_guid; in requery_dup_node_info()
125 context.ni_context.dup_node_guid = p_physp->p_node->node_info.node_guid; in requery_dup_node_info()
141 static void ni_rcv_set_links(IN osm_sm_t * sm, osm_node_t * p_node, in ni_rcv_set_links() argument
158 cl_ntoh64(osm_node_get_node_guid(p_node))); in ni_rcv_set_links()
173 CL_ASSERT(osm_node_link_has_valid_ports(p_node, port_num, in ni_rcv_set_links()
177 if (osm_node_link_exists(p_node, port_num, in ni_rcv_set_links()
183 p_physp = osm_node_get_physp_ptr(p_node, port_num); in ni_rcv_set_links()
[all …]
H A Dosm_port_info_rcv.c206 IN osm_node_t * p_node, in pi_rcv_process_switch_port0() argument
225 if (p_node->sw && in pi_rcv_process_switch_port0()
226 !ib_switch_info_is_enhanced_port0(&p_node->sw->switch_info)) in pi_rcv_process_switch_port0()
231 num_ports = osm_node_get_num_physp(p_node); in pi_rcv_process_switch_port0()
233 context.pi_context.node_guid = osm_node_get_node_guid(p_node); in pi_rcv_process_switch_port0()
260 IN osm_node_t * p_node, in pi_rcv_process_switch_ext_port() argument
286 ib_node_info_get_vendor_id(&p_node->node_info), in pi_rcv_process_switch_ext_port()
287 p_node->node_info.device_id); in pi_rcv_process_switch_ext_port()
307 (p_node)), port_num, in pi_rcv_process_switch_ext_port()
317 osm_node_unlink(p_node, (uint8_t) port_num, in pi_rcv_process_switch_ext_port()
[all …]
H A Dosm_dump.c66 osm_node_t *p_node; in dump_ucast_path_distribution() local
74 p_node = p_sw->p_node; in dump_ucast_path_distribution()
79 cl_ntoh64(osm_node_get_node_guid(p_node))); in dump_ucast_path_distribution()
89 p_remote_node = osm_node_get_remote_node(p_node, i, NULL); in dump_ucast_path_distribution()
119 const osm_node_t *p_node; in dump_ucast_routes() local
132 p_node = p_sw->p_node; in dump_ucast_routes()
138 cl_ntoh64(osm_node_get_node_guid(p_node))); in dump_ucast_routes()
170 if (p_port->p_node->sw) { in dump_ucast_routes()
173 base_lid = osm_node_get_base_lid(p_port->p_node, 0); in dump_ucast_routes()
189 !p_physp->p_remote_physp->p_node->sw) in dump_ucast_routes()
[all …]
H A Dosm_node_desc_rcv.c61 static void nd_rcv_process_nd(IN osm_sm_t * sm, IN osm_node_t * p_node, in nd_rcv_process_nd() argument
69 memcpy(&p_node->node_desc.description, p_nd, sizeof(*p_nd)); in nd_rcv_process_nd()
75 cl_ntoh64(osm_node_get_node_guid(p_node)), in nd_rcv_process_nd()
79 if (p_node->print_desc) in nd_rcv_process_nd()
80 free(p_node->print_desc); in nd_rcv_process_nd()
81 p_node->print_desc = tmp_desc; in nd_rcv_process_nd()
86 cl_ntoh64(osm_node_get_node_guid(p_node)), in nd_rcv_process_nd()
87 p_node->print_desc); in nd_rcv_process_nd()
92 cl_ntoh64(osm_node_get_node_guid(p_node)), p_node->print_desc); in nd_rcv_process_nd()
103 osm_node_t *p_node; in osm_nd_rcv_process() local
[all …]
H A Dosm_sw_info_rcv.c70 osm_node_t *p_node;
79 p_node = p_sw->p_node;
81 CL_ASSERT(osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH);
83 context.lft_context.node_guid = osm_node_get_node_guid(p_node);
88 p_physp = osm_node_get_physp_ptr(p_node, 0);
116 osm_node_t *p_node;
129 p_node = p_sw->p_node;
131 CL_ASSERT(osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH);
136 cl_ntoh64(osm_node_get_node_guid(p_node)));
140 context.mft_context.node_guid = osm_node_get_node_guid(p_node);
[all …]
H A Dosm_pkey_mgr.c69 osm_node_t *p_node = osm_physp_get_node_ptr(p_physp); in pkey_mgr_get_physp_max_pkeys() local
72 if (!p_node->sw || (osm_physp_get_port_num(p_physp) == 0)) in pkey_mgr_get_physp_max_pkeys()
73 num_pkeys = cl_ntoh16(p_node->node_info.partition_cap); in pkey_mgr_get_physp_max_pkeys()
75 num_pkeys = cl_ntoh16(p_node->sw->switch_info.enforce_cap); in pkey_mgr_get_physp_max_pkeys()
95 osm_node_t *p_node = osm_physp_get_node_ptr(p_physp); in pkey_mgr_process_physical_port() local
106 cl_ntoh64(osm_node_get_node_guid(p_node)), in pkey_mgr_process_physical_port()
131 cl_ntoh64(osm_node_get_node_guid(p_node)), in pkey_mgr_process_physical_port()
194 cl_ntoh64(osm_node_get_node_guid(p_node)), in pkey_mgr_process_physical_port()
230 osm_node_t *p_node = osm_physp_get_node_ptr(p_physp); in pkey_mgr_update_pkey_entry() local
235 context.pkey_context.node_guid = osm_node_get_node_guid(p_node); in pkey_mgr_update_pkey_entry()
[all …]
H A Dosm_sa_node_record.c71 IN const osm_node_t * p_node, in nr_rcv_new_nr() argument
92 cl_ntoh64(osm_node_get_node_guid(p_node)), in nr_rcv_new_nr()
99 p_rec_item->resp.node_rec.node_info = p_node->node_info; in nr_rcv_new_nr()
104 memcpy(&(p_rec_item->resp.node_rec.node_desc), &(p_node->node_desc), in nr_rcv_new_nr()
113 static void nr_rcv_create_nr(IN osm_sa_t * sa, IN osm_node_t * p_node, in nr_rcv_create_nr() argument
141 if (osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH) in nr_rcv_create_nr()
144 num_ports = osm_node_get_num_physp(p_node); in nr_rcv_create_nr()
147 p_physp = osm_node_get_physp_ptr(p_node, port_num); in nr_rcv_create_nr()
187 nr_rcv_new_nr(sa, p_node, p_list, port_guid, base_lid, port_num); in nr_rcv_create_nr()
196 osm_node_t *p_node = (osm_node_t *) p_map_item; in nr_rcv_by_comp_mask() local
[all …]
H A Dosm_state_mgr.c100 osm_node_t *p_node = (osm_node_t *) p_map_item; in state_mgr_reset_node_count() local
102 p_node->discovery_count = 0; in state_mgr_reset_node_count()
104 memset(p_node->physp_discovered, 0, sizeof(uint8_t) * p_node->physp_tbl_size); in state_mgr_reset_node_count()
126 osm_node_t *p_node; in state_mgr_get_sw_info() local
136 p_node = p_sw->p_node; in state_mgr_get_sw_info()
137 p_physp = osm_node_get_physp_ptr(p_node, 0); in state_mgr_get_sw_info()
142 mad_context.si_context.node_guid = osm_node_get_node_guid(p_node); in state_mgr_get_sw_info()
153 cl_ntoh64(osm_node_get_node_guid(p_node)), in state_mgr_get_sw_info()
472 if (p_port->p_node->sw && in state_mgr_is_sm_port_down()
473 !ib_switch_info_is_enhanced_port0(&p_port->p_node->sw->switch_info)) in state_mgr_is_sm_port_down()
[all …]
H A Dosm_ucast_cache.c148 uint16_t lid_ho = cl_ntoh16(osm_node_get_base_lid(p->p_node, 0)); in cache_add_sw_link()
161 p_cache_sw = cache_sw_new(lid_ho, p->p_node->sw->num_ports); in cache_add_sw_link()
410 osm_node_t *p_node; in ucast_cache_validate() local
437 p_node = p_sw->p_node; in ucast_cache_validate()
439 lid_ho = cl_ntoh16(osm_node_get_base_lid(p_node, 0)); in ucast_cache_validate()
442 max_ports = osm_node_get_num_physp(p_node); in ucast_cache_validate()
447 p_physp = osm_node_get_physp_ptr(p_node, port_num); in ucast_cache_validate()
462 p_physp->p_remote_physp->p_node && in ucast_cache_validate()
464 p_node) != IB_NODE_TYPE_SWITCH) in ucast_cache_validate()
476 osm_node_get_type(p_remote_physp->p_node); in ucast_cache_validate()
[all …]
H A Dosm_slvl_map_rcv.c72 osm_node_t *p_node; in osm_slvl_rcv_process() local
115 p_node = p_port->p_node; in osm_slvl_rcv_process()
116 CL_ASSERT(p_node); in osm_slvl_rcv_process()
119 if (osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH) { in osm_slvl_rcv_process()
120 unsigned num_ports = osm_node_get_num_physp(p_node) - 1; in osm_slvl_rcv_process()
124 startoutport = ib_switch_info_is_enhanced_port0(&p_node->sw->switch_info) ? 0 : 1; in osm_slvl_rcv_process()
125 endoutport = osm_node_get_num_physp(p_node) - 1; in osm_slvl_rcv_process()
130 startinport = ib_switch_info_is_enhanced_port0(&p_node->sw->switch_info) ? 0 : 1; in osm_slvl_rcv_process()
131 endinport = osm_node_get_num_physp(p_node) - 1; in osm_slvl_rcv_process()
162 p_physp = osm_node_get_physp_ptr(p_node, out_port); in osm_slvl_rcv_process()
H A Dosm_sa_link_record.c91 if (p_physp->p_node->node_info.node_type == IB_NODE_TYPE_SWITCH) in get_base_lid()
92 p_physp = osm_node_get_physp_ptr(p_physp->p_node, 0); in get_base_lid()
209 osm_node_t *p_node; in lr_rcv_get_port_links() local
225 num_ports = osm_node_get_num_physp(p_src_port->p_node); in lr_rcv_get_port_links()
227 osm_node_get_num_physp(p_dest_port->p_node); in lr_rcv_get_port_links()
230 osm_node_get_physp_ptr(p_src_port->p_node, in lr_rcv_get_port_links()
237 p_node, in lr_rcv_get_port_links()
256 p_src_port->p_node->physp_tbl_size) { in lr_rcv_get_port_links()
259 p_node, in lr_rcv_get_port_links()
269 osm_node_get_num_physp(p_src_port->p_node); in lr_rcv_get_port_links()
[all …]
H A Dosm_link_mgr.c100 osm_node_t *p_node; in link_mgr_set_physp_pi() local
114 p_node = osm_physp_get_node_ptr(p_physp); in link_mgr_set_physp_pi()
122 if (osm_node_get_type(p_node) != IB_NODE_TYPE_SWITCH || in link_mgr_set_physp_pi()
139 if (osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH) in link_mgr_set_physp_pi()
140 physp0 = osm_node_get_physp_ptr(p_node, 0); in link_mgr_set_physp_pi()
149 if (!p_node->sw) { in link_mgr_set_physp_pi()
152 cl_ntoh64(p_node->node_info.node_guid)); in link_mgr_set_physp_pi()
156 if (ib_switch_info_is_enhanced_port0(&p_node->sw->switch_info) in link_mgr_set_physp_pi()
198 if (osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH && in link_mgr_set_physp_pi()
225 if (osm_node_get_type(p_node) != IB_NODE_TYPE_SWITCH || in link_mgr_set_physp_pi()
[all …]
H A Dosm_mlnx_ext_port_info_rcv.c71 osm_node_t *p_node; in osm_mlnx_epi_rcv_process() local
108 p_node = p_port->p_node; in osm_mlnx_epi_rcv_process()
109 CL_ASSERT(p_node); in osm_mlnx_epi_rcv_process()
113 p_physp = osm_node_get_physp_ptr(p_node, port_num); in osm_mlnx_epi_rcv_process()
118 if (p_node->sw && in osm_mlnx_epi_rcv_process()
119 ib_switch_info_is_enhanced_port0(&p_node->sw->switch_info)) in osm_mlnx_epi_rcv_process()
123 portnum < osm_node_get_num_physp(p_node); in osm_mlnx_epi_rcv_process()
125 p_physp = osm_node_get_physp_ptr(p_node, portnum); in osm_mlnx_epi_rcv_process()
H A Dosm_ucast_mgr.c113 lid = cl_ntoh16(osm_node_get_base_lid(p_sw->p_node, 0)); in ucast_mgr_process_hop_0_1()
117 osm_physp_t *p = osm_node_get_physp_ptr(p_sw->p_node, i); in ucast_mgr_process_hop_0_1()
119 p->p_remote_physp->p_node : NULL; in ucast_mgr_process_hop_0_1()
122 p_remote_node != p_sw->p_node) { in ucast_mgr_process_hop_0_1()
147 cl_ntoh64(osm_node_get_node_guid(p_this_sw->p_node)), in ucast_mgr_process_neighbor()
148 cl_ntoh64(osm_node_get_node_guid(p_remote_sw->p_node)), in ucast_mgr_process_neighbor()
151 p = osm_node_get_physp_ptr(p_this_sw->p_node, port_num); in ucast_mgr_process_neighbor()
157 lid_ho = cl_ntoh16(osm_node_get_base_lid(p_sw->p_node, 0)); in ucast_mgr_process_neighbor()
170 (p_this_sw->p_node))); in ucast_mgr_process_neighbor()
185 osm_physp_t *p = osm_node_get_physp_ptr(sw->p_node, port); in find_and_add_remote_sys()
[all …]
H A Dosm_switch.c109 osm_switch_t *osm_switch_new(IN osm_node_t * p_node, in osm_switch_new() argument
119 CL_ASSERT(p_node); in osm_switch_new()
123 num_ports = osm_node_get_num_physp(p_node); in osm_switch_new()
136 p_sw->p_node = p_node; in osm_switch_new()
147 osm_mcast_tbl_init(&p_sw->mcast_tbl, osm_node_get_num_physp(p_node), in osm_switch_new()
195 p_physp = osm_node_get_physp_ptr(p_sw->p_node, port_num); in switch_find_guid_common()
294 if (p_port->p_node->sw) { in osm_switch_recommend_path()
295 if (p_port->p_node->sw == p_sw) in osm_switch_recommend_path()
301 !p_physp->p_remote_physp->p_node->sw) in osm_switch_recommend_path()
304 if (p_physp->p_remote_physp->p_node->sw == p_sw) in osm_switch_recommend_path()
[all …]
H A Dosm_sa_multipath_record.c74 osm_node_t const *p_node; in sa_multipath_rec_is_tavor_port() local
77 p_node = p_port->p_node; in sa_multipath_rec_is_tavor_port()
78 vend_id = ib_node_info_get_vendor_id(&p_node->node_info); in sa_multipath_rec_is_tavor_port()
80 return ((p_node->node_info.device_id == CL_HTON16(23108)) && in sa_multipath_rec_is_tavor_port()
147 const osm_node_t *p_node; in mpr_rcv_get_path_parms() local
209 p_node = osm_physp_get_node_ptr(p_physp); in mpr_rcv_get_path_parms()
211 if (p_node->sw) { in mpr_rcv_get_path_parms()
217 p_physp = osm_switch_get_route_by_lid(p_node->sw, dest_lid); in mpr_rcv_get_path_parms()
222 src_lid_ho, dest_lid_ho, p_node->print_desc, in mpr_rcv_get_path_parms()
223 cl_ntoh64(osm_node_get_node_guid(p_node))); in mpr_rcv_get_path_parms()
[all …]
H A Dosm_mcast_mgr.c155 if (port->p_node->sw) { in create_mgrp_switch_map()
156 sw = port->p_node->sw; in create_mgrp_switch_map()
159 sw = port->p_physp->p_remote_physp->p_node->sw; in create_mgrp_switch_map()
163 guid = osm_node_get_node_guid(sw->p_node); in create_mgrp_switch_map()
202 lid = cl_ntoh16(osm_node_get_base_lid(sw->p_node, 0)); in mcast_mgr_compute_avg_hops()
237 lid = cl_ntoh16(osm_node_get_base_lid(sw->p_node, 0)); in mcast_mgr_compute_max_hops()
288 cl_ntoh64(osm_node_get_node_guid(p_sw->p_node)), hops); in mcast_mgr_find_optimal_switch()
299 cl_ntoh64(osm_node_get_node_guid(p_best_sw->p_node)), in mcast_mgr_find_optimal_switch()
300 p_best_sw->p_node->print_desc, best_hops); in mcast_mgr_find_optimal_switch()
334 osm_node_t *p_node; in mcast_mgr_set_mft_block() local
[all …]
H A Dosm_port.c92 IN uint8_t port_num, IN const struct osm_node *p_node, in osm_physp_init() argument
99 CL_ASSERT(p_node); in osm_physp_init()
106 p_physp->p_node = (struct osm_node *)p_node; in osm_physp_init()
111 if (osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH) in osm_physp_init()
113 num_slvl = osm_node_get_num_physp(p_node) + 1; in osm_physp_init()
151 p_port->p_node = (struct osm_node *)p_parent_node; in osm_port_new()
325 osm_node_t *p_node; in physp_get_dr_physp_set() local
341 p_node = p_port->p_node; in physp_get_dr_physp_set()
350 p_physp = osm_node_get_physp_ptr(p_node, p_path->path[hop]); in physp_get_dr_physp_set()
368 cl_ntoh64(p_node->node_info.node_guid), in physp_get_dr_physp_set()
[all …]
H A Dosm_sa_path_record.c84 osm_node_t const *p_node; in sa_path_rec_is_tavor_port() local
87 p_node = p_port->p_node; in sa_path_rec_is_tavor_port()
88 vend_id = ib_node_info_get_vendor_id(&p_node->node_info); in sa_path_rec_is_tavor_port()
90 return ((p_node->node_info.device_id == CL_HTON16(23108)) && in sa_path_rec_is_tavor_port()
155 const osm_node_t *p_node; in pr_rcv_get_path_parms() local
221 p_node = osm_physp_get_node_ptr(p_physp); in pr_rcv_get_path_parms()
223 if (p_node->sw) { in pr_rcv_get_path_parms()
229 p_physp = osm_switch_get_route_by_lid(p_node->sw, dest_lid); in pr_rcv_get_path_parms()
234 src_lid_ho, dest_lid_ho, p_node->print_desc, in pr_rcv_get_path_parms()
235 cl_ntoh64(osm_node_get_node_guid(p_node))); in pr_rcv_get_path_parms()
[all …]
H A Dosm_pkey_rcv.c64 osm_node_t *p_node; in osm_pkey_rcv_process() local
105 p_node = p_port->p_node; in osm_pkey_rcv_process()
106 CL_ASSERT(p_node); in osm_pkey_rcv_process()
110 if (osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH) { in osm_pkey_rcv_process()
114 p_physp = osm_node_get_physp_ptr(p_node, port_num); in osm_pkey_rcv_process()
H A Dosm_vl_arb_rcv.c73 osm_node_t *p_node; in osm_vla_rcv_process() local
113 p_node = p_port->p_node; in osm_vla_rcv_process()
114 CL_ASSERT(p_node); in osm_vla_rcv_process()
118 if (osm_node_get_type(p_node) == IB_NODE_TYPE_SWITCH) { in osm_vla_rcv_process()
120 p_physp = osm_node_get_physp_ptr(p_node, port_num); in osm_vla_rcv_process()
H A Dosm_sa_portinfo_record.c110 if (osm_node_get_type(p_physp->p_node) == in pir_rcv_new_pir()
112 p_physp0 = osm_node_get_physp_ptr(p_physp->p_node, 0); in pir_rcv_new_pir()
151 if (p_physp->p_node->sw) { in sa_pir_create()
152 p_node_physp = osm_node_get_physp_ptr(p_physp->p_node, 0); in sa_pir_create()
155 osm_switch_sp0_is_lmc_capable(p_physp->p_node->sw, in sa_pir_create()
201 osm_dump_port_info_v2(sa->p_log, osm_node_get_node_guid(p_physp->p_node), in sa_pir_check_physp()
420 if (osm_node_get_type(p_physp->p_node) == IB_NODE_TYPE_SWITCH) { in sa_pir_check_physp()
421 p_physp0 = osm_node_get_physp_ptr(p_physp->p_node, 0); in sa_pir_check_physp()
449 static void sa_pir_by_comp_mask(IN osm_sa_t * sa, IN osm_node_t * p_node, in sa_pir_by_comp_mask() argument
465 num_ports = osm_node_get_num_physp(p_node); in sa_pir_by_comp_mask()
[all …]
/freebsd/contrib/ofed/opensm/include/opensm/
H A Dosm_node.h162 void osm_node_delete(IN OUT osm_node_t ** p_node);
217 static inline osm_physp_t *osm_node_get_physp_ptr(IN osm_node_t * p_node, in osm_node_get_physp_ptr() argument
221 CL_ASSERT(port_num < p_node->physp_tbl_size); in osm_node_get_physp_ptr()
222 return osm_physp_is_valid(&p_node->physp_table[port_num]) ? in osm_node_get_physp_ptr()
223 &p_node->physp_table[port_num] : NULL; in osm_node_get_physp_ptr()
254 static inline uint8_t osm_node_get_type(IN const osm_node_t * p_node) in osm_node_get_type() argument
256 return p_node->node_info.node_type; in osm_node_get_type()
285 static inline uint8_t osm_node_get_num_physp(IN const osm_node_t * p_node) in osm_node_get_num_physp() argument
287 return (uint8_t) p_node->physp_tbl_size; in osm_node_get_num_physp()
315 osm_node_t *osm_node_get_remote_node(IN osm_node_t * p_node,
[all …]

123