xref: /netbsd-src/sys/arch/pmax/include/bootinfo.h (revision 02cdf4d2c869ecfa1ae5484cf77eefe2fbcc6d94)
1*02cdf4d2Sdsl /*	$NetBSD: bootinfo.h,v 1.8 2009/03/14 14:46:04 dsl Exp $	*/
2729eda43Ssimonb 
3729eda43Ssimonb /*
4729eda43Ssimonb  * Copyright (c) 1997
5729eda43Ssimonb  *	Matthias Drochner.  All rights reserved.
6729eda43Ssimonb  *
7729eda43Ssimonb  * Redistribution and use in source and binary forms, with or without
8729eda43Ssimonb  * modification, are permitted provided that the following conditions
9729eda43Ssimonb  * are met:
10729eda43Ssimonb  * 1. Redistributions of source code must retain the above copyright
11729eda43Ssimonb  *    notice, this list of conditions and the following disclaimer.
12729eda43Ssimonb  * 2. Redistributions in binary form must reproduce the above copyright
13729eda43Ssimonb  *    notice, this list of conditions and the following disclaimer in the
14729eda43Ssimonb  *    documentation and/or other materials provided with the distribution.
15729eda43Ssimonb  *
16729eda43Ssimonb  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
17729eda43Ssimonb  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
18729eda43Ssimonb  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
19729eda43Ssimonb  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
20729eda43Ssimonb  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
21729eda43Ssimonb  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
22729eda43Ssimonb  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23729eda43Ssimonb  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24729eda43Ssimonb  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
25729eda43Ssimonb  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26729eda43Ssimonb  *
27729eda43Ssimonb  */
28729eda43Ssimonb 
29838b5e08Sad #ifndef _PMAX_BOOTINFO_H_
30838b5e08Sad #define _PMAX_BOOTINFO_H_
31838b5e08Sad 
32729eda43Ssimonb #define BOOTINFO_MAGIC	0xb007babe
336f6573cbSsimonb #define BOOTINFO_SIZE	1024
34729eda43Ssimonb 
35729eda43Ssimonb /*
36729eda43Ssimonb  * The bootinfo structure is at the end of the 64kB hole between
37729eda43Ssimonb  * 0x80010000 to 0x8001ffff that neither NetBSD nor the PROM uses.
38729eda43Ssimonb  */
396f6573cbSsimonb #define BOOTINFO_ADDR	0x8001fc00
40729eda43Ssimonb 
41729eda43Ssimonb struct btinfo_common {
42729eda43Ssimonb 	int next;		/* offset of next item, or zero */
43729eda43Ssimonb 	int type;
44729eda43Ssimonb };
45729eda43Ssimonb 
46729eda43Ssimonb #define BTINFO_MAGIC	1
47729eda43Ssimonb #define BTINFO_BOOTPATH 2
48729eda43Ssimonb #define BTINFO_SYMTAB	3
49729eda43Ssimonb 
50729eda43Ssimonb struct btinfo_magic {
51729eda43Ssimonb 	struct btinfo_common common;
52729eda43Ssimonb 	int magic;
53729eda43Ssimonb };
54729eda43Ssimonb 
55729eda43Ssimonb #define BTINFO_BOOTPATH_LEN	80
56729eda43Ssimonb struct btinfo_bootpath {
57729eda43Ssimonb 	struct btinfo_common common;
58729eda43Ssimonb 	char bootpath[BTINFO_BOOTPATH_LEN];
59729eda43Ssimonb };
60729eda43Ssimonb 
61729eda43Ssimonb struct btinfo_symtab {
62729eda43Ssimonb 	struct btinfo_common common;
63729eda43Ssimonb 	int nsym;
64729eda43Ssimonb 	int ssym;
65729eda43Ssimonb 	int esym;
66729eda43Ssimonb };
67729eda43Ssimonb 
68729eda43Ssimonb #ifdef _KERNEL
69*02cdf4d2Sdsl void	*lookup_bootinfo(int);
70729eda43Ssimonb #endif
71838b5e08Sad 
72838b5e08Sad #endif	/* !_PMAX_BOOTINFO_H_ */
73