xref: /illumos-gate/usr/src/psm/stand/boot/sparc/common/boot_plat.h (revision e38a713ad4e0a9c42f8cccd9350412b2c6ccccdb)
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  * Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
23  * Use is subject to license terms.
24  */
25 
26 #ifndef _BOOT_PLAT_H
27 #define	_BOOT_PLAT_H
28 
29 #pragma ident	"%Z%%M%	%I%	%E% SMI"
30 
31 #ifdef __cplusplus
32 extern "C" {
33 #endif
34 
35 
36 
37 /* boot_plat.c */
38 extern int	verbosemode;
39 extern char	filename[];
40 extern char	*const defname;
41 extern char	*const defname64;
42 extern char	wanboot_arguments[];
43 
44 extern int	bootprog(char *, char *, boolean_t);
45 extern char	*choose_default_filename(char *, char *);
46 extern char	*get_default_filename(void);
47 extern void	post_mountroot(char *, char *);
48 extern void	redirect_boot_path(char *, char *);
49 extern void	set_client_bootargs(const char *, const char *);
50 extern boolean_t is_netdev(char *devpath);
51 
52 
53 /* bootops.c */
54 extern struct bootops	bootops;
55 
56 extern void	setup_bootops(void);
57 extern void	update_memlist(char *, char *, struct memlist **);
58 
59 
60 /*
61  * bootprop.c.  These variables will be exported to the standalone as boot
62  * properties.
63  */
64 extern char	*v2path, *kernname, *systype, *my_own_name;
65 extern char	v2args_buf[];
66 #define	V2ARGS_BUF_SZ	OBP_MAXPATHLEN
67 extern char	*v2args;
68 extern char	*mfg_name;
69 extern char	*impl_arch_name;
70 extern char	*bootp_response;
71 extern char	*boot_message;
72 extern int	cache_state;
73 extern uint64_t	memlistextent;
74 extern char	*netdev_path;
75 
76 extern void	set_default_filename(char *filename);
77 
78 
79 /* get.c */
80 extern int	cons_gets(char *, int);
81 
82 
83 /* machdep.c */
84 extern int  vac;
85 
86 extern void	fiximp(void);
87 extern void	retain_nvram_page();
88 
89 #ifdef MPSAS
90 extern void	sas_bpts(void);
91 #endif
92 
93 extern int	cpu_is_ultrasparc_1(void);
94 
95 
96 /* memlist.c */
97 extern void		init_memlists(void);
98 extern struct memlist	*fill_memlists(char *name, char *prop,
99     struct memlist *old);
100 
101 
102 /* srt0.c */
103 extern void	_start(void *romp, ...);
104 extern void	exitto(int (*entrypoint)());
105 extern void	exitto64(int (*entrypoint)(), void *bootvec);
106 
107 
108 /* standalloc.c */
109 extern caddr_t	memlistpage;
110 extern caddr_t	scratchmemp;
111 
112 
113 
114 #ifdef __cplusplus
115 }
116 #endif
117 
118 #endif /* _BOOT_PLAT_H */
119