File: /usr/src/linux/include/asm-arm/mach/arch.h
1 /*
2 * linux/include/asm-arm/mach/arch.h
3 *
4 * Copyright (C) 2000 Russell King
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 */
10
11 /*
12 * The size of struct machine_desc
13 * (for assembler code)
14 */
15 #define SIZEOF_MACHINE_DESC 48
16
17 #ifndef __ASSEMBLY__
18
19 extern void setup_initrd(unsigned int start, unsigned int size);
20 extern void setup_ramdisk(int doload, int prompt, int start, unsigned int rd_sz);
21
22 struct machine_desc {
23 /*
24 * Note! The first four elements are used
25 * by assembler code in head-armv.S
26 */
27 unsigned int nr; /* architecture number */
28 unsigned int phys_ram; /* start of physical ram */
29 unsigned int phys_io; /* start of physical io */
30 unsigned int virt_io; /* start of virtual io */
31
32 const char *name; /* architecture name */
33 unsigned int param_offset; /* parameter page */
34
35 unsigned int video_start; /* start of video RAM */
36 unsigned int video_end; /* end of video RAM */
37
38 unsigned int reserve_lp0 :1; /* never has lp0 */
39 unsigned int reserve_lp1 :1; /* never has lp1 */
40 unsigned int reserve_lp2 :1; /* never has lp2 */
41 unsigned int soft_reboot :1; /* soft reboot */
42 void (*fixup)(struct machine_desc *,
43 struct param_struct *, char **,
44 struct meminfo *);
45 void (*map_io)(void);/* IO mapping function */
46 void (*init_irq)(void);
47 };
48
49 /*
50 * Set of macros to define architecture features. This is built into
51 * a table by the linker.
52 */
53 #define MACHINE_START(_type,_name) \
54 const struct machine_desc __mach_desc_##_type \
55 __attribute__((__section__(".arch.info"))) = { \
56 nr: MACH_TYPE_##_type, \
57 name: _name,
58
59 #define MAINTAINER(n)
60
61 #define BOOT_MEM(_pram,_pio,_vio) \
62 phys_ram: _pram, \
63 phys_io: _pio, \
64 virt_io: _vio,
65
66 #define BOOT_PARAMS(_params) \
67 param_offset: _params,
68
69 #define VIDEO(_start,_end) \
70 video_start: _start, \
71 video_end: _end,
72
73 #define DISABLE_PARPORT(_n) \
74 reserve_lp##_n: 1,
75
76 #define BROKEN_HLT /* unused */
77
78 #define SOFT_REBOOT \
79 soft_reboot: 1,
80
81 #define FIXUP(_func) \
82 fixup: _func,
83
84 #define MAPIO(_func) \
85 map_io: _func,
86
87 #define INITIRQ(_func) \
88 init_irq: _func,
89
90 #define MACHINE_END \
91 };
92
93 #endif
94