diff options
author | Christoph Lameter <clameter@sgi.com> | 2008-04-28 05:12:45 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-28 11:58:21 -0400 |
commit | bf2ae2b37c06cc9fb6fc03d99617f1161939980f (patch) | |
tree | 3ffc871c7cf45eb08a51704f840778dda6db0cdc /arch/mips/kernel | |
parent | 726b80127239aeea9c8d8aad5b4e2c80313e3ce8 (diff) |
pageflags: standardize comment inclusion in asm-offsets.h and fix MIPS
Add the ability to pass comments into asm-offsets.h by generating asm
output like
-># comment line
Mips needs this feature to preserve the comments that are in
asm-mips/asm-offsets.h right now.
Then remove the special handling for mips from Kbuild and convert mips to use
the new string to include the comments.
Cc: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Cc: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/mips/kernel')
-rw-r--r-- | arch/mips/kernel/asm-offsets.c | 404 |
1 files changed, 202 insertions, 202 deletions
diff --git a/arch/mips/kernel/asm-offsets.c b/arch/mips/kernel/asm-offsets.c index ca136298acdc..5bf03b3c4150 100644 --- a/arch/mips/kernel/asm-offsets.c +++ b/arch/mips/kernel/asm-offsets.c | |||
@@ -17,252 +17,252 @@ | |||
17 | #include <asm/ptrace.h> | 17 | #include <asm/ptrace.h> |
18 | #include <asm/processor.h> | 18 | #include <asm/processor.h> |
19 | 19 | ||
20 | #define text(t) __asm__("\n@@@" t) | 20 | #define text(t) __asm__("\n->#" t) |
21 | #define _offset(type, member) (&(((type *)NULL)->member)) | 21 | #define _offset(type, member) (&(((type *)NULL)->member)) |
22 | #define offset(string, ptr, member) \ | 22 | #define offset(string, ptr, member) \ |
23 | __asm__("\n@@@" string "%0" : : "i" (_offset(ptr, member))) | 23 | __asm__("\n->" string " %0" : : "i" (_offset(ptr, member))) |
24 | #define constant(string, member) \ | 24 | #define constant(string, member) \ |
25 | __asm__("\n@@@" string "%X0" : : "ri" (member)) | 25 | __asm__("\n->" string " %0" : : "ri" (member)) |
26 | #define size(string, size) \ | 26 | #define size(string, size) \ |
27 | __asm__("\n@@@" string "%0" : : "i" (sizeof(size))) | 27 | __asm__("\n->" string " %0" : : "i" (sizeof(size))) |
28 | #define linefeed text("") | 28 | #define linefeed text("") |
29 | 29 | ||
30 | void output_ptreg_defines(void) | 30 | void output_ptreg_defines(void) |
31 | { | 31 | { |
32 | text("/* MIPS pt_regs offsets. */"); | 32 | text("MIPS pt_regs offsets."); |
33 | offset("#define PT_R0 ", struct pt_regs, regs[0]); | 33 | offset("PT_R0", struct pt_regs, regs[0]); |
34 | offset("#define PT_R1 ", struct pt_regs, regs[1]); | 34 | offset("PT_R1", struct pt_regs, regs[1]); |
35 | offset("#define PT_R2 ", struct pt_regs, regs[2]); | 35 | offset("PT_R2", struct pt_regs, regs[2]); |
36 | offset("#define PT_R3 ", struct pt_regs, regs[3]); | 36 | offset("PT_R3", struct pt_regs, regs[3]); |
37 | offset("#define PT_R4 ", struct pt_regs, regs[4]); | 37 | offset("PT_R4", struct pt_regs, regs[4]); |
38 | offset("#define PT_R5 ", struct pt_regs, regs[5]); | 38 | offset("PT_R5", struct pt_regs, regs[5]); |
39 | offset("#define PT_R6 ", struct pt_regs, regs[6]); | 39 | offset("PT_R6", struct pt_regs, regs[6]); |
40 | offset("#define PT_R7 ", struct pt_regs, regs[7]); | 40 | offset("PT_R7", struct pt_regs, regs[7]); |
41 | offset("#define PT_R8 ", struct pt_regs, regs[8]); | 41 | offset("PT_R8", struct pt_regs, regs[8]); |
42 | offset("#define PT_R9 ", struct pt_regs, regs[9]); | 42 | offset("PT_R9", struct pt_regs, regs[9]); |
43 | offset("#define PT_R10 ", struct pt_regs, regs[10]); | 43 | offset("PT_R10", struct pt_regs, regs[10]); |
44 | offset("#define PT_R11 ", struct pt_regs, regs[11]); | 44 | offset("PT_R11", struct pt_regs, regs[11]); |
45 | offset("#define PT_R12 ", struct pt_regs, regs[12]); | 45 | offset("PT_R12", struct pt_regs, regs[12]); |
46 | offset("#define PT_R13 ", struct pt_regs, regs[13]); | 46 | offset("PT_R13", struct pt_regs, regs[13]); |
47 | offset("#define PT_R14 ", struct pt_regs, regs[14]); | 47 | offset("PT_R14", struct pt_regs, regs[14]); |
48 | offset("#define PT_R15 ", struct pt_regs, regs[15]); | 48 | offset("PT_R15", struct pt_regs, regs[15]); |
49 | offset("#define PT_R16 ", struct pt_regs, regs[16]); | 49 | offset("PT_R16", struct pt_regs, regs[16]); |
50 | offset("#define PT_R17 ", struct pt_regs, regs[17]); | 50 | offset("PT_R17", struct pt_regs, regs[17]); |
51 | offset("#define PT_R18 ", struct pt_regs, regs[18]); | 51 | offset("PT_R18", struct pt_regs, regs[18]); |
52 | offset("#define PT_R19 ", struct pt_regs, regs[19]); | 52 | offset("PT_R19", struct pt_regs, regs[19]); |
53 | offset("#define PT_R20 ", struct pt_regs, regs[20]); | 53 | offset("PT_R20", struct pt_regs, regs[20]); |
54 | offset("#define PT_R21 ", struct pt_regs, regs[21]); | 54 | offset("PT_R21", struct pt_regs, regs[21]); |
55 | offset("#define PT_R22 ", struct pt_regs, regs[22]); | 55 | offset("PT_R22", struct pt_regs, regs[22]); |
56 | offset("#define PT_R23 ", struct pt_regs, regs[23]); | 56 | offset("PT_R23", struct pt_regs, regs[23]); |
57 | offset("#define PT_R24 ", struct pt_regs, regs[24]); | 57 | offset("PT_R24", struct pt_regs, regs[24]); |
58 | offset("#define PT_R25 ", struct pt_regs, regs[25]); | 58 | offset("PT_R25", struct pt_regs, regs[25]); |
59 | offset("#define PT_R26 ", struct pt_regs, regs[26]); | 59 | offset("PT_R26", struct pt_regs, regs[26]); |
60 | offset("#define PT_R27 ", struct pt_regs, regs[27]); | 60 | offset("PT_R27", struct pt_regs, regs[27]); |
61 | offset("#define PT_R28 ", struct pt_regs, regs[28]); | 61 | offset("PT_R28", struct pt_regs, regs[28]); |
62 | offset("#define PT_R29 ", struct pt_regs, regs[29]); | 62 | offset("PT_R29", struct pt_regs, regs[29]); |
63 | offset("#define PT_R30 ", struct pt_regs, regs[30]); | 63 | offset("PT_R30", struct pt_regs, regs[30]); |
64 | offset("#define PT_R31 ", struct pt_regs, regs[31]); | 64 | offset("PT_R31", struct pt_regs, regs[31]); |
65 | offset("#define PT_LO ", struct pt_regs, lo); | 65 | offset("PT_LO", struct pt_regs, lo); |
66 | offset("#define PT_HI ", struct pt_regs, hi); | 66 | offset("PT_HI", struct pt_regs, hi); |
67 | #ifdef CONFIG_CPU_HAS_SMARTMIPS | 67 | #ifdef CONFIG_CPU_HAS_SMARTMIPS |
68 | offset("#define PT_ACX ", struct pt_regs, acx); | 68 | offset("PT_ACX", struct pt_regs, acx); |
69 | #endif | 69 | #endif |
70 | offset("#define PT_EPC ", struct pt_regs, cp0_epc); | 70 | offset("PT_EPC", struct pt_regs, cp0_epc); |
71 | offset("#define PT_BVADDR ", struct pt_regs, cp0_badvaddr); | 71 | offset("PT_BVADDR", struct pt_regs, cp0_badvaddr); |
72 | offset("#define PT_STATUS ", struct pt_regs, cp0_status); | 72 | offset("PT_STATUS", struct pt_regs, cp0_status); |
73 | offset("#define PT_CAUSE ", struct pt_regs, cp0_cause); | 73 | offset("PT_CAUSE", struct pt_regs, cp0_cause); |
74 | #ifdef CONFIG_MIPS_MT_SMTC | 74 | #ifdef CONFIG_MIPS_MT_SMTC |
75 | offset("#define PT_TCSTATUS ", struct pt_regs, cp0_tcstatus); | 75 | offset("PT_TCSTATUS", struct pt_regs, cp0_tcstatus); |
76 | #endif /* CONFIG_MIPS_MT_SMTC */ | 76 | #endif /* CONFIG_MIPS_MT_SMTC */ |
77 | size("#define PT_SIZE ", struct pt_regs); | 77 | size("PT_SIZE", struct pt_regs); |
78 | linefeed; | 78 | linefeed; |
79 | } | 79 | } |
80 | 80 | ||
81 | void output_task_defines(void) | 81 | void output_task_defines(void) |
82 | { | 82 | { |
83 | text("/* MIPS task_struct offsets. */"); | 83 | text("MIPS task_struct offsets."); |
84 | offset("#define TASK_STATE ", struct task_struct, state); | 84 | offset("TASK_STATE", struct task_struct, state); |
85 | offset("#define TASK_THREAD_INFO ", struct task_struct, stack); | 85 | offset("TASK_THREAD_INFO", struct task_struct, stack); |
86 | offset("#define TASK_FLAGS ", struct task_struct, flags); | 86 | offset("TASK_FLAGS", struct task_struct, flags); |
87 | offset("#define TASK_MM ", struct task_struct, mm); | 87 | offset("TASK_MM", struct task_struct, mm); |
88 | offset("#define TASK_PID ", struct task_struct, pid); | 88 | offset("TASK_PID", struct task_struct, pid); |
89 | size( "#define TASK_STRUCT_SIZE ", struct task_struct); | 89 | size( "TASK_STRUCT_SIZE", struct task_struct); |
90 | linefeed; | 90 | linefeed; |
91 | } | 91 | } |
92 | 92 | ||
93 | void output_thread_info_defines(void) | 93 | void output_thread_info_defines(void) |
94 | { | 94 | { |
95 | text("/* MIPS thread_info offsets. */"); | 95 | text("MIPS thread_info offsets."); |
96 | offset("#define TI_TASK ", struct thread_info, task); | 96 | offset("TI_TASK", struct thread_info, task); |
97 | offset("#define TI_EXEC_DOMAIN ", struct thread_info, exec_domain); | 97 | offset("TI_EXEC_DOMAIN", struct thread_info, exec_domain); |
98 | offset("#define TI_FLAGS ", struct thread_info, flags); | 98 | offset("TI_FLAGS", struct thread_info, flags); |
99 | offset("#define TI_TP_VALUE ", struct thread_info, tp_value); | 99 | offset("TI_TP_VALUE", struct thread_info, tp_value); |
100 | offset("#define TI_CPU ", struct thread_info, cpu); | 100 | offset("TI_CPU", struct thread_info, cpu); |
101 | offset("#define TI_PRE_COUNT ", struct thread_info, preempt_count); | 101 | offset("TI_PRE_COUNT", struct thread_info, preempt_count); |
102 | offset("#define TI_ADDR_LIMIT ", struct thread_info, addr_limit); | 102 | offset("TI_ADDR_LIMIT", struct thread_info, addr_limit); |
103 | offset("#define TI_RESTART_BLOCK ", struct thread_info, restart_block); | 103 | offset("TI_RESTART_BLOCK", struct thread_info, restart_block); |
104 | offset("#define TI_REGS ", struct thread_info, regs); | 104 | offset("TI_REGS", struct thread_info, regs); |
105 | constant("#define _THREAD_SIZE ", THREAD_SIZE); | 105 | constant("_THREAD_SIZE", THREAD_SIZE); |
106 | constant("#define _THREAD_MASK ", THREAD_MASK); | 106 | constant("_THREAD_MASK", THREAD_MASK); |
107 | linefeed; | 107 | linefeed; |
108 | } | 108 | } |
109 | 109 | ||
110 | void output_thread_defines(void) | 110 | void output_thread_defines(void) |
111 | { | 111 | { |
112 | text("/* MIPS specific thread_struct offsets. */"); | 112 | text("MIPS specific thread_struct offsets."); |
113 | offset("#define THREAD_REG16 ", struct task_struct, thread.reg16); | 113 | offset("THREAD_REG16", struct task_struct, thread.reg16); |
114 | offset("#define THREAD_REG17 ", struct task_struct, thread.reg17); | 114 | offset("THREAD_REG17", struct task_struct, thread.reg17); |
115 | offset("#define THREAD_REG18 ", struct task_struct, thread.reg18); | 115 | offset("THREAD_REG18", struct task_struct, thread.reg18); |
116 | offset("#define THREAD_REG19 ", struct task_struct, thread.reg19); | 116 | offset("THREAD_REG19", struct task_struct, thread.reg19); |
117 | offset("#define THREAD_REG20 ", struct task_struct, thread.reg20); | 117 | offset("THREAD_REG20", struct task_struct, thread.reg20); |
118 | offset("#define THREAD_REG21 ", struct task_struct, thread.reg21); | 118 | offset("THREAD_REG21", struct task_struct, thread.reg21); |
119 | offset("#define THREAD_REG22 ", struct task_struct, thread.reg22); | 119 | offset("THREAD_REG22", struct task_struct, thread.reg22); |
120 | offset("#define THREAD_REG23 ", struct task_struct, thread.reg23); | 120 | offset("THREAD_REG23", struct task_struct, thread.reg23); |
121 | offset("#define THREAD_REG29 ", struct task_struct, thread.reg29); | 121 | offset("THREAD_REG29", struct task_struct, thread.reg29); |
122 | offset("#define THREAD_REG30 ", struct task_struct, thread.reg30); | 122 | offset("THREAD_REG30", struct task_struct, thread.reg30); |
123 | offset("#define THREAD_REG31 ", struct task_struct, thread.reg31); | 123 | offset("THREAD_REG31", struct task_struct, thread.reg31); |
124 | offset("#define THREAD_STATUS ", struct task_struct, | 124 | offset("THREAD_STATUS", struct task_struct, |
125 | thread.cp0_status); | 125 | thread.cp0_status); |
126 | offset("#define THREAD_FPU ", struct task_struct, thread.fpu); | 126 | offset("THREAD_FPU", struct task_struct, thread.fpu); |
127 | 127 | ||
128 | offset("#define THREAD_BVADDR ", struct task_struct, \ | 128 | offset("THREAD_BVADDR", struct task_struct, \ |
129 | thread.cp0_badvaddr); | 129 | thread.cp0_badvaddr); |
130 | offset("#define THREAD_BUADDR ", struct task_struct, \ | 130 | offset("THREAD_BUADDR", struct task_struct, \ |
131 | thread.cp0_baduaddr); | 131 | thread.cp0_baduaddr); |
132 | offset("#define THREAD_ECODE ", struct task_struct, \ | 132 | offset("THREAD_ECODE", struct task_struct, \ |
133 | thread.error_code); | 133 | thread.error_code); |
134 | offset("#define THREAD_TRAPNO ", struct task_struct, thread.trap_no); | 134 | offset("THREAD_TRAPNO", struct task_struct, thread.trap_no); |
135 | offset("#define THREAD_TRAMP ", struct task_struct, \ | 135 | offset("THREAD_TRAMP", struct task_struct, \ |
136 | thread.irix_trampoline); | 136 | thread.irix_trampoline); |
137 | offset("#define THREAD_OLDCTX ", struct task_struct, \ | 137 | offset("THREAD_OLDCTX", struct task_struct, \ |
138 | thread.irix_oldctx); | 138 | thread.irix_oldctx); |
139 | linefeed; | 139 | linefeed; |
140 | } | 140 | } |
141 | 141 | ||
142 | void output_thread_fpu_defines(void) | 142 | void output_thread_fpu_defines(void) |
143 | { | 143 | { |
144 | offset("#define THREAD_FPR0 ", | 144 | offset("THREAD_FPR0", |
145 | struct task_struct, thread.fpu.fpr[0]); | 145 | struct task_struct, thread.fpu.fpr[0]); |
146 | offset("#define THREAD_FPR1 ", | 146 | offset("THREAD_FPR1", |
147 | struct task_struct, thread.fpu.fpr[1]); | 147 | struct task_struct, thread.fpu.fpr[1]); |
148 | offset("#define THREAD_FPR2 ", | 148 | offset("THREAD_FPR2", |
149 | struct task_struct, thread.fpu.fpr[2]); | 149 | struct task_struct, thread.fpu.fpr[2]); |
150 | offset("#define THREAD_FPR3 ", | 150 | offset("THREAD_FPR3", |
151 | struct task_struct, thread.fpu.fpr[3]); | 151 | struct task_struct, thread.fpu.fpr[3]); |
152 | offset("#define THREAD_FPR4 ", | 152 | offset("THREAD_FPR4", |
153 | struct task_struct, thread.fpu.fpr[4]); | 153 | struct task_struct, thread.fpu.fpr[4]); |
154 | offset("#define THREAD_FPR5 ", | 154 | offset("THREAD_FPR5", |
155 | struct task_struct, thread.fpu.fpr[5]); | 155 | struct task_struct, thread.fpu.fpr[5]); |
156 | offset("#define THREAD_FPR6 ", | 156 | offset("THREAD_FPR6", |
157 | struct task_struct, thread.fpu.fpr[6]); | 157 | struct task_struct, thread.fpu.fpr[6]); |
158 | offset("#define THREAD_FPR7 ", | 158 | offset("THREAD_FPR7", |
159 | struct task_struct, thread.fpu.fpr[7]); | 159 | struct task_struct, thread.fpu.fpr[7]); |
160 | offset("#define THREAD_FPR8 ", | 160 | offset("THREAD_FPR8", |
161 | struct task_struct, thread.fpu.fpr[8]); | 161 | struct task_struct, thread.fpu.fpr[8]); |
162 | offset("#define THREAD_FPR9 ", | 162 | offset("THREAD_FPR9", |
163 | struct task_struct, thread.fpu.fpr[9]); | 163 | struct task_struct, thread.fpu.fpr[9]); |
164 | offset("#define THREAD_FPR10 ", | 164 | offset("THREAD_FPR10", |
165 | struct task_struct, thread.fpu.fpr[10]); | 165 | struct task_struct, thread.fpu.fpr[10]); |
166 | offset("#define THREAD_FPR11 ", | 166 | offset("THREAD_FPR11", |
167 | struct task_struct, thread.fpu.fpr[11]); | 167 | struct task_struct, thread.fpu.fpr[11]); |
168 | offset("#define THREAD_FPR12 ", | 168 | offset("THREAD_FPR12", |
169 | struct task_struct, thread.fpu.fpr[12]); | 169 | struct task_struct, thread.fpu.fpr[12]); |
170 | offset("#define THREAD_FPR13 ", | 170 | offset("THREAD_FPR13", |
171 | struct task_struct, thread.fpu.fpr[13]); | 171 | struct task_struct, thread.fpu.fpr[13]); |
172 | offset("#define THREAD_FPR14 ", | 172 | offset("THREAD_FPR14", |
173 | struct task_struct, thread.fpu.fpr[14]); | 173 | struct task_struct, thread.fpu.fpr[14]); |
174 | offset("#define THREAD_FPR15 ", | 174 | offset("THREAD_FPR15", |
175 | struct task_struct, thread.fpu.fpr[15]); | 175 | struct task_struct, thread.fpu.fpr[15]); |
176 | offset("#define THREAD_FPR16 ", | 176 | offset("THREAD_FPR16", |
177 | struct task_struct, thread.fpu.fpr[16]); | 177 | struct task_struct, thread.fpu.fpr[16]); |
178 | offset("#define THREAD_FPR17 ", | 178 | offset("THREAD_FPR17", |
179 | struct task_struct, thread.fpu.fpr[17]); | 179 | struct task_struct, thread.fpu.fpr[17]); |
180 | offset("#define THREAD_FPR18 ", | 180 | offset("THREAD_FPR18", |
181 | struct task_struct, thread.fpu.fpr[18]); | 181 | struct task_struct, thread.fpu.fpr[18]); |
182 | offset("#define THREAD_FPR19 ", | 182 | offset("THREAD_FPR19", |
183 | struct task_struct, thread.fpu.fpr[19]); | 183 | struct task_struct, thread.fpu.fpr[19]); |
184 | offset("#define THREAD_FPR20 ", | 184 | offset("THREAD_FPR20", |
185 | struct task_struct, thread.fpu.fpr[20]); | 185 | struct task_struct, thread.fpu.fpr[20]); |
186 | offset("#define THREAD_FPR21 ", | 186 | offset("THREAD_FPR21", |
187 | struct task_struct, thread.fpu.fpr[21]); | 187 | struct task_struct, thread.fpu.fpr[21]); |
188 | offset("#define THREAD_FPR22 ", | 188 | offset("THREAD_FPR22", |
189 | struct task_struct, thread.fpu.fpr[22]); | 189 | struct task_struct, thread.fpu.fpr[22]); |
190 | offset("#define THREAD_FPR23 ", | 190 | offset("THREAD_FPR23", |
191 | struct task_struct, thread.fpu.fpr[23]); | 191 | struct task_struct, thread.fpu.fpr[23]); |
192 | offset("#define THREAD_FPR24 ", | 192 | offset("THREAD_FPR24", |
193 | struct task_struct, thread.fpu.fpr[24]); | 193 | struct task_struct, thread.fpu.fpr[24]); |
194 | offset("#define THREAD_FPR25 ", | 194 | offset("THREAD_FPR25", |
195 | struct task_struct, thread.fpu.fpr[25]); | 195 | struct task_struct, thread.fpu.fpr[25]); |
196 | offset("#define THREAD_FPR26 ", | 196 | offset("THREAD_FPR26", |
197 | struct task_struct, thread.fpu.fpr[26]); | 197 | struct task_struct, thread.fpu.fpr[26]); |
198 | offset("#define THREAD_FPR27 ", | 198 | offset("THREAD_FPR27", |
199 | struct task_struct, thread.fpu.fpr[27]); | 199 | struct task_struct, thread.fpu.fpr[27]); |
200 | offset("#define THREAD_FPR28 ", | 200 | offset("THREAD_FPR28", |
201 | struct task_struct, thread.fpu.fpr[28]); | 201 | struct task_struct, thread.fpu.fpr[28]); |
202 | offset("#define THREAD_FPR29 ", | 202 | offset("THREAD_FPR29", |
203 | struct task_struct, thread.fpu.fpr[29]); | 203 | struct task_struct, thread.fpu.fpr[29]); |
204 | offset("#define THREAD_FPR30 ", | 204 | offset("THREAD_FPR30", |
205 | struct task_struct, thread.fpu.fpr[30]); | 205 | struct task_struct, thread.fpu.fpr[30]); |
206 | offset("#define THREAD_FPR31 ", | 206 | offset("THREAD_FPR31", |
207 | struct task_struct, thread.fpu.fpr[31]); | 207 | struct task_struct, thread.fpu.fpr[31]); |
208 | 208 | ||
209 | offset("#define THREAD_FCR31 ", | 209 | offset("THREAD_FCR31", |
210 | struct task_struct, thread.fpu.fcr31); | 210 | struct task_struct, thread.fpu.fcr31); |
211 | linefeed; | 211 | linefeed; |
212 | } | 212 | } |
213 | 213 | ||
214 | void output_mm_defines(void) | 214 | void output_mm_defines(void) |
215 | { | 215 | { |
216 | text("/* Size of struct page */"); | 216 | text("Size of struct page"); |
217 | size("#define STRUCT_PAGE_SIZE ", struct page); | 217 | size("STRUCT_PAGE_SIZE", struct page); |
218 | linefeed; | 218 | linefeed; |
219 | text("/* Linux mm_struct offsets. */"); | 219 | text("Linux mm_struct offsets."); |
220 | offset("#define MM_USERS ", struct mm_struct, mm_users); | 220 | offset("MM_USERS", struct mm_struct, mm_users); |
221 | offset("#define MM_PGD ", struct mm_struct, pgd); | 221 | offset("MM_PGD", struct mm_struct, pgd); |
222 | offset("#define MM_CONTEXT ", struct mm_struct, context); | 222 | offset("MM_CONTEXT", struct mm_struct, context); |
223 | linefeed; | 223 | linefeed; |
224 | constant("#define _PAGE_SIZE ", PAGE_SIZE); | 224 | constant("_PAGE_SIZE", PAGE_SIZE); |
225 | constant("#define _PAGE_SHIFT ", PAGE_SHIFT); | 225 | constant("_PAGE_SHIFT", PAGE_SHIFT); |
226 | linefeed; | 226 | linefeed; |
227 | constant("#define _PGD_T_SIZE ", sizeof(pgd_t)); | 227 | constant("_PGD_T_SIZE", sizeof(pgd_t)); |
228 | constant("#define _PMD_T_SIZE ", sizeof(pmd_t)); | 228 | constant("_PMD_T_SIZE", sizeof(pmd_t)); |
229 | constant("#define _PTE_T_SIZE ", sizeof(pte_t)); | 229 | constant("_PTE_T_SIZE", sizeof(pte_t)); |
230 | linefeed; | 230 | linefeed; |
231 | constant("#define _PGD_T_LOG2 ", PGD_T_LOG2); | 231 | constant("_PGD_T_LOG2", PGD_T_LOG2); |
232 | constant("#define _PMD_T_LOG2 ", PMD_T_LOG2); | 232 | constant("_PMD_T_LOG2", PMD_T_LOG2); |
233 | constant("#define _PTE_T_LOG2 ", PTE_T_LOG2); | 233 | constant("_PTE_T_LOG2", PTE_T_LOG2); |
234 | linefeed; | 234 | linefeed; |
235 | constant("#define _PGD_ORDER ", PGD_ORDER); | 235 | constant("_PGD_ORDER", PGD_ORDER); |
236 | constant("#define _PMD_ORDER ", PMD_ORDER); | 236 | constant("_PMD_ORDER", PMD_ORDER); |
237 | constant("#define _PTE_ORDER ", PTE_ORDER); | 237 | constant("_PTE_ORDER", PTE_ORDER); |
238 | linefeed; | 238 | linefeed; |
239 | constant("#define _PMD_SHIFT ", PMD_SHIFT); | 239 | constant("_PMD_SHIFT", PMD_SHIFT); |
240 | constant("#define _PGDIR_SHIFT ", PGDIR_SHIFT); | 240 | constant("_PGDIR_SHIFT", PGDIR_SHIFT); |
241 | linefeed; | 241 | linefeed; |
242 | constant("#define _PTRS_PER_PGD ", PTRS_PER_PGD); | 242 | constant("_PTRS_PER_PGD", PTRS_PER_PGD); |
243 | constant("#define _PTRS_PER_PMD ", PTRS_PER_PMD); | 243 | constant("_PTRS_PER_PMD", PTRS_PER_PMD); |
244 | constant("#define _PTRS_PER_PTE ", PTRS_PER_PTE); | 244 | constant("_PTRS_PER_PTE", PTRS_PER_PTE); |
245 | linefeed; | 245 | linefeed; |
246 | } | 246 | } |
247 | 247 | ||
248 | #ifdef CONFIG_32BIT | 248 | #ifdef CONFIG_32BIT |
249 | void output_sc_defines(void) | 249 | void output_sc_defines(void) |
250 | { | 250 | { |
251 | text("/* Linux sigcontext offsets. */"); | 251 | text("Linux sigcontext offsets."); |
252 | offset("#define SC_REGS ", struct sigcontext, sc_regs); | 252 | offset("SC_REGS", struct sigcontext, sc_regs); |
253 | offset("#define SC_FPREGS ", struct sigcontext, sc_fpregs); | 253 | offset("SC_FPREGS", struct sigcontext, sc_fpregs); |
254 | offset("#define SC_ACX ", struct sigcontext, sc_acx); | 254 | offset("SC_ACX", struct sigcontext, sc_acx); |
255 | offset("#define SC_MDHI ", struct sigcontext, sc_mdhi); | 255 | offset("SC_MDHI", struct sigcontext, sc_mdhi); |
256 | offset("#define SC_MDLO ", struct sigcontext, sc_mdlo); | 256 | offset("SC_MDLO", struct sigcontext, sc_mdlo); |
257 | offset("#define SC_PC ", struct sigcontext, sc_pc); | 257 | offset("SC_PC", struct sigcontext, sc_pc); |
258 | offset("#define SC_FPC_CSR ", struct sigcontext, sc_fpc_csr); | 258 | offset("SC_FPC_CSR", struct sigcontext, sc_fpc_csr); |
259 | offset("#define SC_FPC_EIR ", struct sigcontext, sc_fpc_eir); | 259 | offset("SC_FPC_EIR", struct sigcontext, sc_fpc_eir); |
260 | offset("#define SC_HI1 ", struct sigcontext, sc_hi1); | 260 | offset("SC_HI1", struct sigcontext, sc_hi1); |
261 | offset("#define SC_LO1 ", struct sigcontext, sc_lo1); | 261 | offset("SC_LO1", struct sigcontext, sc_lo1); |
262 | offset("#define SC_HI2 ", struct sigcontext, sc_hi2); | 262 | offset("SC_HI2", struct sigcontext, sc_hi2); |
263 | offset("#define SC_LO2 ", struct sigcontext, sc_lo2); | 263 | offset("SC_LO2", struct sigcontext, sc_lo2); |
264 | offset("#define SC_HI3 ", struct sigcontext, sc_hi3); | 264 | offset("SC_HI3", struct sigcontext, sc_hi3); |
265 | offset("#define SC_LO3 ", struct sigcontext, sc_lo3); | 265 | offset("SC_LO3", struct sigcontext, sc_lo3); |
266 | linefeed; | 266 | linefeed; |
267 | } | 267 | } |
268 | #endif | 268 | #endif |
@@ -270,13 +270,13 @@ void output_sc_defines(void) | |||
270 | #ifdef CONFIG_64BIT | 270 | #ifdef CONFIG_64BIT |
271 | void output_sc_defines(void) | 271 | void output_sc_defines(void) |
272 | { | 272 | { |
273 | text("/* Linux sigcontext offsets. */"); | 273 | text("Linux sigcontext offsets."); |
274 | offset("#define SC_REGS ", struct sigcontext, sc_regs); | 274 | offset("SC_REGS", struct sigcontext, sc_regs); |
275 | offset("#define SC_FPREGS ", struct sigcontext, sc_fpregs); | 275 | offset("SC_FPREGS", struct sigcontext, sc_fpregs); |
276 | offset("#define SC_MDHI ", struct sigcontext, sc_mdhi); | 276 | offset("SC_MDHI", struct sigcontext, sc_mdhi); |
277 | offset("#define SC_MDLO ", struct sigcontext, sc_mdlo); | 277 | offset("SC_MDLO", struct sigcontext, sc_mdlo); |
278 | offset("#define SC_PC ", struct sigcontext, sc_pc); | 278 | offset("SC_PC", struct sigcontext, sc_pc); |
279 | offset("#define SC_FPC_CSR ", struct sigcontext, sc_fpc_csr); | 279 | offset("SC_FPC_CSR", struct sigcontext, sc_fpc_csr); |
280 | linefeed; | 280 | linefeed; |
281 | } | 281 | } |
282 | #endif | 282 | #endif |
@@ -284,56 +284,56 @@ void output_sc_defines(void) | |||
284 | #ifdef CONFIG_MIPS32_COMPAT | 284 | #ifdef CONFIG_MIPS32_COMPAT |
285 | void output_sc32_defines(void) | 285 | void output_sc32_defines(void) |
286 | { | 286 | { |
287 | text("/* Linux 32-bit sigcontext offsets. */"); | 287 | text("Linux 32-bit sigcontext offsets."); |
288 | offset("#define SC32_FPREGS ", struct sigcontext32, sc_fpregs); | 288 | offset("SC32_FPREGS", struct sigcontext32, sc_fpregs); |
289 | offset("#define SC32_FPC_CSR ", struct sigcontext32, sc_fpc_csr); | 289 | offset("SC32_FPC_CSR", struct sigcontext32, sc_fpc_csr); |
290 | offset("#define SC32_FPC_EIR ", struct sigcontext32, sc_fpc_eir); | 290 | offset("SC32_FPC_EIR", struct sigcontext32, sc_fpc_eir); |
291 | linefeed; | 291 | linefeed; |
292 | } | 292 | } |
293 | #endif | 293 | #endif |
294 | 294 | ||
295 | void output_signal_defined(void) | 295 | void output_signal_defined(void) |
296 | { | 296 | { |
297 | text("/* Linux signal numbers. */"); | 297 | text("Linux signal numbers."); |
298 | constant("#define _SIGHUP ", SIGHUP); | 298 | constant("_SIGHUP", SIGHUP); |
299 | constant("#define _SIGINT ", SIGINT); | 299 | constant("_SIGINT", SIGINT); |
300 | constant("#define _SIGQUIT ", SIGQUIT); | 300 | constant("_SIGQUIT", SIGQUIT); |
301 | constant("#define _SIGILL ", SIGILL); | 301 | constant("_SIGILL", SIGILL); |
302 | constant("#define _SIGTRAP ", SIGTRAP); | 302 | constant("_SIGTRAP", SIGTRAP); |
303 | constant("#define _SIGIOT ", SIGIOT); | 303 | constant("_SIGIOT", SIGIOT); |
304 | constant("#define _SIGABRT ", SIGABRT); | 304 | constant("_SIGABRT", SIGABRT); |
305 | constant("#define _SIGEMT ", SIGEMT); | 305 | constant("_SIGEMT", SIGEMT); |
306 | constant("#define _SIGFPE ", SIGFPE); | 306 | constant("_SIGFPE", SIGFPE); |
307 | constant("#define _SIGKILL ", SIGKILL); | 307 | constant("_SIGKILL", SIGKILL); |
308 | constant("#define _SIGBUS ", SIGBUS); | 308 | constant("_SIGBUS", SIGBUS); |
309 | constant("#define _SIGSEGV ", SIGSEGV); | 309 | constant("_SIGSEGV", SIGSEGV); |
310 | constant("#define _SIGSYS ", SIGSYS); | 310 | constant("_SIGSYS", SIGSYS); |
311 | constant("#define _SIGPIPE ", SIGPIPE); | 311 | constant("_SIGPIPE", SIGPIPE); |
312 | constant("#define _SIGALRM ", SIGALRM); | 312 | constant("_SIGALRM", SIGALRM); |
313 | constant("#define _SIGTERM ", SIGTERM); | 313 | constant("_SIGTERM", SIGTERM); |
314 | constant("#define _SIGUSR1 ", SIGUSR1); | 314 | constant("_SIGUSR1", SIGUSR1); |
315 | constant("#define _SIGUSR2 ", SIGUSR2); | 315 | constant("_SIGUSR2", SIGUSR2); |
316 | constant("#define _SIGCHLD ", SIGCHLD); | 316 | constant("_SIGCHLD", SIGCHLD); |
317 | constant("#define _SIGPWR ", SIGPWR); | 317 | constant("_SIGPWR", SIGPWR); |
318 | constant("#define _SIGWINCH ", SIGWINCH); | 318 | constant("_SIGWINCH", SIGWINCH); |
319 | constant("#define _SIGURG ", SIGURG); | 319 | constant("_SIGURG", SIGURG); |
320 | constant("#define _SIGIO ", SIGIO); | 320 | constant("_SIGIO", SIGIO); |
321 | constant("#define _SIGSTOP ", SIGSTOP); | 321 | constant("_SIGSTOP", SIGSTOP); |
322 | constant("#define _SIGTSTP ", SIGTSTP); | 322 | constant("_SIGTSTP", SIGTSTP); |
323 | constant("#define _SIGCONT ", SIGCONT); | 323 | constant("_SIGCONT", SIGCONT); |
324 | constant("#define _SIGTTIN ", SIGTTIN); | 324 | constant("_SIGTTIN", SIGTTIN); |
325 | constant("#define _SIGTTOU ", SIGTTOU); | 325 | constant("_SIGTTOU", SIGTTOU); |
326 | constant("#define _SIGVTALRM ", SIGVTALRM); | 326 | constant("_SIGVTALRM", SIGVTALRM); |
327 | constant("#define _SIGPROF ", SIGPROF); | 327 | constant("_SIGPROF", SIGPROF); |
328 | constant("#define _SIGXCPU ", SIGXCPU); | 328 | constant("_SIGXCPU", SIGXCPU); |
329 | constant("#define _SIGXFSZ ", SIGXFSZ); | 329 | constant("_SIGXFSZ", SIGXFSZ); |
330 | linefeed; | 330 | linefeed; |
331 | } | 331 | } |
332 | 332 | ||
333 | void output_irq_cpustat_t_defines(void) | 333 | void output_irq_cpustat_t_defines(void) |
334 | { | 334 | { |
335 | text("/* Linux irq_cpustat_t offsets. */"); | 335 | text("Linux irq_cpustat_t offsets."); |
336 | offset("#define IC_SOFTIRQ_PENDING ", irq_cpustat_t, __softirq_pending); | 336 | offset("IC_SOFTIRQ_PENDING", irq_cpustat_t, __softirq_pending); |
337 | size("#define IC_IRQ_CPUSTAT_T ", irq_cpustat_t); | 337 | size("IC_IRQ_CPUSTAT_T", irq_cpustat_t); |
338 | linefeed; | 338 | linefeed; |
339 | } | 339 | } |