11414Scindi /* 21414Scindi * CDDL HEADER START 31414Scindi * 41414Scindi * The contents of this file are subject to the terms of the 51414Scindi * Common Development and Distribution License (the "License"). 61414Scindi * You may not use this file except in compliance with the License. 71414Scindi * 81414Scindi * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 91414Scindi * or http://www.opensolaris.org/os/licensing. 101414Scindi * See the License for the specific language governing permissions 111414Scindi * and limitations under the License. 121414Scindi * 131414Scindi * When distributing Covered Code, include this CDDL HEADER in each 141414Scindi * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 151414Scindi * If applicable, add the following below this CDDL HEADER, with the 161414Scindi * fields enclosed by brackets "[]" replaced with your own identifying 171414Scindi * information: Portions Copyright [yyyy] [name of copyright owner] 181414Scindi * 191414Scindi * CDDL HEADER END 201414Scindi */ 211414Scindi 221414Scindi /* 231414Scindi * Copyright 2006 Sun Microsystems, Inc. All rights reserved. 241414Scindi * Use is subject to license terms. 251414Scindi */ 261414Scindi 271414Scindi #ifndef _HB_SUN4_H 281414Scindi #define _HB_SUN4_H 291414Scindi 301414Scindi #pragma ident "%Z%%M% %I% %E% SMI" 311414Scindi 321414Scindi #include <fm/topo_mod.h> 331414Scindi #include <sys/types.h> 341414Scindi #include <libdevinfo.h> 351414Scindi 361414Scindi #ifdef __cplusplus 371414Scindi extern "C" { 381414Scindi #endif 391414Scindi 401414Scindi typedef struct busorrc { 411414Scindi struct busorrc *br_nextbus; /* next bus or root complex */ 421414Scindi struct busorrc *br_prevbus; /* previous bus or root complex */ 431414Scindi ulong_t br_ba_ac; /* bus addr, after the comma */ 441414Scindi ulong_t br_ba_bc; /* bus addr, before the comma */ 451414Scindi di_node_t br_din; /* devinfo node */ 461414Scindi } busorrc_t; 471414Scindi 482027Ssethg struct did_hash; 492027Ssethg 50*3062Scindi extern busorrc_t *busorrc_new(topo_mod_t *, const char *, di_node_t); 51*3062Scindi extern void busorrc_insert(topo_mod_t *, busorrc_t **, busorrc_t *); 52*3062Scindi extern int busorrc_add(topo_mod_t *, busorrc_t **, di_node_t); 53*3062Scindi extern void busorrc_free(topo_mod_t *, busorrc_t *); 541414Scindi 55*3062Scindi extern tnode_t *rc_process(topo_mod_t *, tnode_t *, topo_instance_t, di_node_t); 56*3062Scindi extern int declare_buses(topo_mod_t *, busorrc_t *, tnode_t *, int); 57*3062Scindi extern int declare_exbuses(topo_mod_t *, busorrc_t *, tnode_t *, int, int); 581414Scindi 591414Scindi #ifdef __cplusplus 601414Scindi } 611414Scindi #endif 621414Scindi 631414Scindi #endif /* _HB_SUN4_H */ 64