diff options
-rw-r--r-- | include/asm-mips/sn/addrs.h | 5 | ||||
-rw-r--r-- | include/asm-mips/sn/klconfig.h | 50 | ||||
-rw-r--r-- | include/asm-mips/sn/kldir.h | 30 |
3 files changed, 2 insertions, 83 deletions
diff --git a/include/asm-mips/sn/addrs.h b/include/asm-mips/sn/addrs.h index 2b5cef1ba37f..00da24f506f6 100644 --- a/include/asm-mips/sn/addrs.h +++ b/include/asm-mips/sn/addrs.h | |||
@@ -27,13 +27,8 @@ | |||
27 | 27 | ||
28 | #ifndef __ASSEMBLY__ | 28 | #ifndef __ASSEMBLY__ |
29 | 29 | ||
30 | #if defined(CONFIG_SGI_IO) /* FIXME */ | ||
31 | #define PS_UINT_CAST (__psunsigned_t) | ||
32 | #define UINT64_CAST (__uint64_t) | ||
33 | #else /* CONFIG_SGI_IO */ | ||
34 | #define PS_UINT_CAST (unsigned long) | 30 | #define PS_UINT_CAST (unsigned long) |
35 | #define UINT64_CAST (unsigned long) | 31 | #define UINT64_CAST (unsigned long) |
36 | #endif /* CONFIG_SGI_IO */ | ||
37 | 32 | ||
38 | #define HUBREG_CAST (volatile hubreg_t *) | 33 | #define HUBREG_CAST (volatile hubreg_t *) |
39 | 34 | ||
diff --git a/include/asm-mips/sn/klconfig.h b/include/asm-mips/sn/klconfig.h index 9709ff701d9b..19ece28c5e8b 100644 --- a/include/asm-mips/sn/klconfig.h +++ b/include/asm-mips/sn/klconfig.h | |||
@@ -54,12 +54,12 @@ | |||
54 | #include <asm/sn/agent.h> | 54 | #include <asm/sn/agent.h> |
55 | #include <asm/arc/types.h> | 55 | #include <asm/arc/types.h> |
56 | #include <asm/arc/hinv.h> | 56 | #include <asm/arc/hinv.h> |
57 | #if defined(CONFIG_SGI_IO) || defined(CONFIG_SGI_IP35) | 57 | #if defined(CONFIG_SGI_IP35) |
58 | // The hack file has to be before vector and after sn0_fru.... | 58 | // The hack file has to be before vector and after sn0_fru.... |
59 | #include <asm/hack.h> | 59 | #include <asm/hack.h> |
60 | #include <asm/sn/vector.h> | 60 | #include <asm/sn/vector.h> |
61 | #include <asm/xtalk/xtalk.h> | 61 | #include <asm/xtalk/xtalk.h> |
62 | #endif /* CONFIG_SGI_IO || CONFIG_SGI_IP35 */ | 62 | #endif /* CONFIG_SGI_IP35 */ |
63 | #endif /* CONFIG_SGI_IP27 || CONFIG_SGI_IP35 */ | 63 | #endif /* CONFIG_SGI_IP27 || CONFIG_SGI_IP35 */ |
64 | 64 | ||
65 | #define KLCFGINFO_MAGIC 0xbeedbabe | 65 | #define KLCFGINFO_MAGIC 0xbeedbabe |
@@ -134,15 +134,9 @@ typedef s32 klconf_off_t; | |||
134 | 134 | ||
135 | 135 | ||
136 | typedef struct console_s { | 136 | typedef struct console_s { |
137 | #if defined(CONFIG_SGI_IO) /* FIXME */ | ||
138 | __psunsigned_t uart_base; | ||
139 | __psunsigned_t config_base; | ||
140 | __psunsigned_t memory_base; | ||
141 | #else | ||
142 | unsigned long uart_base; | 137 | unsigned long uart_base; |
143 | unsigned long config_base; | 138 | unsigned long config_base; |
144 | unsigned long memory_base; | 139 | unsigned long memory_base; |
145 | #endif | ||
146 | short baud; | 140 | short baud; |
147 | short flag; | 141 | short flag; |
148 | int type; | 142 | int type; |
@@ -197,23 +191,13 @@ typedef struct kl_config_hdr { | |||
197 | 191 | ||
198 | /* --- New Macros for the changed kl_config_hdr_t structure --- */ | 192 | /* --- New Macros for the changed kl_config_hdr_t structure --- */ |
199 | 193 | ||
200 | #if defined(CONFIG_SGI_IO) | ||
201 | #define PTR_CH_MALLOC_HDR(_k) ((klc_malloc_hdr_t *)\ | ||
202 | ((__psunsigned_t)_k + (_k->ch_malloc_hdr_off))) | ||
203 | #else | ||
204 | #define PTR_CH_MALLOC_HDR(_k) ((klc_malloc_hdr_t *)\ | 194 | #define PTR_CH_MALLOC_HDR(_k) ((klc_malloc_hdr_t *)\ |
205 | (unsigned long)_k + (_k->ch_malloc_hdr_off))) | 195 | (unsigned long)_k + (_k->ch_malloc_hdr_off))) |
206 | #endif | ||
207 | 196 | ||
208 | #define KL_CONFIG_CH_MALLOC_HDR(_n) PTR_CH_MALLOC_HDR(KL_CONFIG_HDR(_n)) | 197 | #define KL_CONFIG_CH_MALLOC_HDR(_n) PTR_CH_MALLOC_HDR(KL_CONFIG_HDR(_n)) |
209 | 198 | ||
210 | #if defined(CONFIG_SGI_IO) | ||
211 | #define PTR_CH_CONS_INFO(_k) ((console_t *)\ | ||
212 | ((__psunsigned_t)_k + (_k->ch_cons_off))) | ||
213 | #else | ||
214 | #define PTR_CH_CONS_INFO(_k) ((console_t *)\ | 199 | #define PTR_CH_CONS_INFO(_k) ((console_t *)\ |
215 | ((unsigned long)_k + (_k->ch_cons_off))) | 200 | ((unsigned long)_k + (_k->ch_cons_off))) |
216 | #endif | ||
217 | 201 | ||
218 | #define KL_CONFIG_CH_CONS_INFO(_n) PTR_CH_CONS_INFO(KL_CONFIG_HDR(_n)) | 202 | #define KL_CONFIG_CH_CONS_INFO(_n) PTR_CH_CONS_INFO(KL_CONFIG_HDR(_n)) |
219 | 203 | ||
@@ -945,36 +929,6 @@ extern klcpu_t *nasid_slice_to_cpuinfo(nasid_t, int); | |||
945 | extern lboard_t *find_lboard_class(lboard_t *start, unsigned char brd_class); | 929 | extern lboard_t *find_lboard_class(lboard_t *start, unsigned char brd_class); |
946 | 930 | ||
947 | 931 | ||
948 | #if defined(CONFIG_SGI_IO) | ||
949 | extern xwidgetnum_t nodevertex_widgetnum_get(vertex_hdl_t node_vtx); | ||
950 | extern vertex_hdl_t nodevertex_xbow_peer_get(vertex_hdl_t node_vtx); | ||
951 | extern lboard_t *find_gfxpipe(int pipenum); | ||
952 | extern void setup_gfxpipe_link(vertex_hdl_t vhdl,int pipenum); | ||
953 | extern lboard_t *find_lboard_module_class(lboard_t *start, moduleid_t mod, | ||
954 | unsigned char brd_class); | ||
955 | extern lboard_t *find_nic_lboard(lboard_t *, nic_t); | ||
956 | extern lboard_t *find_nic_type_lboard(nasid_t, unsigned char, nic_t); | ||
957 | extern lboard_t *find_lboard_modslot(lboard_t *start, moduleid_t mod, slotid_t slot); | ||
958 | extern lboard_t *find_lboard_module(lboard_t *start, moduleid_t mod); | ||
959 | extern lboard_t *get_board_name(nasid_t nasid, moduleid_t mod, slotid_t slot, char *name); | ||
960 | extern int config_find_nic_router(nasid_t, nic_t, lboard_t **, klrou_t**); | ||
961 | extern int config_find_nic_hub(nasid_t, nic_t, lboard_t **, klhub_t**); | ||
962 | extern int config_find_xbow(nasid_t, lboard_t **, klxbow_t**); | ||
963 | extern klcpu_t *get_cpuinfo(cpuid_t cpu); | ||
964 | extern int update_klcfg_cpuinfo(nasid_t, int); | ||
965 | extern void board_to_path(lboard_t *brd, char *path); | ||
966 | extern moduleid_t get_module_id(nasid_t nasid); | ||
967 | extern void nic_name_convert(char *old_name, char *new_name); | ||
968 | extern int module_brds(nasid_t nasid, lboard_t **module_brds, int n); | ||
969 | extern lboard_t *brd_from_key(ulong_t key); | ||
970 | extern void device_component_canonical_name_get(lboard_t *,klinfo_t *, | ||
971 | char *); | ||
972 | extern int board_serial_number_get(lboard_t *,char *); | ||
973 | extern int is_master_baseio(nasid_t,moduleid_t,slotid_t); | ||
974 | extern nasid_t get_actual_nasid(lboard_t *brd) ; | ||
975 | extern net_vec_t klcfg_discover_route(lboard_t *, lboard_t *, int); | ||
976 | #else /* CONFIG_SGI_IO */ | ||
977 | extern klcpu_t *sn_get_cpuinfo(cpuid_t cpu); | 932 | extern klcpu_t *sn_get_cpuinfo(cpuid_t cpu); |
978 | #endif /* CONFIG_SGI_IO */ | ||
979 | 933 | ||
980 | #endif /* _ASM_SN_KLCONFIG_H */ | 934 | #endif /* _ASM_SN_KLCONFIG_H */ |
diff --git a/include/asm-mips/sn/kldir.h b/include/asm-mips/sn/kldir.h index f0efab1672ec..fa40e6794f82 100644 --- a/include/asm-mips/sn/kldir.h +++ b/include/asm-mips/sn/kldir.h | |||
@@ -13,10 +13,6 @@ | |||
13 | 13 | ||
14 | #include <linux/config.h> | 14 | #include <linux/config.h> |
15 | 15 | ||
16 | #if defined(CONFIG_SGI_IO) | ||
17 | #include <asm/hack.h> | ||
18 | #endif | ||
19 | |||
20 | /* | 16 | /* |
21 | * The kldir memory area resides at a fixed place in each node's memory and | 17 | * The kldir memory area resides at a fixed place in each node's memory and |
22 | * provides pointers to most other IP27 memory areas. This allows us to | 18 | * provides pointers to most other IP27 memory areas. This allows us to |
@@ -136,8 +132,6 @@ | |||
136 | #define KLDIR_OFF_STRIDE 0x28 | 132 | #define KLDIR_OFF_STRIDE 0x28 |
137 | #endif /* __ASSEMBLY__ */ | 133 | #endif /* __ASSEMBLY__ */ |
138 | 134 | ||
139 | #if !defined(CONFIG_SGI_IO) | ||
140 | |||
141 | /* | 135 | /* |
142 | * This is defined here because IP27_SYMMON_STK_SIZE must be at least what | 136 | * This is defined here because IP27_SYMMON_STK_SIZE must be at least what |
143 | * we define here. Since it's set up in the prom. We can't redefine it later | 137 | * we define here. Since it's set up in the prom. We can't redefine it later |
@@ -207,17 +201,11 @@ | |||
207 | #define KLDIR_ENT_SIZE 0x40 | 201 | #define KLDIR_ENT_SIZE 0x40 |
208 | #define KLDIR_MAX_ENTRIES (0x400 / 0x40) | 202 | #define KLDIR_MAX_ENTRIES (0x400 / 0x40) |
209 | 203 | ||
210 | #endif /* !CONFIG_SGI_IO */ | ||
211 | |||
212 | #ifndef __ASSEMBLY__ | 204 | #ifndef __ASSEMBLY__ |
213 | typedef struct kldir_ent_s { | 205 | typedef struct kldir_ent_s { |
214 | u64 magic; /* Indicates validity of entry */ | 206 | u64 magic; /* Indicates validity of entry */ |
215 | off_t offset; /* Offset from start of node space */ | 207 | off_t offset; /* Offset from start of node space */ |
216 | #if defined(CONFIG_SGI_IO) /* FIXME */ | ||
217 | __psunsigned_t pointer; /* Pointer to area in some cases */ | ||
218 | #else | ||
219 | unsigned long pointer; /* Pointer to area in some cases */ | 208 | unsigned long pointer; /* Pointer to area in some cases */ |
220 | #endif | ||
221 | size_t size; /* Size in bytes */ | 209 | size_t size; /* Size in bytes */ |
222 | u64 count; /* Repeat count if array, 1 if not */ | 210 | u64 count; /* Repeat count if array, 1 if not */ |
223 | size_t stride; /* Stride if array, 0 if not */ | 211 | size_t stride; /* Stride if array, 0 if not */ |
@@ -227,22 +215,4 @@ typedef struct kldir_ent_s { | |||
227 | } kldir_ent_t; | 215 | } kldir_ent_t; |
228 | #endif /* !__ASSEMBLY__ */ | 216 | #endif /* !__ASSEMBLY__ */ |
229 | 217 | ||
230 | #if defined(CONFIG_SGI_IO) | ||
231 | |||
232 | #define KLDIR_ENT_SIZE 0x40 | ||
233 | #define KLDIR_MAX_ENTRIES (0x400 / 0x40) | ||
234 | |||
235 | /* | ||
236 | * The actual offsets of each memory area are machine-dependent | ||
237 | */ | ||
238 | #ifdef CONFIG_SGI_IP27 | ||
239 | // Not yet #include <asm/sn/sn0/kldir.h> | ||
240 | #elif defined(CONFIG_SGI_IP35) | ||
241 | #include <asm/sn/sn1/kldir.h> | ||
242 | #else | ||
243 | #error "kldir.h is currently defined for IP27 and IP35 platforms only" | ||
244 | #endif | ||
245 | |||
246 | #endif /* CONFIG_SGI_IO */ | ||
247 | |||
248 | #endif /* _ASM_SN_KLDIR_H */ | 218 | #endif /* _ASM_SN_KLDIR_H */ |