aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Martin <dave.martin@linaro.org>2011-06-23 12:18:31 -0400
committerDave Martin <dave.martin@linaro.org>2011-07-07 10:31:07 -0400
commitc3be06eb587fedafe1efd33783d376157f96e5a6 (patch)
tree859ad5814b6b45d8ac3d0169b61355e6da37299b
parent5c9369bc2efe7d68f4dfdaa449f915f7cf6a8275 (diff)
ARM: mm: proc-arm6_7: Use the new processor struct macros
Signed-off-by: Dave Martin <dave.martin@linaro.org>
-rw-r--r--arch/arm/mm/proc-arm6_7.S166
1 files changed, 32 insertions, 134 deletions
diff --git a/arch/arm/mm/proc-arm6_7.S b/arch/arm/mm/proc-arm6_7.S
index 5f79dc4ce3fb..ebc0ca7f1a15 100644
--- a/arch/arm/mm/proc-arm6_7.S
+++ b/arch/arm/mm/proc-arm6_7.S
@@ -269,159 +269,57 @@ __arm7_setup: mov r0, #0
269 269
270 __INITDATA 270 __INITDATA
271 271
272/* 272 @ define struct processor (see <asm/proc-fns.h> and proc-macros.S)
273 * Purpose : Function pointers used to access above functions - all calls 273 define_processor_functions arm6, dabort=cpu_arm6_data_abort, pabort=legacy_pabort
274 * come through these 274 define_processor_functions arm7, dabort=cpu_arm7_data_abort, pabort=legacy_pabort
275 */
276 .type arm6_processor_functions, #object
277ENTRY(arm6_processor_functions)
278 .word cpu_arm6_data_abort
279 .word legacy_pabort
280 .word cpu_arm6_proc_init
281 .word cpu_arm6_proc_fin
282 .word cpu_arm6_reset
283 .word cpu_arm6_do_idle
284 .word cpu_arm6_dcache_clean_area
285 .word cpu_arm6_switch_mm
286 .word cpu_arm6_set_pte_ext
287 .word 0
288 .word 0
289 .word 0
290 .size arm6_processor_functions, . - arm6_processor_functions
291
292/*
293 * Purpose : Function pointers used to access above functions - all calls
294 * come through these
295 */
296 .type arm7_processor_functions, #object
297ENTRY(arm7_processor_functions)
298 .word cpu_arm7_data_abort
299 .word legacy_pabort
300 .word cpu_arm7_proc_init
301 .word cpu_arm7_proc_fin
302 .word cpu_arm7_reset
303 .word cpu_arm7_do_idle
304 .word cpu_arm7_dcache_clean_area
305 .word cpu_arm7_switch_mm
306 .word cpu_arm7_set_pte_ext
307 .word 0
308 .word 0
309 .word 0
310 .size arm7_processor_functions, . - arm7_processor_functions
311 275
312 .section ".rodata" 276 .section ".rodata"
313 277
314 .type cpu_arch_name, #object 278 string cpu_arch_name, "armv3"
315cpu_arch_name: .asciz "armv3" 279 string cpu_elf_name, "v3"
316 .size cpu_arch_name, . - cpu_arch_name 280 string cpu_arm6_name, "ARM6"
317 281 string cpu_arm610_name, "ARM610"
318 .type cpu_elf_name, #object 282 string cpu_arm7_name, "ARM7"
319cpu_elf_name: .asciz "v3" 283 string cpu_arm710_name, "ARM710"
320 .size cpu_elf_name, . - cpu_elf_name
321
322 .type cpu_arm6_name, #object
323cpu_arm6_name: .asciz "ARM6"
324 .size cpu_arm6_name, . - cpu_arm6_name
325
326 .type cpu_arm610_name, #object
327cpu_arm610_name:
328 .asciz "ARM610"
329 .size cpu_arm610_name, . - cpu_arm610_name
330
331 .type cpu_arm7_name, #object
332cpu_arm7_name: .asciz "ARM7"
333 .size cpu_arm7_name, . - cpu_arm7_name
334
335 .type cpu_arm710_name, #object
336cpu_arm710_name:
337 .asciz "ARM710"
338 .size cpu_arm710_name, . - cpu_arm710_name
339 284
340 .align 285 .align
341 286
342 .section ".proc.info.init", #alloc, #execinstr 287 .section ".proc.info.init", #alloc, #execinstr
343 288
344 .type __arm6_proc_info, #object 289.macro arm67_proc_info name:req, cpu_val:req, cpu_mask:req, cpu_name:req, \
345__arm6_proc_info: 290 cpu_mm_mmu_flags:req, cpu_flush:req, cpu_proc_funcs:req
346 .long 0x41560600 291 .type __\name\()_proc_info, #object
347 .long 0xfffffff0 292__\name\()_proc_info:
348 .long 0x00000c1e 293 .long \cpu_val
294 .long \cpu_mask
295 .long \cpu_mm_mmu_flags
349 .long PMD_TYPE_SECT | \ 296 .long PMD_TYPE_SECT | \
350 PMD_BIT4 | \ 297 PMD_BIT4 | \
351 PMD_SECT_AP_WRITE | \ 298 PMD_SECT_AP_WRITE | \
352 PMD_SECT_AP_READ 299 PMD_SECT_AP_READ
353 b __arm6_setup 300 b \cpu_flush
354 .long cpu_arch_name 301 .long cpu_arch_name
355 .long cpu_elf_name 302 .long cpu_elf_name
356 .long HWCAP_SWP | HWCAP_26BIT 303 .long HWCAP_SWP | HWCAP_26BIT
357 .long cpu_arm6_name 304 .long \cpu_name
358 .long arm6_processor_functions 305 .long \cpu_proc_funcs
359 .long v3_tlb_fns 306 .long v3_tlb_fns
360 .long v3_user_fns 307 .long v3_user_fns
361 .long v3_cache_fns 308 .long v3_cache_fns
362 .size __arm6_proc_info, . - __arm6_proc_info 309 .size __\name\()_proc_info, . - __\name\()_proc_info
363 310.endm
364 .type __arm610_proc_info, #object 311
365__arm610_proc_info: 312 arm67_proc_info arm6, 0x41560600, 0xfffffff0, cpu_arm6_name, \
366 .long 0x41560610 313 0x00000c1e, __arm6_setup, arm6_processor_functions
367 .long 0xfffffff0 314 arm67_proc_info arm610, 0x41560610, 0xfffffff0, cpu_arm610_name, \
368 .long 0x00000c1e 315 0x00000c1e, __arm6_setup, arm6_processor_functions
369 .long PMD_TYPE_SECT | \ 316 arm67_proc_info arm7, 0x41007000, 0xffffff00, cpu_arm7_name, \
370 PMD_BIT4 | \ 317 0x00000c1e, __arm7_setup, arm7_processor_functions
371 PMD_SECT_AP_WRITE | \ 318 arm67_proc_info arm710, 0x41007100, 0xfff8ff00, cpu_arm710_name, \
372 PMD_SECT_AP_READ 319 PMD_TYPE_SECT | \
373 b __arm6_setup
374 .long cpu_arch_name
375 .long cpu_elf_name
376 .long HWCAP_SWP | HWCAP_26BIT
377 .long cpu_arm610_name
378 .long arm6_processor_functions
379 .long v3_tlb_fns
380 .long v3_user_fns
381 .long v3_cache_fns
382 .size __arm610_proc_info, . - __arm610_proc_info
383
384 .type __arm7_proc_info, #object
385__arm7_proc_info:
386 .long 0x41007000
387 .long 0xffffff00
388 .long 0x00000c1e
389 .long PMD_TYPE_SECT | \
390 PMD_BIT4 | \
391 PMD_SECT_AP_WRITE | \
392 PMD_SECT_AP_READ
393 b __arm7_setup
394 .long cpu_arch_name
395 .long cpu_elf_name
396 .long HWCAP_SWP | HWCAP_26BIT
397 .long cpu_arm7_name
398 .long arm7_processor_functions
399 .long v3_tlb_fns
400 .long v3_user_fns
401 .long v3_cache_fns
402 .size __arm7_proc_info, . - __arm7_proc_info
403
404 .type __arm710_proc_info, #object
405__arm710_proc_info:
406 .long 0x41007100
407 .long 0xfff8ff00
408 .long PMD_TYPE_SECT | \
409 PMD_SECT_BUFFERABLE | \ 320 PMD_SECT_BUFFERABLE | \
410 PMD_SECT_CACHEABLE | \ 321 PMD_SECT_CACHEABLE | \
411 PMD_BIT4 | \ 322 PMD_BIT4 | \
412 PMD_SECT_AP_WRITE | \ 323 PMD_SECT_AP_WRITE | \
413 PMD_SECT_AP_READ 324 PMD_SECT_AP_READ, \
414 .long PMD_TYPE_SECT | \ 325 __arm7_setup, arm7_processor_functions
415 PMD_BIT4 | \
416 PMD_SECT_AP_WRITE | \
417 PMD_SECT_AP_READ
418 b __arm7_setup
419 .long cpu_arch_name
420 .long cpu_elf_name
421 .long HWCAP_SWP | HWCAP_26BIT
422 .long cpu_arm710_name
423 .long arm7_processor_functions
424 .long v3_tlb_fns
425 .long v3_user_fns
426 .long v3_cache_fns
427 .size __arm710_proc_info, . - __arm710_proc_info