Lines Matching defs:node

129  * @param wwnn World wide node name in host endian.
181 /* Initialize node group list */
248 /* Free any node group directories */
286 ocs_node_t *node;
295 ocs_list_foreach_safe(&sport->node_list, node, next) {
296 ocs_node_force_free(node);
370 * @param wwnn World wide node name.
409 ocs_node_t *node;
419 ocs_list_foreach(&sport->node_list, node) {
420 ocs_node_update_display_name(node);
489 ocs_node_t *node;
505 /* sm: node list is empty / ocs_hw_port_free
517 /* sm: node list is not empty / shutdown nodes */
520 ocs_list_foreach_safe(&sport->node_list, node, node_next) {
525 if((node->rnode.fc_id == FC_ADDR_FABRIC) && (sport->is_vport)) {
528 ocs_node_post_event(node, OCS_EVT_SHUTDOWN, NULL);
530 ocs_log_debug(ocs,"[%s] sport shutdown vport,sending logo to node\n",
531 node->display_name);
533 if (ocs_send_logo(node, OCS_FC_ELS_SEND_DEFAULT_TIMEOUT,
535 /* failed to send LOGO, go ahead and cleanup node anyways */
536 node_printf(node, "Failed to send LOGO\n");
537 ocs_node_post_event(node, OCS_EVT_SHUTDOWN_EXPLICIT_LOGO, NULL);
540 ocs_node_transition(node, __ocs_d_wait_logo_rsp, NULL);
544 ocs_node_post_event(node, OCS_EVT_SHUTDOWN, NULL);
566 * @param ctx Remote node state machine context.
604 * @param ctx Remote node state machine context.
655 * @param ctx Remote node state machine context.
687 /* if sport->fc_id is uninitialized, then request that the fabric node use FDISC
717 * This state is entered after the sport is allocated; it then waits for a fabric node
721 * @param ctx Remote node state machine context.
737 ocs_node_t *node;
740 /* Find our fabric node, and forward this event */
741 node = ocs_node_find(sport, FC_ADDR_FABRIC);
742 if (node == NULL) {
743 ocs_log_test(ocs, "can't find node %06x\n", FC_ADDR_FABRIC);
746 /* sm: / forward sport attach to fabric node */
747 ocs_node_post_event(node, evt, NULL);
766 * @param ctx Remote node state machine context.
782 ocs_node_t *node;
787 ocs_list_foreach(&sport->node_list, node) {
788 ocs_node_update_display_name(node);
826 * @brief SLI port state machine: Wait for the node shutdowns to complete.
829 * Waits for the ALL_CHILD_NODES_FREE event to be posted from the node
832 * @param ctx Remote node state machine context.
881 * @param ctx Remote node state machine context.
998 * @param wwnn World wide node name
1000 * @param ini TRUE, if port is created as an initiator node.
1001 * @param tgt TRUE, if port is created as a target node.
1092 * @param wwnn World wide node name of the port to delete (host endian).
1187 ocs_node_t *node;
1243 ocs_list_foreach(&sport->node_list, node) {
1244 retval = ocs_ddump_node(textbuf, node);
1260 ocs_node_t *node;
1283 ocs_list_foreach(&sport->node_list, node) {
1284 if ((node->mgmt_functions) && (node->mgmt_functions->get_list_handler)) {
1285 node->mgmt_functions->get_list_handler(textbuf, node);
1298 ocs_node_t *node;
1351 ocs_list_foreach(&sport->node_list, node) {
1352 if ((node->mgmt_functions) && (node->mgmt_functions->get_handler)) {
1353 retval = node->mgmt_functions->get_handler(textbuf, qualifier, name, node);
1372 ocs_node_t *node;
1391 ocs_list_foreach(&sport->node_list, node) {
1392 if ((node->mgmt_functions) && (node->mgmt_functions->get_all_handler)) {
1393 node->mgmt_functions->get_all_handler(textbuf, node);
1404 ocs_node_t *node;
1413 /* The sport has no settable values. Pass the request to each node. */
1416 ocs_list_foreach(&sport->node_list, node) {
1417 if ((node->mgmt_functions) && (node->mgmt_functions->set_handler)) {
1418 retval = node->mgmt_functions->set_handler(qualifier, name, value, node);
1435 ocs_node_t *node;
1455 ocs_list_foreach(&sport->node_list, node) {
1456 if ((node->mgmt_functions) && (node->mgmt_functions->exec_handler)) {
1457 retval = node->mgmt_functions->exec_handler(qualifier, action, arg_in, arg_in_length,
1458 arg_out, arg_out_length, node);
1512 * @param wwnn World wide node name (may be zero for auto-select).
1560 /* node group api */
1611 * Returns 0 if the two service parameters are the same, excluding the port/node name
1638 * @brief Allocate a node group directory entry.
1641 * A node group directory entry is allocated, initialized, and added to the sport's
1642 * node group directory list.
1669 ocs_log_debug(sport->ocs, "[%s] [%d] allocating node group directory\n", sport->display_name,
1676 * @brief Free a node group directory entry.
1679 * The node group directory entry @c node_group_dir is removed
1680 * from the sport's node group directory list and freed.
1682 * @param node_group_dir Pointer to the node group directory entry.
1693 ocs_log_debug(sport->ocs, "[%s] [%d] freeing node group directory\n", sport->display_name,
1697 ocs_log_test(sport->ocs, "[%s] WARNING: node group list not empty\n", sport->display_name);
1706 * @brief Find a matching node group directory entry.
1709 * The sport's node group directory list is searched for a matching set of
1736 * @brief Allocate a remote node group object.
1739 * A remote node group object is allocated, initialized, and placed on the node group
1740 * list of @c node_group_dir. The HW remote node group @b alloc function is called.
1742 * @param node_group_dir Pointer to the node group directory.
1744 * @return Returns a pointer to the allocated remote node group object; or NULL.
1766 /* set pointer to node group directory */
1773 /* invoke HW node group inialization */
1781 ocs_log_debug(ocs, "[%s] [%d] indicator x%03x allocating node group\n", sport->display_name,
1784 /* add to the node group directory entry node group list */
1794 * @brief Free a remote node group object.
1797 * The remote node group object @c node_group is removed from its
1798 * node group directory entry and freed.
1800 * @param node_group Pointer to the remote node group object.
1820 ocs_log_debug(sport->ocs, "[%s] [%d] freeing node group\n", sport->display_name, node_group->instance_index);
1822 /* Remove from node group directory node group list */
1834 * @brief Initialize a node for high login mode.
1837 * The @c node is initialized for high login mode. The following steps are performed:
1838 * 1. The sports node group directory is searched for a matching set of service parameters.
1839 * 2. If a matching set is not found, a node group directory entry is allocated.
1840 * 3. If less than the @c hlm_group_size number of remote node group objects is present in the
1841 * node group directory, a new remote node group object is allocated and added to the list.
1842 * 4. A remote node group object is selected, and the node is attached to the node group.
1844 * @param node Pointer to the node.
1850 ocs_node_group_init(ocs_node_t *node)
1858 ocs_assert(node, -1);
1859 ocs_assert(node->sport, -1);
1860 ocs_assert(node->ocs, -1);
1862 ocs = node->ocs;
1863 sport = node->sport;
1867 /* see if there's a node group directory allocated for this service parameter set */
1868 node_group_dir = ocs_node_group_dir_find(sport, node->service_params);
1871 node_group_dir = ocs_node_group_dir_alloc(sport, node->service_params);
1873 /* node group directory allocation failed ... can't continue, however,
1874 * the node will be allocated with a normal (not shared) RPI
1881 /* check to see if we've allocated hlm_group_size's worth of node group structures for this
1884 ocs_lock(&node->sport->node_group_lock);
1886 ocs_unlock(&node->sport->node_group_lock);
1892 ocs_lock(&node->sport->node_group_lock);
1898 ocs_log_err(node->ocs, "assertion failed: idx >= ocs->hlm_group_size\n");
1899 ocs_unlock(&node->sport->node_group_lock);
1915 ocs_unlock(&node->sport->node_group_lock);
1917 /* Initialize a pointer in the node back to the node group */
1918 node->node_group = node_group;
1920 /* Join this node into the group */
1921 hrc = ocs_hw_node_group_attach(&ocs->hw, node_group, &node->rnode);