diff options
author | Atsushi Nemoto <anemo@mba.ocn.ne.jp> | 2006-01-28 12:31:17 -0500 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2006-02-07 08:30:24 -0500 |
commit | c315a2b5fed42aea4dda98b5ced35d1d1a3a8349 (patch) | |
tree | e5503c9619ab581fbdb6c716836bff6778943a9b /arch | |
parent | 76f072a46f179be371aa10a84c85db06a387713b (diff) |
[MIPS] Sparse: Add _MIPS_SZINT and _MIPS_ISA to CHECKFLAGS to fix sparse warnings.
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/mips/Makefile | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/arch/mips/Makefile b/arch/mips/Makefile index 9b53c59b269a..dee9bfebaf87 100644 --- a/arch/mips/Makefile +++ b/arch/mips/Makefile | |||
@@ -53,14 +53,17 @@ CROSS_COMPILE := $(tool-prefix) | |||
53 | endif | 53 | endif |
54 | 54 | ||
55 | CHECKFLAGS-y += -D__linux__ -D__mips__ \ | 55 | CHECKFLAGS-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 |
59 | CHECKFLAGS-$(CONFIG_32BIT) += -D_MIPS_SIM=_ABIO32 \ | 60 | CHECKFLAGS-$(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 |
62 | CHECKFLAGS-$(CONFIG_64BIT) += -m64 -D_MIPS_SIM=_ABI64 \ | 64 | CHECKFLAGS-$(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" |
65 | CHECKFLAGS-$(CONFIG_CPU_BIG_ENDIAN) += -D__MIPSEB__ | 68 | CHECKFLAGS-$(CONFIG_CPU_BIG_ENDIAN) += -D__MIPSEB__ |
66 | CHECKFLAGS-$(CONFIG_CPU_LITTLE_ENDIAN) += -D__MIPSEL__ | 69 | CHECKFLAGS-$(CONFIG_CPU_LITTLE_ENDIAN) += -D__MIPSEL__ |
@@ -166,79 +169,98 @@ echo $$gcc_abi $$gcc_opt$$gcc_cpu $$gcc_isa $$gas_abi $$gas_opt$$gas_cpu $$gas_i | |||
166 | # | 169 | # |
167 | cflags-$(CONFIG_CPU_R3000) += \ | 170 | cflags-$(CONFIG_CPU_R3000) += \ |
168 | $(call set_gccflags,r3000,mips1,r3000,mips1,mips1) | 171 | $(call set_gccflags,r3000,mips1,r3000,mips1,mips1) |
172 | CHECKFLAGS-$(CONFIG_CPU_R3000) += -D_MIPS_ISA=_MIPS_ISA_MIPS1 | ||
169 | 173 | ||
170 | cflags-$(CONFIG_CPU_TX39XX) += \ | 174 | cflags-$(CONFIG_CPU_TX39XX) += \ |
171 | $(call set_gccflags,r3900,mips1,r3000,mips1,mips1) | 175 | $(call set_gccflags,r3900,mips1,r3000,mips1,mips1) |
176 | CHECKFLAGS-$(CONFIG_CPU_TX39XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS1 | ||
172 | 177 | ||
173 | cflags-$(CONFIG_CPU_R6000) += \ | 178 | cflags-$(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 |
181 | CHECKFLAGS-$(CONFIG_CPU_R6000) += -D_MIPS_ISA=_MIPS_ISA_MIPS2 | ||
176 | 182 | ||
177 | cflags-$(CONFIG_CPU_R4300) += \ | 183 | cflags-$(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 |
186 | CHECKFLAGS-$(CONFIG_CPU_R4300) += -D_MIPS_ISA=_MIPS_ISA_MIPS3 | ||
180 | 187 | ||
181 | cflags-$(CONFIG_CPU_VR41XX) += \ | 188 | cflags-$(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 |
191 | CHECKFLAGS-$(CONFIG_CPU_VR41XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS3 | ||
184 | 192 | ||
185 | cflags-$(CONFIG_CPU_R4X00) += \ | 193 | cflags-$(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 |
196 | CHECKFLAGS-$(CONFIG_CPU_R4X00) += -D_MIPS_ISA=_MIPS_ISA_MIPS3 | ||
188 | 197 | ||
189 | cflags-$(CONFIG_CPU_TX49XX) += \ | 198 | cflags-$(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 |
201 | CHECKFLAGS-$(CONFIG_CPU_TX49XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS3 | ||
192 | 202 | ||
193 | cflags-$(CONFIG_CPU_MIPS32_R1) += \ | 203 | cflags-$(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 |
206 | CHECKFLAGS-$(CONFIG_CPU_MIPS32_R1) += -D_MIPS_ISA=_MIPS_ISA_MIPS32 | ||
196 | 207 | ||
197 | cflags-$(CONFIG_CPU_MIPS32_R2) += \ | 208 | cflags-$(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 |
211 | CHECKFLAGS-$(CONFIG_CPU_MIPS32_R2) += -D_MIPS_ISA=_MIPS_ISA_MIPS32 | ||
200 | 212 | ||
201 | cflags-$(CONFIG_CPU_MIPS64_R1) += \ | 213 | cflags-$(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 |
216 | CHECKFLAGS-$(CONFIG_CPU_MIPS64_R1) += -D_MIPS_ISA=_MIPS_ISA_MIPS64 | ||
204 | 217 | ||
205 | cflags-$(CONFIG_CPU_MIPS64_R2) += \ | 218 | cflags-$(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 |
221 | CHECKFLAGS-$(CONFIG_CPU_MIPS64_R2) += -D_MIPS_ISA=_MIPS_ISA_MIPS64 | ||
208 | 222 | ||
209 | cflags-$(CONFIG_CPU_R5000) += \ | 223 | cflags-$(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 |
226 | CHECKFLAGS-$(CONFIG_CPU_R5000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 | ||
212 | 227 | ||
213 | cflags-$(CONFIG_CPU_R5432) += \ | 228 | cflags-$(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 |
231 | CHECKFLAGS-$(CONFIG_CPU_R5432) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 | ||
216 | 232 | ||
217 | cflags-$(CONFIG_CPU_NEVADA) += \ | 233 | cflags-$(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) | 236 | # $(call cc-option,-mmad) |
237 | CHECKFLAGS-$(CONFIG_CPU_NEVADA) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 | ||
221 | 238 | ||
222 | cflags-$(CONFIG_CPU_RM7000) += \ | 239 | cflags-$(CONFIG_CPU_RM7000) += \ |
223 | $(call set_gccflags,rm7000,mips4,r5000,mips4,mips2) \ | 240 | $(call set_gccflags,rm7000,mips4,r5000,mips4,mips2) \ |
224 | -Wa,--trap | 241 | -Wa,--trap |
242 | CHECKFLAGS-$(CONFIG_CPU_RM7000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 | ||
225 | 243 | ||
226 | cflags-$(CONFIG_CPU_RM9000) += \ | 244 | cflags-$(CONFIG_CPU_RM9000) += \ |
227 | $(call set_gccflags,rm9000,mips4,r5000,mips4,mips2) \ | 245 | $(call set_gccflags,rm9000,mips4,r5000,mips4,mips2) \ |
228 | -Wa,--trap | 246 | -Wa,--trap |
247 | CHECKFLAGS-$(CONFIG_CPU_RM9000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 | ||
229 | 248 | ||
230 | 249 | ||
231 | cflags-$(CONFIG_CPU_SB1) += \ | 250 | cflags-$(CONFIG_CPU_SB1) += \ |
232 | $(call set_gccflags,sb1,mips64,r5000,mips4,mips2) \ | 251 | $(call set_gccflags,sb1,mips64,r5000,mips4,mips2) \ |
233 | -Wa,--trap | 252 | -Wa,--trap |
253 | CHECKFLAGS-$(CONFIG_CPU_SB1) += -D_MIPS_ISA=_MIPS_ISA_MIPS64 | ||
234 | 254 | ||
235 | cflags-$(CONFIG_CPU_R8000) += \ | 255 | cflags-$(CONFIG_CPU_R8000) += \ |
236 | $(call set_gccflags,r8000,mips4,r8000,mips4,mips2) \ | 256 | $(call set_gccflags,r8000,mips4,r8000,mips4,mips2) \ |
237 | -Wa,--trap | 257 | -Wa,--trap |
258 | CHECKFLAGS-$(CONFIG_CPU_R8000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 | ||
238 | 259 | ||
239 | cflags-$(CONFIG_CPU_R10000) += \ | 260 | cflags-$(CONFIG_CPU_R10000) += \ |
240 | $(call set_gccflags,r10000,mips4,r8000,mips4,mips2) \ | 261 | $(call set_gccflags,r10000,mips4,r8000,mips4,mips2) \ |
241 | -Wa,--trap | 262 | -Wa,--trap |
263 | CHECKFLAGS-$(CONFIG_CPU_R10000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 | ||
242 | 264 | ||
243 | ifdef CONFIG_CPU_SB1 | 265 | ifdef CONFIG_CPU_SB1 |
244 | ifdef CONFIG_SB1_PASS_1_WORKAROUNDS | 266 | ifdef CONFIG_SB1_PASS_1_WORKAROUNDS |