xref: /titanic_50/usr/src/uts/sun4u/sys/rmcadm.h (revision c77a61a72b5ecdc507d6cf104142edd371a16c84)
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 2002 Sun Microsystems, Inc.  All rights reserved.
24  * Use is subject to license terms.
25  */
26 
27 #ifndef _SYS_RMCADM_IMPL_H
28 #define	_SYS_RMCADM_IMPL_H
29 
30 #pragma ident	"%Z%%M%	%I%	%E% SMI"
31 
32 #ifdef	__cplusplus
33 extern "C" {
34 #endif
35 
36 #define	RMCADM_REQUEST_RESPONSE		0
37 #define	RMCADM_RESET_SP			1
38 #define	RMCADM_REQUEST_RESPONSE_BP	2
39 #define	RMCADM_SEND_SRECORD_BP		3
40 
41 typedef struct rmcadm_msg {
42 	uint8_t		msg_type;	/* message type */
43 	uint16_t	msg_len;	/* size of the message buffer */
44 	uint16_t	msg_bytes;	/* number of bytes returned */
45 	caddr_t		msg_buf;	/* message buffer */
46 } rmcadm_msg_t;
47 
48 typedef struct rmcadm_request_response {
49 	rmcadm_msg_t	req;
50 	rmcadm_msg_t	resp;
51 	uint_t		wait_time;
52 	int		status;
53 } rmcadm_request_response_t;
54 
55 typedef struct rmcadm_send_srecord_bp {
56 	uint_t		data_len;
57 	caddr_t		data_buf;	/* message buffer */
58 	rmcadm_msg_t	resp_bp;	/* BP message returned */
59 	uint32_t	wait_time;	/* max waiting time for a BP message */
60 					/* (millisec) */
61 	int		status;
62 } rmcadm_send_srecord_bp_t;
63 
64 #if defined(_SYSCALL32)
65 typedef struct rmcadm_msg32 {
66 	uint8_t		msg_type;	/* message type */
67 	uint16_t	msg_len;	/* size of the message buffer */
68 	uint16_t	msg_bytes;	/* number of bytes returned */
69 	caddr32_t	msg_buf;	/* message buffer */
70 } rmcadm_msg32_t;
71 
72 typedef struct rmcadm_request_response32 {
73 	rmcadm_msg32_t	req;
74 	rmcadm_msg32_t	resp;
75 	uint32_t	wait_time;
76 	int		status;
77 } rmcadm_request_response32_t;
78 
79 typedef struct rmcadm_send_srecord_bp32 {
80 	uint_t		data_len;
81 	caddr32_t	data_buf;	/* message buffer */
82 	rmcadm_msg32_t	resp_bp;
83 	uint32_t	wait_time;
84 	int		status;
85 } rmcadm_send_srecord_bp32_t;
86 
87 #endif /* _SYSCALL32 */
88 
89 #ifdef	__cplusplus
90 }
91 #endif
92 
93 #endif	/* _SYS_RMCADM_IMPL_H */
94