xref: /titanic_50/usr/src/uts/sun4u/sunfire/sys/sram.h (revision 02ca3e029e37aa98ac6717698bfdac6afe960932)
1 /*
2  * CDDL HEADER START
3  *
4  * The contents of this file are subject to the terms of the
5  * Common Development and Distribution License (the "License").
6  * You may not use this file except in compliance with the License.
7  *
8  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9  * or http://www.opensolaris.org/os/licensing.
10  * See the License for the specific language governing permissions
11  * and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL HEADER in each
14  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15  * If applicable, add the following below this CDDL HEADER, with the
16  * fields enclosed by brackets "[]" replaced with your own identifying
17  * information: Portions Copyright [yyyy] [name of copyright owner]
18  *
19  * CDDL HEADER END
20  */
21 
22 /*
23  * Copyright 1994 Sun Microsystems, Inc.  All rights reserved.
24  * Use is subject to license terms.
25  */
26 
27 #ifndef	_SYS_SRAM_H
28 #define	_SYS_SRAM_H
29 
30 #pragma ident	"%Z%%M%	%I%	%E% SMI"
31 
32 #ifdef	__cplusplus
33 extern "C" {
34 #endif
35 
36 /* useful debugging stuff */
37 #define	SRAM_ATTACH_DEBUG	0x1
38 #define	SRAM_REGISTERS_DEBUG	0x2
39 
40 /* Use predefined strings to name the kstats from this driver. */
41 #define	RESETINFO_KSTAT_NAME	"reset-info"
42 
43 /* Define Maximum size of the reset-info data passed up by POST. */
44 #define	MX_RSTINFO_SZ		0x2000
45 
46 #if defined(_KERNEL)
47 
48 /* Structures used in the driver to manage the hardware */
49 struct sram_soft_state {
50 	dev_info_t *dip;	/* dev info of myself */
51 	dev_info_t *pdip;	/* dev info of my parent */
52 	int board;		/* Board number for this sram */
53 	char *sram_base;	/* base of sram */
54 	int offset;		/* offset into sram of reset info */
55 	char *reset_info;	/* base of reset-info structure */
56 	char *os_private;	/* base of OS private area; */
57 };
58 
59 #endif	/* _KERNEL */
60 
61 #ifdef	__cplusplus
62 }
63 #endif
64 
65 #endif	/* _SYS_SRAM_H */
66