From: dave.martin@linaro.org (Dave Martin)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v3 32/40] Subject: ARM: mm: proc-xsc3: Use new generic struct definition macros
Date: Thu, 23 Jun 2011 18:50:40 +0100 [thread overview]
Message-ID: <1308851448-25139-33-git-send-email-dave.martin@linaro.org> (raw)
In-Reply-To: <1308851448-25139-1-git-send-email-dave.martin@linaro.org>
Signed-off-by: Dave Martin <dave.martin@linaro.org>
---
arch/arm/mm/proc-xsc3.S | 90 +++++++++--------------------------------------
1 files changed, 17 insertions(+), 73 deletions(-)
diff --git a/arch/arm/mm/proc-xsc3.S b/arch/arm/mm/proc-xsc3.S
index 5962136..87c99d1 100644
--- a/arch/arm/mm/proc-xsc3.S
+++ b/arch/arm/mm/proc-xsc3.S
@@ -335,17 +335,8 @@ ENTRY(xsc3_dma_unmap_area)
mov pc, lr
ENDPROC(xsc3_dma_unmap_area)
-ENTRY(xsc3_cache_fns)
- .long xsc3_flush_icache_all
- .long xsc3_flush_kern_cache_all
- .long xsc3_flush_user_cache_all
- .long xsc3_flush_user_cache_range
- .long xsc3_coherent_kern_range
- .long xsc3_coherent_user_range
- .long xsc3_flush_kern_dcache_area
- .long xsc3_dma_map_area
- .long xsc3_dma_unmap_area
- .long xsc3_dma_flush_range
+ @ define struct cpu_cache_fns (see <asm/cacheflush.h> and proc-macros.S)
+ define_cache_functions xsc3, default=xsc3
ENTRY(cpu_xsc3_dcache_clean_area)
1: mcr p15, 0, r0, c7, c10, 1 @ clean L1 D line
@@ -503,52 +494,24 @@ xsc3_crval:
__INITDATA
-/*
- * Purpose : Function pointers used to access above functions - all calls
- * come through these
- */
-
- .type xsc3_processor_functions, #object
-ENTRY(xsc3_processor_functions)
- .word v5t_early_abort
- .word legacy_pabort
- .word cpu_xsc3_proc_init
- .word cpu_xsc3_proc_fin
- .word cpu_xsc3_reset
- .word cpu_xsc3_do_idle
- .word cpu_xsc3_dcache_clean_area
- .word cpu_xsc3_switch_mm
- .word cpu_xsc3_set_pte_ext
- .word cpu_xsc3_suspend_size
- .word cpu_xsc3_do_suspend
- .word cpu_xsc3_do_resume
- .size xsc3_processor_functions, . - xsc3_processor_functions
+ @ define struct processor (see <asm/proc-fns.h> and proc-macros.S)
+ define_processor_functions xsc3, dabort=v5t_early_abort, pabort=legacy_pabort, suspend=1
.section ".rodata"
- .type cpu_arch_name, #object
-cpu_arch_name:
- .asciz "armv5te"
- .size cpu_arch_name, . - cpu_arch_name
-
- .type cpu_elf_name, #object
-cpu_elf_name:
- .asciz "v5"
- .size cpu_elf_name, . - cpu_elf_name
-
- .type cpu_xsc3_name, #object
-cpu_xsc3_name:
- .asciz "XScale-V3 based processor"
- .size cpu_xsc3_name, . - cpu_xsc3_name
+ string cpu_arch_name, "armv5te"
+ string cpu_elf_name, "v5"
+ string cpu_xsc3_name, "XScale-V3 based processor"
.align
.section ".proc.info.init", #alloc, #execinstr
- .type __xsc3_proc_info,#object
-__xsc3_proc_info:
- .long 0x69056000
- .long 0xffffe000
+.macro xsc3_proc_info name:req, cpu_val:req, cpu_mask:req
+ .type __\name\()_proc_info,#object
+__\name\()_proc_info:
+ .long \cpu_val
+ .long \cpu_mask
.long PMD_TYPE_SECT | \
PMD_SECT_BUFFERABLE | \
PMD_SECT_CACHEABLE | \
@@ -566,29 +529,10 @@ __xsc3_proc_info:
.long v4wbi_tlb_fns
.long xsc3_mc_user_fns
.long xsc3_cache_fns
- .size __xsc3_proc_info, . - __xsc3_proc_info
+ .size __\name\()_proc_info, . - __\name\()_proc_info
+.endm
-/* Note: PXA935 changed its implementor ID from Intel to Marvell */
+ xsc3_proc_info xsc3, 0x69056000, 0xffffe000
- .type __xsc3_pxa935_proc_info,#object
-__xsc3_pxa935_proc_info:
- .long 0x56056000
- .long 0xffffe000
- .long PMD_TYPE_SECT | \
- PMD_SECT_BUFFERABLE | \
- PMD_SECT_CACHEABLE | \
- PMD_SECT_AP_WRITE | \
- PMD_SECT_AP_READ
- .long PMD_TYPE_SECT | \
- PMD_SECT_AP_WRITE | \
- PMD_SECT_AP_READ
- b __xsc3_setup
- .long cpu_arch_name
- .long cpu_elf_name
- .long HWCAP_SWP|HWCAP_HALF|HWCAP_THUMB|HWCAP_FAST_MULT|HWCAP_EDSP
- .long cpu_xsc3_name
- .long xsc3_processor_functions
- .long v4wbi_tlb_fns
- .long xsc3_mc_user_fns
- .long xsc3_cache_fns
- .size __xsc3_pxa935_proc_info, . - __xsc3_pxa935_proc_info
+/* Note: PXA935 changed its implementor ID from Intel to Marvell */
+ xsc3_proc_info xsc3_pxa935, 0x56056000, 0xffffe000
--
1.7.4.1
next prev parent reply other threads:[~2011-06-23 17:50 UTC|newest]
Thread overview: 58+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-23 17:50 [PATCH v3 00/40] ARM: mm: Add generic macros for declaring various CPU structs Dave Martin
2011-06-23 17:50 ` [PATCH v3 01/40] Subject: ARM: mm: proc-macros Add generic proc/cache/tlb struct definition macros Dave Martin
2011-07-07 8:22 ` Russell King - ARM Linux
2011-07-07 9:32 ` Will Deacon
2011-07-07 10:07 ` Dave Martin
2011-07-07 10:16 ` Russell King - ARM Linux
2011-07-07 10:25 ` Dave Martin
2011-06-23 17:50 ` [PATCH v3 02/40] Subject: ARM: assembler.h: Add string declaration macro Dave Martin
2011-06-23 17:50 ` [PATCH v3 03/40] Subject: ARM: mm: cache-fa: Use the new processor struct macros Dave Martin
2011-06-23 17:50 ` [PATCH v3 04/40] Subject: ARM: mm: cache-v3: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 05/40] Subject: ARM: mm: cache-v4: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 06/40] Subject: ARM: mm: cache-v4wb: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 07/40] Subject: ARM: mm: cache-v4wt: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 08/40] Subject: ARM: mm: cache-v6: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 09/40] Subject: ARM: mm: cache-v7: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 10/40] Subject: ARM: mm: proc-arm1020: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 11/40] Subject: ARM: mm: proc-arm1020e: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 12/40] Subject: ARM: mm: proc-arm1022: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 13/40] Subject: ARM: mm: proc-arm1026: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 14/40] Subject: ARM: mm: proc-arm6_7: " Dave Martin
2011-07-07 9:10 ` Russell King - ARM Linux
2011-07-07 10:11 ` Dave Martin
2011-06-23 17:50 ` [PATCH v3 15/40] Subject: ARM: mm: proc-arm720: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 16/40] Subject: ARM: mm: proc-arm740: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 17/40] Subject: ARM: mm: proc-arm7tdmi: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 18/40] Subject: ARM: mm: proc-arm920: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 19/40] Subject: ARM: mm: proc-arm922: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 20/40] Subject: ARM: mm: proc-arm925: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 21/40] Subject: ARM: mm: proc-arm926: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 22/40] Subject: ARM: mm: proc-arm940: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 23/40] Subject: ARM: mm: proc-arm946: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 24/40] Subject: ARM: mm: proc-arm9tdmi: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 25/40] Subject: ARM: mm: proc-fa526: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 26/40] Subject: ARM: mm: proc-feroceon: " Dave Martin
2011-07-07 9:14 ` Russell King - ARM Linux
2011-07-07 10:14 ` Dave Martin
2011-06-23 17:50 ` [PATCH v3 27/40] Subject: ARM: mm: proc-mohawk: " Dave Martin
2011-07-07 9:11 ` Russell King - ARM Linux
2011-07-07 10:21 ` Dave Martin
2011-06-23 17:50 ` [PATCH v3 28/40] Subject: ARM: mm: proc-sa110: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 29/40] Subject: ARM: mm: proc-sa1100: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 30/40] Subject: ARM: mm: proc-v6: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 31/40] Subject: ARM: mm: proc-v7: " Dave Martin
2011-06-23 17:50 ` Dave Martin [this message]
2011-06-23 17:50 ` [PATCH v3 33/40] Subject: ARM: mm: proc-xscale: Use new generic struct definition macros Dave Martin
2011-06-23 17:50 ` [PATCH v3 34/40] Subject: ARM: mm: tlb-fa: Use the new processor struct macros Dave Martin
2011-06-23 17:50 ` [PATCH v3 35/40] Subject: ARM: mm: tlb-v3: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 36/40] Subject: ARM: mm: tlb-v4: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 37/40] Subject: ARM: mm: tlb-v4wb: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 38/40] Subject: ARM: mm: tlb-v4wbi: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 39/40] Subject: ARM: mm: tlb-v6: " Dave Martin
2011-06-23 17:50 ` [PATCH v3 40/40] Subject: ARM: mm: tlb-v7: " Dave Martin
2011-06-23 23:44 ` [PATCH v3 00/40] ARM: mm: Add generic macros for declaring various CPU structs Nicolas Pitre
2011-06-24 10:10 ` Dave Martin
2011-06-24 13:32 ` Nicolas Pitre
2011-06-24 13:54 ` Dave Martin
2011-06-28 10:53 ` Dave Martin
2011-07-01 10:10 ` Will Deacon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1308851448-25139-33-git-send-email-dave.martin@linaro.org \
--to=dave.martin@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).