wrsm_nc.h revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright (c) 2001 by Sun Microsystems, Inc.
* All rights reserved.
*/
#ifndef _WRSM_NC_H
#define _WRSM_NC_H
#pragma ident "%Z%%M% %I% %E% SMI"
/*
* this file is include by consumers of NC interfaces
*/
#include <sys/wrsm_config.h>
#include <sys/wrsm_common.h>
#include <sys/wrsm_transport.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef struct wci_ids {
int port; /* safari port id */
} wci_ids_t;
/*
* wrsm_mh data structures
*/
typedef struct wrsm_mh_reachable {
int nhops[WRSM_MAX_WNODES];
int stripes[WRSM_MAX_WNODES];
/*
* The following data structures are to support for queueing events to the
* per controller NR event thread.
*/
typedef enum {
#ifdef DEBUG
#define WRSM_EVTSTRING(e) \
((e == wrsm_evt_mhdirect) ? "mhdirect" : \
(e == wrsm_evt_mhreroute) ? "mhreroute" : \
(e == wrsm_evt_force_reroute) ? "force_reroute" : \
(e == wrsm_evt_add_passthrough) ? "add_passthrough" : \
(e == wrsm_evt_send_ptlist) ? "send_ptlist" : \
(e == wrsm_evt_recv_ptlist) ? "recv_ptlist" : \
(e == wrsm_evt_sessup) ? "sessup" : \
(e == wrsm_evt_sessdown) ? "sessdown" : \
(e == wrsm_evt_connect) ? "connect" : \
(e == wrsm_evt_smallputmap) ? "smallputmap" : \
(e == wrsm_evt_barriermap) ? "barriermap" : \
(e == wrsm_evt_segmap) ? "segmap" : \
(e == wrsm_evt_disconnect) ? "disconnect" : \
(e == wrsm_evt_unpublish) ? "unpublish" : \
(e == wrsm_evt_access) ? "access" : \
#endif
typedef struct wrsm_evt_mhevent {
typedef struct wrsm_evt_forcereroute {
typedef struct wrsm_evt_addpt {
typedef struct wrsm_evt_send_ptlist {
typedef struct wrsm_evt_recv_ptlist {
int pt_route_counter; /* incr when pt_provided changes */
typedef struct wrsm_evt_sess {
typedef struct wrsm_nr_event {
union {
} data;
struct wrsm_nr_event *next;
/*
* the following functions are used by the Config Layer
*/
/*
* find network structure from controller id or dev_info_t pointer
*/
/*
* save away new config info; disable current config
*/
/*
*/
/*
* make sure all old links are down; bring up new links
*/
/*
* start using new links
*/
/*
* check whether config is in installed_up state
*/
/*
* install and enable new config
*/
/*
* uninstall config for an RSM controller; delete RSM controller
*/
/*
* enable sessions in RSM controller
*/
/*
* enable sessions in RSM controller
*/
/*
* notify the NR that all links on a WCI are up
*/
/*
* find out if node connected to a link has a valid session
*/
/*
* clear cluster write lockout on a remote cnode
*/
/*
* a new WCI has been attached
*/
/*
* an attached wci is being detached
*/
/*
* the following functions are used by memory segments
*/
/*
* the following functions are used by the LC
*/
/*
* the following functions are used by the driver
*/
/* this is an RSMPI function */
/*
* returns controller number given nc handle. Used by lc since the lc
* cannot dereference the config fields in softstate as they may be null
*/
/*
* The plugin library (librsmwrsm) opens controllers, in order to prevent the
* the config layer from removing a controller (network) that the plugin is
* using, the driver must return busy. open and close controller below
* a config.
*/
/* logs system events for use by user applications via the sysdaemond to see */
#ifdef __cplusplus
}
#endif
#endif /* _WRSM_NC_H */