1
2
3
4
5
6
7
8
9
10
11
12#ifndef _ASM_BOOTINFO_H
13#define _ASM_BOOTINFO_H
14
15#include <linux/types.h>
16#include <asm/setup.h>
17
18
19
20
21
22
23
24
25
26
27#define MACH_UNKNOWN 0
28
29
30
31
32#define MACH_DSUNKNOWN 0
33#define MACH_DS23100 1
34#define MACH_DS5100 2
35#define MACH_DS5000_200 3
36#define MACH_DS5000_1XX 4
37#define MACH_DS5000_XX 5
38#define MACH_DS5000_2X0 6
39#define MACH_DS5400 7
40#define MACH_DS5500 8
41#define MACH_DS5800 9
42#define MACH_DS5900 10
43
44
45
46
47#define MACH_MSP4200_EVAL 0
48#define MACH_MSP4200_GW 1
49#define MACH_MSP4200_FPGA 2
50#define MACH_MSP7120_EVAL 3
51#define MACH_MSP7120_GW 4
52#define MACH_MSP7120_FPGA 5
53#define MACH_MSP_OTHER 255
54
55
56
57
58#define MACH_MIKROTIK_RB532 0
59#define MACH_MIKROTIK_RB532A 1
60
61
62
63
64enum loongson_machine_type {
65 MACH_LOONGSON_UNKNOWN,
66 MACH_LEMOTE_FL2E,
67 MACH_LEMOTE_FL2F,
68 MACH_LEMOTE_ML2F7,
69 MACH_LEMOTE_YL2F89,
70 MACH_DEXXON_GDIUM2F10,
71 MACH_LEMOTE_NAS,
72 MACH_LEMOTE_LL2F,
73 MACH_LOONGSON_GENERIC,
74 MACH_LOONGSON_END
75};
76
77
78
79
80#define MACH_INGENIC_JZ4730 0
81#define MACH_INGENIC_JZ4740 1
82
83extern char *system_type;
84const char *get_system_type(void);
85
86extern unsigned long mips_machtype;
87
88#define BOOT_MEM_MAP_MAX 32
89#define BOOT_MEM_RAM 1
90#define BOOT_MEM_ROM_DATA 2
91#define BOOT_MEM_RESERVED 3
92#define BOOT_MEM_INIT_RAM 4
93
94
95
96
97
98struct boot_mem_map {
99 int nr_map;
100 struct boot_mem_map_entry {
101 phys_addr_t addr;
102 phys_addr_t size;
103 long type;
104 } map[BOOT_MEM_MAP_MAX];
105};
106
107extern struct boot_mem_map boot_mem_map;
108
109extern void add_memory_region(phys_addr_t start, phys_addr_t size, long type);
110extern void detect_memory_region(phys_addr_t start, phys_addr_t sz_min, phys_addr_t sz_max);
111
112extern void prom_init(void);
113extern void prom_free_prom_memory(void);
114
115extern void free_init_pages(const char *what,
116 unsigned long begin, unsigned long end);
117
118extern void (*free_init_pages_eva)(void *begin, void *end);
119
120
121
122
123extern char arcs_cmdline[COMMAND_LINE_SIZE];
124
125
126
127
128extern unsigned long fw_arg0, fw_arg1, fw_arg2, fw_arg3;
129
130#ifdef CONFIG_USE_OF
131extern unsigned long fw_passed_dtb;
132#endif
133
134
135
136
137extern void plat_mem_setup(void);
138
139#ifdef CONFIG_SWIOTLB
140
141
142
143extern void plat_swiotlb_setup(void);
144
145#else
146
147static inline void plat_swiotlb_setup(void) {}
148
149#endif
150
151#ifdef CONFIG_USE_OF
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166extern void *plat_get_fdt(void);
167#endif
168
169#endif
170