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.
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.
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]
23 * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
24 * Use is subject to license terms.
30 #pragma ident "%Z%%M% %I% %E% SMI"
37 * Serengeti SBBC Driver
39 * The Serengeti SBBC driver handles communication between the
40 * System Controller Software (ScApp) and Solaris via SBBC
41 * registers and IOSRAM.
44 #include <sys/serengeti.h>
47 * OS <-> SC Interrupt Reasons
49 #define SBBC_CONSOLE_IN 0x1 /* console input available */
50 #define SBBC_CONSOLE_OUT 0x2 /* console output available */
51 #define SBBC_CONSOLE_BRK 0x4 /* break */
52 #define SBBC_CONSOLE_SPACE_IN 0x8 /* console has in space */
53 #define SBBC_CONSOLE_SPACE_OUT 0x10 /* console has out space */
54 #define SBBC_MAILBOX_IN 0x20 /* mailbox message in */
55 #define SBBC_MAILBOX_OUT 0x40 /* mailbox message out */
56 #define SBBC_MAILBOX_SPACE_IN 0x80 /* mailbox has in space */
57 #define SBBC_MAILBOX_SPACE_OUT 0x100 /* mailbox has out space */
60 * SBBC needs to know what softint handlers are doing
62 #define SBBC_INTR_IDLE 0
63 #define SBBC_INTR_RUNNING 1
65 typedef const char *const fn_t
;
67 typedef uint_t (*sbbc_intrfunc_t
)(caddr_t
);
69 /* For printing out warning and panic messages */
70 #define SBBC_ERR(err, msg) \
71 { prom_printf(msg); cmn_err(err, msg); }
72 #define SBBC_ERR1(err, msg, arg) \
73 { prom_printf(msg, arg); cmn_err(err, msg, arg); }
80 #endif /* _SYS_SGSBBC_H */