2 * arch/arm/include/asm/glue.h
4 * Copyright (C) 1997-1999 Russell King
5 * Copyright (C) 2000-2002 Deep Blue Solutions Ltd.
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License version 2 as
9 * published by the Free Software Foundation.
11 * This file provides the glue to stick the processor-specific bits
12 * into the kernel in an efficient manner. The idea is to use branches
13 * when we're only targetting one class of TLB, or indirect calls
14 * when we're targetting multiple classes of TLBs.
20 #define ____glue(name,fn) name##fn
22 #define ____glue(name,fn) name/**/fn
24 #define __glue(name,fn) ____glue(name,fn)
32 * We have the following to choose from:
35 * v4_early - ARMv4 without Thumb early abort handler
36 * v4t_late - ARMv4 with Thumb late abort handler
37 * v4t_early - ARMv4 with Thumb early abort handler
38 * v5tej_early - ARMv5 with Thumb and Java early abort handler
39 * xscale - ARMv5 with Thumb with Xscale extensions
40 * v6_early - ARMv6 generic early abort handler
41 * v7_early - ARMv7 generic early abort handler
43 #undef CPU_DABORT_HANDLER
46 #if defined(CONFIG_CPU_ARM610)
47 # ifdef CPU_DABORT_HANDLER
48 # define MULTI_DABORT 1
50 # define CPU_DABORT_HANDLER cpu_arm6_data_abort
54 #if defined(CONFIG_CPU_ARM710)
55 # ifdef CPU_DABORT_HANDLER
56 # define MULTI_DABORT 1
58 # define CPU_DABORT_HANDLER cpu_arm7_data_abort
62 #ifdef CONFIG_CPU_ABRT_LV4T
63 # ifdef CPU_DABORT_HANDLER
64 # define MULTI_DABORT 1
66 # define CPU_DABORT_HANDLER v4t_late_abort
70 #ifdef CONFIG_CPU_ABRT_EV4
71 # ifdef CPU_DABORT_HANDLER
72 # define MULTI_DABORT 1
74 # define CPU_DABORT_HANDLER v4_early_abort
78 #ifdef CONFIG_CPU_ABRT_EV4T
79 # ifdef CPU_DABORT_HANDLER
80 # define MULTI_DABORT 1
82 # define CPU_DABORT_HANDLER v4t_early_abort
86 #ifdef CONFIG_CPU_ABRT_EV5TJ
87 # ifdef CPU_DABORT_HANDLER
88 # define MULTI_DABORT 1
90 # define CPU_DABORT_HANDLER v5tj_early_abort
94 #ifdef CONFIG_CPU_ABRT_EV5T
95 # ifdef CPU_DABORT_HANDLER
96 # define MULTI_DABORT 1
98 # define CPU_DABORT_HANDLER v5t_early_abort
102 #ifdef CONFIG_CPU_ABRT_EV6
103 # ifdef CPU_DABORT_HANDLER
104 # define MULTI_DABORT 1
106 # define CPU_DABORT_HANDLER v6_early_abort
110 #ifdef CONFIG_CPU_ABRT_EV7
111 # ifdef CPU_DABORT_HANDLER
112 # define MULTI_DABORT 1
114 # define CPU_DABORT_HANDLER v7_early_abort
118 #ifndef CPU_DABORT_HANDLER
119 #error Unknown data abort handler type
123 * Prefetch Abort Model
126 * We have the following to choose from:
127 * legacy - no IFSR, no IFAR
128 * v6 - ARMv6: IFSR, no IFAR
129 * v7 - ARMv7: IFSR and IFAR
132 #undef CPU_PABORT_HANDLER
135 #ifdef CONFIG_CPU_PABRT_LEGACY
136 # ifdef CPU_PABORT_HANDLER
137 # define MULTI_PABORT 1
139 # define CPU_PABORT_HANDLER legacy_pabort
143 #ifdef CONFIG_CPU_PABRT_V6
144 # ifdef CPU_PABORT_HANDLER
145 # define MULTI_PABORT 1
147 # define CPU_PABORT_HANDLER v6_pabort
151 #ifdef CONFIG_CPU_PABRT_V7
152 # ifdef CPU_PABORT_HANDLER
153 # define MULTI_PABORT 1
155 # define CPU_PABORT_HANDLER v7_pabort
159 #ifndef CPU_PABORT_HANDLER
160 #error Unknown prefetch abort handler type