aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mips/Makefile')
-rw-r--r--arch/mips/Makefile25
1 files changed, 23 insertions, 2 deletions
diff --git a/arch/mips/Makefile b/arch/mips/Makefile
index 2a9f2ef27b29..6a57407df1bc 100644
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
@@ -53,14 +53,17 @@ CROSS_COMPILE := $(tool-prefix)
53endif 53endif
54 54
55CHECKFLAGS-y += -D__linux__ -D__mips__ \ 55CHECKFLAGS-y += -D__linux__ -D__mips__ \
56 -D_MIPS_SZINT=32 \
56 -D_ABIO32=1 \ 57 -D_ABIO32=1 \
57 -D_ABIN32=2 \ 58 -D_ABIN32=2 \
58 -D_ABI64=3 59 -D_ABI64=3
59CHECKFLAGS-$(CONFIG_32BIT) += -D_MIPS_SIM=_ABIO32 \ 60CHECKFLAGS-$(CONFIG_32BIT) += -D_MIPS_SIM=_ABIO32 \
60 -D_MIPS_SZLONG=32 \ 61 -D_MIPS_SZLONG=32 \
62 -D_MIPS_SZPTR=32 \
61 -D__PTRDIFF_TYPE__=int 63 -D__PTRDIFF_TYPE__=int
62CHECKFLAGS-$(CONFIG_64BIT) += -m64 -D_MIPS_SIM=_ABI64 \ 64CHECKFLAGS-$(CONFIG_64BIT) += -m64 -D_MIPS_SIM=_ABI64 \
63 -D_MIPS_SZLONG=64 \ 65 -D_MIPS_SZLONG=64 \
66 -D_MIPS_SZPTR=64 \
64 -D__PTRDIFF_TYPE__="long int" 67 -D__PTRDIFF_TYPE__="long int"
65CHECKFLAGS-$(CONFIG_CPU_BIG_ENDIAN) += -D__MIPSEB__ 68CHECKFLAGS-$(CONFIG_CPU_BIG_ENDIAN) += -D__MIPSEB__
66CHECKFLAGS-$(CONFIG_CPU_LITTLE_ENDIAN) += -D__MIPSEL__ 69CHECKFLAGS-$(CONFIG_CPU_LITTLE_ENDIAN) += -D__MIPSEL__
@@ -166,79 +169,97 @@ echo $$gcc_abi $$gcc_opt$$gcc_cpu $$gcc_isa $$gas_abi $$gas_opt$$gas_cpu $$gas_i
166# 169#
167cflags-$(CONFIG_CPU_R3000) += \ 170cflags-$(CONFIG_CPU_R3000) += \
168 $(call set_gccflags,r3000,mips1,r3000,mips1,mips1) 171 $(call set_gccflags,r3000,mips1,r3000,mips1,mips1)
172CHECKFLAGS-$(CONFIG_CPU_R3000) += -D_MIPS_ISA=_MIPS_ISA_MIPS1
169 173
170cflags-$(CONFIG_CPU_TX39XX) += \ 174cflags-$(CONFIG_CPU_TX39XX) += \
171 $(call set_gccflags,r3900,mips1,r3000,mips1,mips1) 175 $(call set_gccflags,r3900,mips1,r3000,mips1,mips1)
176CHECKFLAGS-$(CONFIG_CPU_TX39XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS1
172 177
173cflags-$(CONFIG_CPU_R6000) += \ 178cflags-$(CONFIG_CPU_R6000) += \
174 $(call set_gccflags,r6000,mips2,r6000,mips2,mips2) \ 179 $(call set_gccflags,r6000,mips2,r6000,mips2,mips2) \
175 -Wa,--trap 180 -Wa,--trap
181CHECKFLAGS-$(CONFIG_CPU_R6000) += -D_MIPS_ISA=_MIPS_ISA_MIPS2
176 182
177cflags-$(CONFIG_CPU_R4300) += \ 183cflags-$(CONFIG_CPU_R4300) += \
178 $(call set_gccflags,r4300,mips3,r4300,mips3,mips2) \ 184 $(call set_gccflags,r4300,mips3,r4300,mips3,mips2) \
179 -Wa,--trap 185 -Wa,--trap
186CHECKFLAGS-$(CONFIG_CPU_R4300) += -D_MIPS_ISA=_MIPS_ISA_MIPS3
180 187
181cflags-$(CONFIG_CPU_VR41XX) += \ 188cflags-$(CONFIG_CPU_VR41XX) += \
182 $(call set_gccflags,r4100,mips3,r4600,mips3,mips2) \ 189 $(call set_gccflags,r4100,mips3,r4600,mips3,mips2) \
183 -Wa,--trap 190 -Wa,--trap
191CHECKFLAGS-$(CONFIG_CPU_VR41XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS3
184 192
185cflags-$(CONFIG_CPU_R4X00) += \ 193cflags-$(CONFIG_CPU_R4X00) += \
186 $(call set_gccflags,r4600,mips3,r4600,mips3,mips2) \ 194 $(call set_gccflags,r4600,mips3,r4600,mips3,mips2) \
187 -Wa,--trap 195 -Wa,--trap
196CHECKFLAGS-$(CONFIG_CPU_R4X00) += -D_MIPS_ISA=_MIPS_ISA_MIPS3
188 197
189cflags-$(CONFIG_CPU_TX49XX) += \ 198cflags-$(CONFIG_CPU_TX49XX) += \
190 $(call set_gccflags,r4600,mips3,r4600,mips3,mips2) \ 199 $(call set_gccflags,r4600,mips3,r4600,mips3,mips2) \
191 -Wa,--trap 200 -Wa,--trap
201CHECKFLAGS-$(CONFIG_CPU_TX49XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS3
192 202
193cflags-$(CONFIG_CPU_MIPS32_R1) += \ 203cflags-$(CONFIG_CPU_MIPS32_R1) += \
194 $(call set_gccflags,mips32,mips32,r4600,mips3,mips2) \ 204 $(call set_gccflags,mips32,mips32,r4600,mips3,mips2) \
195 -Wa,--trap 205 -Wa,--trap
206CHECKFLAGS-$(CONFIG_CPU_MIPS32_R1) += -D_MIPS_ISA=_MIPS_ISA_MIPS32
196 207
197cflags-$(CONFIG_CPU_MIPS32_R2) += \ 208cflags-$(CONFIG_CPU_MIPS32_R2) += \
198 $(call set_gccflags,mips32r2,mips32r2,r4600,mips3,mips2) \ 209 $(call set_gccflags,mips32r2,mips32r2,r4600,mips3,mips2) \
199 -Wa,--trap 210 -Wa,--trap
211CHECKFLAGS-$(CONFIG_CPU_MIPS32_R2) += -D_MIPS_ISA=_MIPS_ISA_MIPS32
200 212
201cflags-$(CONFIG_CPU_MIPS64_R1) += \ 213cflags-$(CONFIG_CPU_MIPS64_R1) += \
202 $(call set_gccflags,mips64,mips64,r4600,mips3,mips2) \ 214 $(call set_gccflags,mips64,mips64,r4600,mips3,mips2) \
203 -Wa,--trap 215 -Wa,--trap
216CHECKFLAGS-$(CONFIG_CPU_MIPS64_R1) += -D_MIPS_ISA=_MIPS_ISA_MIPS64
204 217
205cflags-$(CONFIG_CPU_MIPS64_R2) += \ 218cflags-$(CONFIG_CPU_MIPS64_R2) += \
206 $(call set_gccflags,mips64r2,mips64r2,r4600,mips3,mips2) \ 219 $(call set_gccflags,mips64r2,mips64r2,r4600,mips3,mips2) \
207 -Wa,--trap 220 -Wa,--trap
221CHECKFLAGS-$(CONFIG_CPU_MIPS64_R2) += -D_MIPS_ISA=_MIPS_ISA_MIPS64
208 222
209cflags-$(CONFIG_CPU_R5000) += \ 223cflags-$(CONFIG_CPU_R5000) += \
210 $(call set_gccflags,r5000,mips4,r5000,mips4,mips2) \ 224 $(call set_gccflags,r5000,mips4,r5000,mips4,mips2) \
211 -Wa,--trap 225 -Wa,--trap
226CHECKFLAGS-$(CONFIG_CPU_R5000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4
212 227
213cflags-$(CONFIG_CPU_R5432) += \ 228cflags-$(CONFIG_CPU_R5432) += \
214 $(call set_gccflags,r5400,mips4,r5000,mips4,mips2) \ 229 $(call set_gccflags,r5400,mips4,r5000,mips4,mips2) \
215 -Wa,--trap 230 -Wa,--trap
231CHECKFLAGS-$(CONFIG_CPU_R5432) += -D_MIPS_ISA=_MIPS_ISA_MIPS4
216 232
217cflags-$(CONFIG_CPU_NEVADA) += \ 233cflags-$(CONFIG_CPU_NEVADA) += \
218 $(call set_gccflags,rm5200,mips4,r5000,mips4,mips2) \ 234 $(call set_gccflags,rm5200,mips4,r5000,mips4,mips2) \
219 -Wa,--trap 235 -Wa,--trap
220# $(call cc-option,-mmad) 236CHECKFLAGS-$(CONFIG_CPU_NEVADA) += -D_MIPS_ISA=_MIPS_ISA_MIPS4
221 237
222cflags-$(CONFIG_CPU_RM7000) += \ 238cflags-$(CONFIG_CPU_RM7000) += \
223 $(call set_gccflags,rm7000,mips4,r5000,mips4,mips2) \ 239 $(call set_gccflags,rm7000,mips4,r5000,mips4,mips2) \
224 -Wa,--trap 240 -Wa,--trap
241CHECKFLAGS-$(CONFIG_CPU_RM7000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4
225 242
226cflags-$(CONFIG_CPU_RM9000) += \ 243cflags-$(CONFIG_CPU_RM9000) += \
227 $(call set_gccflags,rm9000,mips4,r5000,mips4,mips2) \ 244 $(call set_gccflags,rm9000,mips4,r5000,mips4,mips2) \
228 -Wa,--trap 245 -Wa,--trap
246CHECKFLAGS-$(CONFIG_CPU_RM9000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4
229 247
230 248
231cflags-$(CONFIG_CPU_SB1) += \ 249cflags-$(CONFIG_CPU_SB1) += \
232 $(call set_gccflags,sb1,mips64,r5000,mips4,mips2) \ 250 $(call set_gccflags,sb1,mips64,r5000,mips4,mips2) \
233 -Wa,--trap 251 -Wa,--trap
252CHECKFLAGS-$(CONFIG_CPU_SB1) += -D_MIPS_ISA=_MIPS_ISA_MIPS64
234 253
235cflags-$(CONFIG_CPU_R8000) += \ 254cflags-$(CONFIG_CPU_R8000) += \
236 $(call set_gccflags,r8000,mips4,r8000,mips4,mips2) \ 255 $(call set_gccflags,r8000,mips4,r8000,mips4,mips2) \
237 -Wa,--trap 256 -Wa,--trap
257CHECKFLAGS-$(CONFIG_CPU_R8000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4
238 258
239cflags-$(CONFIG_CPU_R10000) += \ 259cflags-$(CONFIG_CPU_R10000) += \
240 $(call set_gccflags,r10000,mips4,r8000,mips4,mips2) \ 260 $(call set_gccflags,r10000,mips4,r8000,mips4,mips2) \
241 -Wa,--trap 261 -Wa,--trap
262CHECKFLAGS-$(CONFIG_CPU_R10000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4
242 263
243ifdef CONFIG_CPU_SB1 264ifdef CONFIG_CPU_SB1
244ifdef CONFIG_SB1_PASS_1_WORKAROUNDS 265ifdef CONFIG_SB1_PASS_1_WORKAROUNDS
@@ -369,7 +390,7 @@ load-$(CONFIG_MIPS_XXS1500) += 0xffffffff80100000
369# Cobalt Server 390# Cobalt Server
370# 391#
371core-$(CONFIG_MIPS_COBALT) += arch/mips/cobalt/ 392core-$(CONFIG_MIPS_COBALT) += arch/mips/cobalt/
372cflags-$(CONFIG_MIPS_COBALT) += -Iinclude/asm-mips/cobalt 393cflags-$(CONFIG_MIPS_COBALT) += -Iinclude/asm-mips/mach-cobalt
373load-$(CONFIG_MIPS_COBALT) += 0xffffffff80080000 394load-$(CONFIG_MIPS_COBALT) += 0xffffffff80080000
374 395
375# 396#