db_machdep.c revision 1.18 1 1.18 matt /* $NetBSD: db_machdep.c,v 1.18 2014/03/01 05:41:39 matt Exp $ */
2 1.1 matt
3 1.17 skrll /*
4 1.1 matt * Copyright (c) 1996 Mark Brinicombe
5 1.1 matt *
6 1.1 matt * Mach Operating System
7 1.1 matt * Copyright (c) 1991,1990 Carnegie Mellon University
8 1.1 matt * All Rights Reserved.
9 1.17 skrll *
10 1.1 matt * Permission to use, copy, modify and distribute this software and its
11 1.1 matt * documentation is hereby granted, provided that both the copyright
12 1.1 matt * notice and this permission notice appear in all copies of the
13 1.1 matt * software, derivative works or modified versions, and any portions
14 1.1 matt * thereof, and that both notices appear in supporting documentation.
15 1.17 skrll *
16 1.1 matt * CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
17 1.1 matt * CONDITION. CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
18 1.1 matt * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
19 1.17 skrll *
20 1.1 matt * Carnegie Mellon requests users of this software to return to
21 1.17 skrll *
22 1.1 matt * Software Distribution Coordinator or Software.Distribution (at) CS.CMU.EDU
23 1.1 matt * School of Computer Science
24 1.1 matt * Carnegie Mellon University
25 1.1 matt * Pittsburgh PA 15213-3890
26 1.17 skrll *
27 1.1 matt * any improvements or extensions that they make and grant Carnegie the
28 1.1 matt * rights to redistribute these changes.
29 1.1 matt */
30 1.8 lukem
31 1.8 lukem #include <sys/cdefs.h>
32 1.18 matt __KERNEL_RCSID(0, "$NetBSD: db_machdep.c,v 1.18 2014/03/01 05:41:39 matt Exp $");
33 1.1 matt
34 1.1 matt #include <sys/param.h>
35 1.1 matt #include <sys/proc.h>
36 1.1 matt #include <sys/vnode.h>
37 1.1 matt #include <sys/systm.h>
38 1.1 matt
39 1.7 chris #include <arm/arm32/db_machdep.h>
40 1.13 christos #include <arm/cpufunc.h>
41 1.1 matt
42 1.1 matt #include <ddb/db_access.h>
43 1.1 matt #include <ddb/db_sym.h>
44 1.1 matt #include <ddb/db_output.h>
45 1.13 christos #include <ddb/db_variables.h>
46 1.13 christos #include <ddb/db_command.h>
47 1.1 matt
48 1.14 skrll #ifdef _KERNEL
49 1.13 christos static long nil;
50 1.1 matt
51 1.13 christos int db_access_und_sp(const struct db_variable *, db_expr_t *, int);
52 1.13 christos int db_access_abt_sp(const struct db_variable *, db_expr_t *, int);
53 1.13 christos int db_access_irq_sp(const struct db_variable *, db_expr_t *, int);
54 1.14 skrll #endif
55 1.13 christos
56 1.13 christos const struct db_variable db_regs[] = {
57 1.13 christos { "spsr", (long *)&DDB_REGS->tf_spsr, FCN_NULL, NULL },
58 1.13 christos { "r0", (long *)&DDB_REGS->tf_r0, FCN_NULL, NULL },
59 1.13 christos { "r1", (long *)&DDB_REGS->tf_r1, FCN_NULL, NULL },
60 1.13 christos { "r2", (long *)&DDB_REGS->tf_r2, FCN_NULL, NULL },
61 1.13 christos { "r3", (long *)&DDB_REGS->tf_r3, FCN_NULL, NULL },
62 1.13 christos { "r4", (long *)&DDB_REGS->tf_r4, FCN_NULL, NULL },
63 1.13 christos { "r5", (long *)&DDB_REGS->tf_r5, FCN_NULL, NULL },
64 1.13 christos { "r6", (long *)&DDB_REGS->tf_r6, FCN_NULL, NULL },
65 1.13 christos { "r7", (long *)&DDB_REGS->tf_r7, FCN_NULL, NULL },
66 1.13 christos { "r8", (long *)&DDB_REGS->tf_r8, FCN_NULL, NULL },
67 1.13 christos { "r9", (long *)&DDB_REGS->tf_r9, FCN_NULL, NULL },
68 1.13 christos { "r10", (long *)&DDB_REGS->tf_r10, FCN_NULL, NULL },
69 1.13 christos { "r11", (long *)&DDB_REGS->tf_r11, FCN_NULL, NULL },
70 1.13 christos { "r12", (long *)&DDB_REGS->tf_r12, FCN_NULL, NULL },
71 1.13 christos { "usr_sp", (long *)&DDB_REGS->tf_usr_sp, FCN_NULL, NULL },
72 1.13 christos { "usr_lr", (long *)&DDB_REGS->tf_usr_lr, FCN_NULL, NULL },
73 1.13 christos { "svc_sp", (long *)&DDB_REGS->tf_svc_sp, FCN_NULL, NULL },
74 1.13 christos { "svc_lr", (long *)&DDB_REGS->tf_svc_lr, FCN_NULL, NULL },
75 1.13 christos { "pc", (long *)&DDB_REGS->tf_pc, FCN_NULL, NULL },
76 1.14 skrll #ifdef _KERNEL
77 1.13 christos { "und_sp", &nil, db_access_und_sp, NULL },
78 1.13 christos { "abt_sp", &nil, db_access_abt_sp, NULL },
79 1.13 christos { "irq_sp", &nil, db_access_irq_sp, NULL },
80 1.14 skrll #endif
81 1.13 christos };
82 1.13 christos
83 1.13 christos const struct db_variable * const db_eregs = db_regs + sizeof(db_regs)/sizeof(db_regs[0]);
84 1.13 christos
85 1.13 christos const struct db_command db_machine_command_table[] = {
86 1.13 christos { DDB_ADD_CMD("frame", db_show_frame_cmd, 0,
87 1.13 christos "Displays the contents of a trapframe",
88 1.13 christos "[address]",
89 1.13 christos " address:\taddress of trapfame to display")},
90 1.13 christos #ifdef _KERNEL
91 1.15 matt { DDB_ADD_CMD("fault", db_show_fault_cmd, 0,
92 1.15 matt "Displays the fault registers",
93 1.15 matt NULL,NULL) },
94 1.13 christos #endif
95 1.18 matt #if defined(_KERNEL) && (defined(CPU_CORTEXA5) || defined(CPU_CORTEXA7))
96 1.18 matt { DDB_ADD_CMD("tlb", db_show_tlb_cmd, 0,
97 1.18 matt "Displays the TLB",
98 1.18 matt NULL,NULL) },
99 1.18 matt #endif
100 1.13 christos #ifdef ARM32_DB_COMMANDS
101 1.13 christos ARM32_DB_COMMANDS,
102 1.13 christos #endif
103 1.13 christos { DDB_ADD_CMD(NULL, NULL, 0,NULL,NULL,NULL) }
104 1.13 christos };
105 1.13 christos
106 1.14 skrll #ifdef _KERNEL
107 1.13 christos int
108 1.13 christos db_access_und_sp(const struct db_variable *vp, db_expr_t *valp, int rw)
109 1.13 christos {
110 1.13 christos
111 1.13 christos if (rw == DB_VAR_GET)
112 1.13 christos *valp = get_stackptr(PSR_UND32_MODE);
113 1.13 christos return(0);
114 1.13 christos }
115 1.13 christos
116 1.13 christos int
117 1.13 christos db_access_abt_sp(const struct db_variable *vp, db_expr_t *valp, int rw)
118 1.13 christos {
119 1.13 christos
120 1.13 christos if (rw == DB_VAR_GET)
121 1.13 christos *valp = get_stackptr(PSR_ABT32_MODE);
122 1.13 christos return(0);
123 1.13 christos }
124 1.13 christos
125 1.13 christos int
126 1.13 christos db_access_irq_sp(const struct db_variable *vp, db_expr_t *valp, int rw)
127 1.13 christos {
128 1.13 christos
129 1.13 christos if (rw == DB_VAR_GET)
130 1.13 christos *valp = get_stackptr(PSR_IRQ32_MODE);
131 1.13 christos return(0);
132 1.13 christos }
133 1.13 christos
134 1.1 matt void
135 1.15 matt db_show_fault_cmd(db_expr_t addr, bool have_addr, db_expr_t count, const char *modif)
136 1.15 matt {
137 1.18 matt db_printf("DFAR=%#x DFSR=%#x IFAR=%#x IFSR=%#x\n",
138 1.15 matt armreg_dfar_read(), armreg_dfsr_read(),
139 1.18 matt armreg_ifar_read(), armreg_ifsr_read());
140 1.18 matt db_printf("CONTEXTIDR=%#x TTBCR=%#x TTBR=%#x\n",
141 1.18 matt armreg_contextidr_read(), armreg_ttbcr_read(),
142 1.15 matt armreg_ttbr_read());
143 1.15 matt }
144 1.18 matt
145 1.18 matt #if defined(CPU_CORTEXA5) || defined(CPU_CORTEXA7)
146 1.18 matt static void
147 1.18 matt tlb_print_common_header(const char *str)
148 1.18 matt {
149 1.18 matt db_printf("-W/I-- ----VA---- ----PA---- --SIZE-- D AP XN ASD %s\n", str);
150 1.18 matt }
151 1.18 matt
152 1.18 matt static void
153 1.18 matt tlb_print_addr(size_t way, size_t va_index, vaddr_t vpn, paddr_t pfn)
154 1.18 matt {
155 1.18 matt db_printf("[%1zu:%02zx] 0x%05lx000 0x%05lx000", way, va_index, vpn, pfn);
156 1.18 matt }
157 1.18 matt
158 1.18 matt static void
159 1.18 matt tlb_print_size_domain_prot(const char *sizestr, u_int domain, u_int ap,
160 1.18 matt bool xn_p)
161 1.18 matt {
162 1.18 matt db_printf(" %8s %1x %2d %s", sizestr, domain, ap, (xn_p ? "XN" : "--"));
163 1.18 matt }
164 1.18 matt
165 1.18 matt static void
166 1.18 matt tlb_print_asid(bool ng_p, tlb_asid_t asid)
167 1.18 matt {
168 1.18 matt if (ng_p) {
169 1.18 matt db_printf(" %3d", asid);
170 1.18 matt } else {
171 1.18 matt db_printf(" ---");
172 1.18 matt }
173 1.18 matt }
174 1.18 matt
175 1.18 matt struct db_tlbinfo {
176 1.18 matt vaddr_t (*dti_decode_vpn)(size_t, uint32_t, uint32_t);
177 1.18 matt void (*dti_print_header)(void);
178 1.18 matt void (*dti_print_entry)(size_t, size_t, uint32_t, uint32_t);
179 1.18 matt u_int dti_index;
180 1.18 matt };
181 1.18 matt
182 1.18 matt #if defined(CPU_CORTEXA5)
183 1.18 matt static void
184 1.18 matt tlb_print_cortex_a5_header(void)
185 1.18 matt {
186 1.18 matt tlb_print_common_header(" S TEX C B");
187 1.18 matt }
188 1.18 matt
189 1.18 matt static vaddr_t
190 1.18 matt tlb_decode_cortex_a5_vpn(size_t va_index, uint32_t d0, uint32_t d1)
191 1.18 matt {
192 1.18 matt const uint64_t d = ((uint64_t)d1 << 32) | d0;
193 1.18 matt
194 1.18 matt const u_int size = __SHIFTOUT(d, ARM_A5_TLBDATA_SIZE);
195 1.18 matt return __SHIFTOUT(d, ARM_A5_TLBDATA_VA) * (ARM_A5_TLBDATAOP_INDEX + 1)
196 1.18 matt + (va_index << (4*size));
197 1.18 matt }
198 1.18 matt
199 1.18 matt static void
200 1.18 matt tlb_print_cortex_a5_entry(size_t way, size_t va_index, uint32_t d0, uint32_t d1)
201 1.18 matt {
202 1.18 matt static const char size_strings[4][8] = {
203 1.18 matt " 4KB ", " 64KB ", " 1MB ", " 16MB ",
204 1.18 matt };
205 1.18 matt
206 1.18 matt const uint64_t d = ((uint64_t)d1 << 32) | d0;
207 1.18 matt
208 1.18 matt const paddr_t pfn = __SHIFTOUT(d, ARM_A5_TLBDATA_PA);
209 1.18 matt const vaddr_t vpn = tlb_decode_cortex_a5_vpn(va_index, d0, d1);
210 1.18 matt
211 1.18 matt tlb_print_addr(way, va_index, vpn, pfn);
212 1.18 matt
213 1.18 matt const u_int size = __SHIFTOUT(d, ARM_A5_TLBDATA_SIZE);
214 1.18 matt const u_int domain = __SHIFTOUT(d, ARM_A5_TLBDATA_DOM);
215 1.18 matt const u_int ap = __SHIFTOUT(d, ARM_A5_TLBDATA_AP);
216 1.18 matt const bool xn_p = (d & ARM_A5_TLBDATA_XN) != 0;
217 1.18 matt
218 1.18 matt tlb_print_size_domain_prot(size_strings[size], domain, ap, xn_p);
219 1.18 matt
220 1.18 matt const bool ng_p = (d & ARM_A5_TLBDATA_nG) != 0;
221 1.18 matt const tlb_asid_t asid = __SHIFTOUT(d, ARM_A5_TLBDATA_ASID);
222 1.18 matt
223 1.18 matt tlb_print_asid(ng_p, asid);
224 1.18 matt
225 1.18 matt const u_int tex = __SHIFTOUT(d, ARM_A5_TLBDATA_TEX);
226 1.18 matt const bool c_p = (d & ARM_A5_TLBDATA_C) != 0;
227 1.18 matt const bool b_p = (d & ARM_A5_TLBDATA_B) != 0;
228 1.18 matt const bool s_p = (d & ARM_A5_TLBDATA_S) != 0;
229 1.18 matt
230 1.18 matt db_printf(" %c %d %c %c\n", (s_p ? 'S' : '-'), tex,
231 1.18 matt (c_p ? 'C' : '-'), (b_p ? 'B' : '-'));
232 1.18 matt }
233 1.18 matt
234 1.18 matt static const struct db_tlbinfo tlb_cortex_a5_info = {
235 1.18 matt .dti_decode_vpn = tlb_decode_cortex_a5_vpn,
236 1.18 matt .dti_print_header = tlb_print_cortex_a5_header,
237 1.18 matt .dti_print_entry = tlb_print_cortex_a5_entry,
238 1.18 matt .dti_index = ARM_A5_TLBDATAOP_INDEX,
239 1.18 matt };
240 1.18 matt #endif /* CPU_CORTEXA5 */
241 1.18 matt
242 1.18 matt #if defined(CPU_CORTEXA7)
243 1.18 matt static const char tlb_cortex_a7_esizes[8][8] = {
244 1.18 matt " 4KB(S)", " 4KB(L)", "64KB(S)", "64KB(L)",
245 1.18 matt " 1MB(S)", " 2MB(L)", "16MB(S)", " 1GB(L)",
246 1.18 matt };
247 1.18 matt
248 1.18 matt static void
249 1.18 matt tlb_print_cortex_a7_header(void)
250 1.18 matt {
251 1.18 matt tlb_print_common_header("IS --OS- SH");
252 1.18 matt }
253 1.18 matt
254 1.18 matt static inline vaddr_t
255 1.18 matt tlb_decode_cortex_a7_vpn(size_t va_index, uint32_t d0, uint32_t d1)
256 1.18 matt {
257 1.18 matt const u_int size = __SHIFTOUT(d0, ARM_A7_TLBDATA0_SIZE);
258 1.18 matt const u_int shift = (size & 1)
259 1.18 matt ? ((0x12090400 >> (8*size)) & 0x1f)
260 1.18 matt : (2 * size);
261 1.18 matt
262 1.18 matt return __SHIFTOUT(d0, ARM_A7_TLBDATA0_VA) * (ARM_A7_TLBDATAOP_INDEX + 1)
263 1.18 matt + (va_index << shift);
264 1.18 matt }
265 1.18 matt
266 1.18 matt static void
267 1.18 matt tlb_print_cortex_a7_entry(size_t way, size_t va_index, uint32_t d0, uint32_t d1)
268 1.18 matt {
269 1.18 matt const uint32_t d2 = armreg_tlbdata2_read();
270 1.18 matt const uint64_t d01 = ((uint64_t)d1 << 32) | d0;
271 1.18 matt const uint64_t d12 = ((uint64_t)d2 << 32) | d1;
272 1.18 matt
273 1.18 matt const paddr_t pfn = __SHIFTOUT(d12, ARM_A7_TLBDATA12_PA);
274 1.18 matt const vaddr_t vpn = tlb_decode_cortex_a7_vpn(va_index, d0, d1);
275 1.18 matt
276 1.18 matt tlb_print_addr(way, va_index, vpn, pfn);
277 1.18 matt
278 1.18 matt const u_int size = __SHIFTOUT(d0, ARM_A7_TLBDATA0_SIZE);
279 1.18 matt const u_int domain = __SHIFTOUT(d2, ARM_A7_TLBDATA2_DOM);
280 1.18 matt const u_int ap = __SHIFTOUT(d1, ARM_A7_TLBDATA1_AP);
281 1.18 matt const bool xn_p = (d2 & ARM_A7_TLBDATA2_XN1) != 0;
282 1.18 matt
283 1.18 matt tlb_print_size_domain_prot(tlb_cortex_a7_esizes[size], domain, ap, xn_p);
284 1.18 matt
285 1.18 matt const bool ng_p = (d1 & ARM_A7_TLBDATA1_nG) != 0;
286 1.18 matt const tlb_asid_t asid = __SHIFTOUT(d01, ARM_A7_TLBDATA01_ASID);
287 1.18 matt
288 1.18 matt tlb_print_asid(ng_p, asid);
289 1.18 matt
290 1.18 matt const u_int is = __SHIFTOUT(d2, ARM_A7_TLBDATA2_IS);
291 1.18 matt if (is == ARM_A7_TLBDATA2_IS_DSO) {
292 1.18 matt u_int mt = __SHIFTOUT(d2, ARM_A7_TLBDATA2_SDO_MT);
293 1.18 matt switch (mt) {
294 1.18 matt case ARM_A7_TLBDATA2_SDO_MT_D:
295 1.18 matt db_printf(" DV\n");
296 1.18 matt return;
297 1.18 matt case ARM_A7_TLBDATA2_SDO_MT_SO:
298 1.18 matt db_printf(" SO\n");
299 1.18 matt return;
300 1.18 matt default:
301 1.18 matt db_printf(" %02u\n", mt);
302 1.18 matt return;
303 1.18 matt }
304 1.18 matt }
305 1.18 matt const u_int os = __SHIFTOUT(d2, ARM_A7_TLBDATA2_OS);
306 1.18 matt const u_int sh = __SHIFTOUT(d2, ARM_A7_TLBDATA2_SH);
307 1.18 matt static const char is_types[3][3] = { "NC", "WB", "WT" };
308 1.18 matt static const char os_types[4][6] = { "NC", "WB+WA", "WT", "WB" };
309 1.18 matt static const char sh_types[4][3] = { "NC", "na", "OS", "IS" };
310 1.18 matt db_printf(" %2s %5s %2s\n", is_types[is], os_types[os], sh_types[sh]);
311 1.18 matt }
312 1.18 matt
313 1.18 matt static const struct db_tlbinfo tlb_cortex_a7_info = {
314 1.18 matt .dti_decode_vpn = tlb_decode_cortex_a7_vpn,
315 1.18 matt .dti_print_header = tlb_print_cortex_a7_header,
316 1.18 matt .dti_print_entry = tlb_print_cortex_a7_entry,
317 1.18 matt .dti_index = ARM_A7_TLBDATAOP_INDEX,
318 1.18 matt };
319 1.18 matt #endif /* CPU_CORTEXA7 */
320 1.18 matt
321 1.18 matt static inline const struct db_tlbinfo *
322 1.18 matt tlb_lookup_tlbinfo(void)
323 1.18 matt {
324 1.18 matt #if defined(CPU_CORTEXA5) && defined(CPU_CORTEXA7)
325 1.18 matt const bool cortex_a5_p = CPU_ID_CORTEX_A5_P(curcpu()->ci_arm_cpuid);
326 1.18 matt const bool cortex_a7_p = CPU_ID_CORTEX_A7_P(curcpu()->ci_arm_cpuid);
327 1.18 matt #elif defined(CPU_CORTEXA5)
328 1.18 matt const bool cortex_a5_p = true;
329 1.18 matt #else
330 1.18 matt const bool cortex_a7_p = true;
331 1.18 matt #endif
332 1.18 matt #ifdef CPU_CORTEXA5
333 1.18 matt if (cortex_a5_p) {
334 1.18 matt return &tlb_cortex_a5_info;
335 1.18 matt }
336 1.13 christos #endif
337 1.18 matt #ifdef CPU_CORTEXA7
338 1.18 matt if (cortex_a7_p) {
339 1.18 matt return &tlb_cortex_a7_info;
340 1.18 matt }
341 1.18 matt #endif
342 1.18 matt return NULL;
343 1.18 matt }
344 1.18 matt
345 1.18 matt void
346 1.18 matt db_show_tlb_cmd(db_expr_t addr, bool have_addr, db_expr_t count, const char *modif)
347 1.18 matt {
348 1.18 matt const struct db_tlbinfo * const dti = tlb_lookup_tlbinfo();
349 1.18 matt
350 1.18 matt if (have_addr) {
351 1.18 matt const vaddr_t vpn = (vaddr_t)addr >> L2_S_SHIFT;
352 1.18 matt const u_int va_index = vpn & dti->dti_index;
353 1.18 matt for (size_t way = 0; way < 2; way++) {
354 1.18 matt armreg_tlbdataop_write(
355 1.18 matt __SHIFTIN(va_index, dti->dti_index)
356 1.18 matt | __SHIFTIN(way, ARM_TLBDATAOP_WAY));
357 1.18 matt __asm("isb");
358 1.18 matt const uint32_t d0 = armreg_tlbdata0_read();
359 1.18 matt const uint32_t d1 = armreg_tlbdata1_read();
360 1.18 matt if ((d0 & ARM_TLBDATA_VALID)
361 1.18 matt && vpn == (*dti->dti_decode_vpn)(va_index, d0, d1)) {
362 1.18 matt (*dti->dti_print_header)();
363 1.18 matt (*dti->dti_print_entry)(way, va_index, d0, d1);
364 1.18 matt return;
365 1.18 matt }
366 1.18 matt }
367 1.18 matt db_printf("VA %#"DDB_EXPR_FMT"x not found in TLB\n", addr);
368 1.18 matt return;
369 1.18 matt }
370 1.18 matt
371 1.18 matt bool first = true;
372 1.18 matt size_t n = 0;
373 1.18 matt for (size_t va_index = 0; va_index <= dti->dti_index; va_index++) {
374 1.18 matt for (size_t way = 0; way < 2; way++) {
375 1.18 matt armreg_tlbdataop_write(
376 1.18 matt __SHIFTIN(way, ARM_TLBDATAOP_WAY)
377 1.18 matt | __SHIFTIN(va_index, dti->dti_index));
378 1.18 matt __asm("isb");
379 1.18 matt const uint32_t d0 = armreg_tlbdata0_read();
380 1.18 matt const uint32_t d1 = armreg_tlbdata1_read();
381 1.18 matt if (d0 & ARM_TLBDATA_VALID) {
382 1.18 matt if (first) {
383 1.18 matt (*dti->dti_print_header)();
384 1.18 matt first = false;
385 1.18 matt }
386 1.18 matt (*dti->dti_print_entry)(way, va_index, d0, d1);
387 1.18 matt n++;
388 1.18 matt }
389 1.18 matt }
390 1.18 matt }
391 1.18 matt db_printf("%zu TLB valid entries found\n", n);
392 1.18 matt }
393 1.18 matt #endif /* CPU_CORTEXA5 || CPU_CORTEXA7 */
394 1.18 matt #endif /* _KERNEL */
395 1.1 matt
396 1.1 matt
397 1.1 matt void
398 1.12 dsl db_show_frame_cmd(db_expr_t addr, bool have_addr, db_expr_t count, const char *modif)
399 1.1 matt {
400 1.1 matt struct trapframe *frame;
401 1.1 matt
402 1.1 matt if (!have_addr) {
403 1.1 matt db_printf("frame address must be specified\n");
404 1.1 matt return;
405 1.1 matt }
406 1.1 matt
407 1.1 matt frame = (struct trapframe *)addr;
408 1.1 matt
409 1.1 matt db_printf("frame address = %08x ", (u_int)frame);
410 1.1 matt db_printf("spsr=%08x\n", frame->tf_spsr);
411 1.1 matt db_printf("r0 =%08x r1 =%08x r2 =%08x r3 =%08x\n",
412 1.1 matt frame->tf_r0, frame->tf_r1, frame->tf_r2, frame->tf_r3);
413 1.1 matt db_printf("r4 =%08x r5 =%08x r6 =%08x r7 =%08x\n",
414 1.1 matt frame->tf_r4, frame->tf_r5, frame->tf_r6, frame->tf_r7);
415 1.1 matt db_printf("r8 =%08x r9 =%08x r10=%08x r11=%08x\n",
416 1.1 matt frame->tf_r8, frame->tf_r9, frame->tf_r10, frame->tf_r11);
417 1.1 matt db_printf("r12=%08x r13=%08x r14=%08x r15=%08x\n",
418 1.1 matt frame->tf_r12, frame->tf_usr_sp, frame->tf_usr_lr, frame->tf_pc);
419 1.1 matt db_printf("slr=%08x\n", frame->tf_svc_lr);
420 1.1 matt }
421