diff options
Diffstat (limited to 'arch/sh/include/asm/dwarf.h')
-rw-r--r-- | arch/sh/include/asm/dwarf.h | 30 |
1 files changed, 11 insertions, 19 deletions
diff --git a/arch/sh/include/asm/dwarf.h b/arch/sh/include/asm/dwarf.h index d3d3837c5e1b..ced6795891a6 100644 --- a/arch/sh/include/asm/dwarf.h +++ b/arch/sh/include/asm/dwarf.h | |||
@@ -200,7 +200,7 @@ | |||
200 | */ | 200 | */ |
201 | static __always_inline unsigned long dwarf_read_arch_reg(unsigned int reg) | 201 | static __always_inline unsigned long dwarf_read_arch_reg(unsigned int reg) |
202 | { | 202 | { |
203 | unsigned long value; | 203 | unsigned long value = 0; |
204 | 204 | ||
205 | switch (reg) { | 205 | switch (reg) { |
206 | case 14: | 206 | case 14: |
@@ -265,10 +265,7 @@ struct dwarf_frame { | |||
265 | 265 | ||
266 | unsigned long pc; | 266 | unsigned long pc; |
267 | 267 | ||
268 | struct dwarf_reg *regs; | 268 | struct list_head reg_list; |
269 | unsigned int num_regs; /* how many regs are allocated? */ | ||
270 | |||
271 | unsigned int depth; /* what level are we in the callstack? */ | ||
272 | 269 | ||
273 | unsigned long cfa; | 270 | unsigned long cfa; |
274 | 271 | ||
@@ -292,20 +289,15 @@ struct dwarf_frame { | |||
292 | * @flags: Describes how to calculate the value of this register | 289 | * @flags: Describes how to calculate the value of this register |
293 | */ | 290 | */ |
294 | struct dwarf_reg { | 291 | struct dwarf_reg { |
292 | struct list_head link; | ||
293 | |||
294 | unsigned int number; | ||
295 | |||
295 | unsigned long addr; | 296 | unsigned long addr; |
296 | unsigned long flags; | 297 | unsigned long flags; |
297 | #define DWARF_REG_OFFSET (1 << 0) | 298 | #define DWARF_REG_OFFSET (1 << 0) |
298 | }; | 299 | #define DWARF_VAL_OFFSET (1 << 1) |
299 | 300 | #define DWARF_UNDEFINED (1 << 2) | |
300 | /** | ||
301 | * dwarf_stack - a DWARF stack contains a collection of DWARF frames | ||
302 | * @depth: the number of frames in the stack | ||
303 | * @level: an array of DWARF frames, indexed by stack level | ||
304 | * | ||
305 | */ | ||
306 | struct dwarf_stack { | ||
307 | unsigned int depth; | ||
308 | struct dwarf_frame **level; | ||
309 | }; | 301 | }; |
310 | 302 | ||
311 | /* | 303 | /* |
@@ -370,17 +362,16 @@ static inline unsigned int DW_CFA_operand(unsigned long insn) | |||
370 | #define DW_EXT_HI 0xffffffff | 362 | #define DW_EXT_HI 0xffffffff |
371 | #define DW_EXT_DWARF64 DW_EXT_HI | 363 | #define DW_EXT_DWARF64 DW_EXT_HI |
372 | 364 | ||
373 | extern void dwarf_unwinder_init(void); | ||
374 | |||
375 | extern struct dwarf_frame *dwarf_unwind_stack(unsigned long, | 365 | extern struct dwarf_frame *dwarf_unwind_stack(unsigned long, |
376 | struct dwarf_frame *); | 366 | struct dwarf_frame *); |
377 | #endif /* __ASSEMBLY__ */ | 367 | #endif /* !__ASSEMBLY__ */ |
378 | 368 | ||
379 | #define CFI_STARTPROC .cfi_startproc | 369 | #define CFI_STARTPROC .cfi_startproc |
380 | #define CFI_ENDPROC .cfi_endproc | 370 | #define CFI_ENDPROC .cfi_endproc |
381 | #define CFI_DEF_CFA .cfi_def_cfa | 371 | #define CFI_DEF_CFA .cfi_def_cfa |
382 | #define CFI_REGISTER .cfi_register | 372 | #define CFI_REGISTER .cfi_register |
383 | #define CFI_REL_OFFSET .cfi_rel_offset | 373 | #define CFI_REL_OFFSET .cfi_rel_offset |
374 | #define CFI_UNDEFINED .cfi_undefined | ||
384 | 375 | ||
385 | #else | 376 | #else |
386 | 377 | ||
@@ -394,6 +385,7 @@ extern struct dwarf_frame *dwarf_unwind_stack(unsigned long, | |||
394 | #define CFI_DEF_CFA CFI_IGNORE | 385 | #define CFI_DEF_CFA CFI_IGNORE |
395 | #define CFI_REGISTER CFI_IGNORE | 386 | #define CFI_REGISTER CFI_IGNORE |
396 | #define CFI_REL_OFFSET CFI_IGNORE | 387 | #define CFI_REL_OFFSET CFI_IGNORE |
388 | #define CFI_UNDEFINED CFI_IGNORE | ||
397 | 389 | ||
398 | #ifndef __ASSEMBLY__ | 390 | #ifndef __ASSEMBLY__ |
399 | static inline void dwarf_unwinder_init(void) | 391 | static inline void dwarf_unwinder_init(void) |