Print this page
LOCAL: disk-lights work 2


 120 /*
 121  * Topo node utilities: callable from topo_walk_step() callback or module
 122  * enumeration, topo_mod_enumerate()
 123  */
 124 extern char *topo_node_name(tnode_t *);
 125 extern topo_instance_t topo_node_instance(tnode_t *);
 126 extern tnode_t *topo_node_parent(tnode_t *);
 127 extern void *topo_node_private(tnode_t *);
 128 extern int topo_node_flags(tnode_t *);
 129 extern int topo_node_asru(tnode_t *, nvlist_t **, nvlist_t *, int *);
 130 extern int topo_node_fru(tnode_t *, nvlist_t **, nvlist_t *, int *);
 131 extern int topo_node_resource(tnode_t *, nvlist_t **, int *);
 132 extern int topo_node_label(tnode_t *, char **, int *);
 133 extern tnode_t *topo_node_lookup(tnode_t *, const char *, topo_instance_t);
 134 extern int topo_method_invoke(tnode_t *node, const char *, topo_version_t,
 135     nvlist_t *, nvlist_t **, int *);
 136 extern boolean_t topo_method_supported(tnode_t *, const char *,
 137     topo_version_t);
 138 extern int topo_node_facility(topo_hdl_t *, tnode_t *, const char *,
 139     uint32_t, topo_faclist_t *, int *);


 140 
 141 /*
 142  * Node flags: denotes type of node
 143  */
 144 #define TOPO_NODE_DEFAULT       0
 145 #define TOPO_NODE_FACILITY      1
 146 
 147 #define TOPO_FAC_TYPE_SENSOR    "sensor"
 148 #define TOPO_FAC_TYPE_INDICATOR "indicator"
 149 
 150 /*
 151  * Topo property get functions
 152  */
 153 extern int topo_prop_get_int32(tnode_t *, const char *, const char *,
 154     int32_t *, int *);
 155 extern int topo_prop_get_uint32(tnode_t *, const char *, const char *,
 156     uint32_t *, int *);
 157 extern int topo_prop_get_int64(tnode_t *, const char *, const char *,
 158     int64_t *, int *);
 159 extern int topo_prop_get_uint64(tnode_t *, const char *, const char *,




 120 /*
 121  * Topo node utilities: callable from topo_walk_step() callback or module
 122  * enumeration, topo_mod_enumerate()
 123  */
 124 extern char *topo_node_name(tnode_t *);
 125 extern topo_instance_t topo_node_instance(tnode_t *);
 126 extern tnode_t *topo_node_parent(tnode_t *);
 127 extern void *topo_node_private(tnode_t *);
 128 extern int topo_node_flags(tnode_t *);
 129 extern int topo_node_asru(tnode_t *, nvlist_t **, nvlist_t *, int *);
 130 extern int topo_node_fru(tnode_t *, nvlist_t **, nvlist_t *, int *);
 131 extern int topo_node_resource(tnode_t *, nvlist_t **, int *);
 132 extern int topo_node_label(tnode_t *, char **, int *);
 133 extern tnode_t *topo_node_lookup(tnode_t *, const char *, topo_instance_t);
 134 extern int topo_method_invoke(tnode_t *node, const char *, topo_version_t,
 135     nvlist_t *, nvlist_t **, int *);
 136 extern boolean_t topo_method_supported(tnode_t *, const char *,
 137     topo_version_t);
 138 extern int topo_node_facility(topo_hdl_t *, tnode_t *, const char *,
 139     uint32_t, topo_faclist_t *, int *);
 140 extern int topo_node_child_walk(topo_hdl_t *, tnode_t *, topo_walk_cb_t,
 141     void *, int *);
 142 
 143 /*
 144  * Node flags: denotes type of node
 145  */
 146 #define TOPO_NODE_DEFAULT       0
 147 #define TOPO_NODE_FACILITY      1
 148 
 149 #define TOPO_FAC_TYPE_SENSOR    "sensor"
 150 #define TOPO_FAC_TYPE_INDICATOR "indicator"
 151 
 152 /*
 153  * Topo property get functions
 154  */
 155 extern int topo_prop_get_int32(tnode_t *, const char *, const char *,
 156     int32_t *, int *);
 157 extern int topo_prop_get_uint32(tnode_t *, const char *, const char *,
 158     uint32_t *, int *);
 159 extern int topo_prop_get_int64(tnode_t *, const char *, const char *,
 160     int64_t *, int *);
 161 extern int topo_prop_get_uint64(tnode_t *, const char *, const char *,