1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24#ifndef _M68K_BOOTINFO_H
25#define _M68K_BOOTINFO_H
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41#ifndef __ASSEMBLY__
42
43struct bi_record {
44 unsigned short tag;
45 unsigned short size;
46 unsigned long data[0];
47};
48
49#endif
50
51
52
53
54
55
56
57
58
59#define BI_LAST 0x0000
60#define BI_MACHTYPE 0x0001
61#define BI_CPUTYPE 0x0002
62#define BI_FPUTYPE 0x0003
63#define BI_MMUTYPE 0x0004
64#define BI_MEMCHUNK 0x0005
65
66#define BI_RAMDISK 0x0006
67
68#define BI_COMMAND_LINE 0x0007
69
70
71
72
73
74
75#define BI_AMIGA_MODEL 0x8000
76#define BI_AMIGA_AUTOCON 0x8001
77
78#define BI_AMIGA_CHIP_SIZE 0x8002
79#define BI_AMIGA_VBLANK 0x8003
80#define BI_AMIGA_PSFREQ 0x8004
81#define BI_AMIGA_ECLOCK 0x8005
82#define BI_AMIGA_CHIPSET 0x8006
83#define BI_AMIGA_SERPER 0x8007
84
85
86
87
88
89#define BI_ATARI_MCH_COOKIE 0x8000
90#define BI_ATARI_MCH_TYPE 0x8001
91
92
93
94#define ATARI_MCH_ST 0
95#define ATARI_MCH_STE 1
96#define ATARI_MCH_TT 2
97#define ATARI_MCH_FALCON 3
98
99
100#define ATARI_MACH_NORMAL 0
101#define ATARI_MACH_MEDUSA 1
102#define ATARI_MACH_HADES 2
103#define ATARI_MACH_AB40 3
104
105
106
107
108
109#define BI_VME_TYPE 0x8000
110#define BI_VME_BRDINFO 0x8001
111
112
113#define VME_TYPE_TP34V 0x0034
114#define VME_TYPE_MVME147 0x0147
115#define VME_TYPE_MVME162 0x0162
116#define VME_TYPE_MVME166 0x0166
117#define VME_TYPE_MVME167 0x0167
118#define VME_TYPE_MVME172 0x0172
119#define VME_TYPE_MVME177 0x0177
120#define VME_TYPE_BVME4000 0x4000
121#define VME_TYPE_BVME6000 0x6000
122
123
124
125
126
127
128
129
130
131
132
133#define BI_MAC_MODEL 0x8000
134#define BI_MAC_VADDR 0x8001
135#define BI_MAC_VDEPTH 0x8002
136#define BI_MAC_VROW 0x8003
137#define BI_MAC_VDIM 0x8004
138#define BI_MAC_VLOGICAL 0x8005
139#define BI_MAC_SCCBASE 0x8006
140#define BI_MAC_BTIME 0x8007
141#define BI_MAC_GMTBIAS 0x8008
142#define BI_MAC_MEMSIZE 0x8009
143#define BI_MAC_CPUID 0x800a
144#define BI_MAC_ROMBASE 0x800b
145
146
147
148
149
150
151#define BI_MAC_VIA1BASE 0x8010
152#define BI_MAC_VIA2BASE 0x8011
153#define BI_MAC_VIA2TYPE 0x8012
154#define BI_MAC_ADBTYPE 0x8013
155#define BI_MAC_ASCBASE 0x8014
156#define BI_MAC_SCSI5380 0x8015
157#define BI_MAC_SCSIDMA 0x8016
158#define BI_MAC_SCSI5396 0x8017
159#define BI_MAC_IDETYPE 0x8018
160#define BI_MAC_IDEBASE 0x8019
161#define BI_MAC_NUBUS 0x801a
162#define BI_MAC_SLOTMASK 0x801b
163#define BI_MAC_SCCTYPE 0x801c
164#define BI_MAC_ETHTYPE 0x801d
165#define BI_MAC_ETHBASE 0x801e
166#define BI_MAC_PMU 0x801f
167#define BI_MAC_IOP_SWIM 0x8020
168#define BI_MAC_IOP_ADB 0x8021
169
170
171
172
173
174
175
176
177#ifndef __ASSEMBLY__
178
179struct mac_booter_data
180{
181 unsigned long videoaddr;
182 unsigned long videorow;
183 unsigned long videodepth;
184 unsigned long dimensions;
185 unsigned long args;
186 unsigned long boottime;
187 unsigned long gmtbias;
188 unsigned long bootver;
189 unsigned long videological;
190 unsigned long sccbase;
191 unsigned long id;
192 unsigned long memsize;
193 unsigned long serialmf;
194 unsigned long serialhsk;
195 unsigned long serialgpi;
196 unsigned long printmf;
197 unsigned long printhsk;
198 unsigned long printgpi;
199 unsigned long cpuid;
200 unsigned long rombase;
201 unsigned long adbdelay;
202 unsigned long timedbra;
203};
204
205extern struct mac_booter_data
206 mac_bi_data;
207
208#endif
209
210
211
212
213
214#define BI_APOLLO_MODEL 0x8000
215
216
217
218
219
220#define BI_HP300_MODEL 0x8000
221#define BI_HP300_UART_SCODE 0x8001
222#define BI_HP300_UART_ADDR 0x8002
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239#define BOOTINFOV_MAGIC 0x4249561A
240#define MK_BI_VERSION(major,minor) (((major)<<16)+(minor))
241#define BI_VERSION_MAJOR(v) (((v) >> 16) & 0xffff)
242#define BI_VERSION_MINOR(v) ((v) & 0xffff)
243
244#ifndef __ASSEMBLY__
245
246struct bootversion {
247 unsigned short branch;
248 unsigned long magic;
249 struct {
250 unsigned long machtype;
251 unsigned long version;
252 } machversions[0];
253};
254
255#endif
256
257#define AMIGA_BOOTI_VERSION MK_BI_VERSION( 2, 0 )
258#define ATARI_BOOTI_VERSION MK_BI_VERSION( 2, 1 )
259#define MAC_BOOTI_VERSION MK_BI_VERSION( 2, 0 )
260#define MVME147_BOOTI_VERSION MK_BI_VERSION( 2, 0 )
261#define MVME16x_BOOTI_VERSION MK_BI_VERSION( 2, 0 )
262#define BVME6000_BOOTI_VERSION MK_BI_VERSION( 2, 0 )
263#define Q40_BOOTI_VERSION MK_BI_VERSION( 2, 0 )
264#define HP300_BOOTI_VERSION MK_BI_VERSION( 2, 0 )
265
266#ifdef BOOTINFO_COMPAT_1_0
267
268
269
270
271
272#define COMPAT_AMIGA_BOOTI_VERSION MK_BI_VERSION( 1, 0 )
273#define COMPAT_ATARI_BOOTI_VERSION MK_BI_VERSION( 1, 0 )
274#define COMPAT_MAC_BOOTI_VERSION MK_BI_VERSION( 1, 0 )
275
276#include <linux/zorro.h>
277
278#define COMPAT_NUM_AUTO 16
279
280struct compat_bi_Amiga {
281 int model;
282 int num_autocon;
283 struct ConfigDev autocon[COMPAT_NUM_AUTO];
284 unsigned long chip_size;
285 unsigned char vblank;
286 unsigned char psfreq;
287 unsigned long eclock;
288 unsigned long chipset;
289 unsigned long hw_present;
290};
291
292struct compat_bi_Atari {
293 unsigned long hw_present;
294 unsigned long mch_cookie;
295};
296
297#ifndef __ASSEMBLY__
298
299struct compat_bi_Macintosh
300{
301 unsigned long videoaddr;
302 unsigned long videorow;
303 unsigned long videodepth;
304 unsigned long dimensions;
305 unsigned long args;
306 unsigned long boottime;
307 unsigned long gmtbias;
308 unsigned long bootver;
309 unsigned long videological;
310 unsigned long sccbase;
311 unsigned long id;
312 unsigned long memsize;
313 unsigned long serialmf;
314 unsigned long serialhsk;
315 unsigned long serialgpi;
316 unsigned long printmf;
317 unsigned long printhsk;
318 unsigned long printgpi;
319 unsigned long cpuid;
320 unsigned long rombase;
321 unsigned long adbdelay;
322 unsigned long timedbra;
323};
324
325#endif
326
327struct compat_mem_info {
328 unsigned long addr;
329 unsigned long size;
330};
331
332#define COMPAT_NUM_MEMINFO 4
333
334#define COMPAT_CPUB_68020 0
335#define COMPAT_CPUB_68030 1
336#define COMPAT_CPUB_68040 2
337#define COMPAT_CPUB_68060 3
338#define COMPAT_FPUB_68881 5
339#define COMPAT_FPUB_68882 6
340#define COMPAT_FPUB_68040 7
341#define COMPAT_FPUB_68060 8
342
343#define COMPAT_CPU_68020 (1<<COMPAT_CPUB_68020)
344#define COMPAT_CPU_68030 (1<<COMPAT_CPUB_68030)
345#define COMPAT_CPU_68040 (1<<COMPAT_CPUB_68040)
346#define COMPAT_CPU_68060 (1<<COMPAT_CPUB_68060)
347#define COMPAT_CPU_MASK (31)
348#define COMPAT_FPU_68881 (1<<COMPAT_FPUB_68881)
349#define COMPAT_FPU_68882 (1<<COMPAT_FPUB_68882)
350#define COMPAT_FPU_68040 (1<<COMPAT_FPUB_68040)
351#define COMPAT_FPU_68060 (1<<COMPAT_FPUB_68060)
352#define COMPAT_FPU_MASK (0xfe0)
353
354#define COMPAT_CL_SIZE (256)
355
356struct compat_bootinfo {
357 unsigned long machtype;
358 unsigned long cputype;
359 struct compat_mem_info memory[COMPAT_NUM_MEMINFO];
360 int num_memory;
361 unsigned long ramdisk_size;
362 unsigned long ramdisk_addr;
363 char command_line[COMPAT_CL_SIZE];
364 union {
365 struct compat_bi_Amiga bi_ami;
366 struct compat_bi_Atari bi_ata;
367 struct compat_bi_Macintosh bi_mac;
368 } bi_un;
369};
370
371#define bi_amiga bi_un.bi_ami
372#define bi_atari bi_un.bi_ata
373#define bi_mac bi_un.bi_mac
374
375#endif
376
377
378#endif
379