diff options
| author | Linus Torvalds <[email protected]> | 2018-08-22 14:06:37 -0700 |
|---|---|---|
| committer | Linus Torvalds <[email protected]> | 2018-08-22 14:06:37 -0700 |
| commit | 45b74a65b9934d5e1520d97aa4e09cf2b8c69ac0 (patch) | |
| tree | 7c451271a6c274da9b7f37fcb2592d4cfc972644 /arch/parisc/kernel/traps.c | |
| parent | 433bcf67370bc170a345634aa1be4ee8ac905de9 (diff) | |
| parent | dbf2a4b1ffab2867505be3b24221d5efa2200c91 (diff) | |
Merge branch 'parisc-4.19-2' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux
Pull more parisc updates from Helge Deller:
- fix boot failure of 64-bit kernel. It got broken by the unwind
optimization commit in merge window.
- fix 64-bit userspace support (static 64-bit applications only, e.g.
we don't yet have 64-bit userspace support in glibc).
- consolidate unwind initialization code.
- add machine model description to stack trace.
* 'parisc-4.19-2' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
parisc: Add hardware description to stack traces
parisc: Fix boot failure of 64-bit kernel
parisc: Consolidate unwind initialization calls
parisc: Update comments in syscall.S regarding wide userland
parisc: Fix ptraced 64-bit applications to call 64-bit syscalls
parisc: Restore possibility to execute 64-bit applications
Diffstat (limited to 'arch/parisc/kernel/traps.c')
| -rw-r--r-- | arch/parisc/kernel/traps.c | 37 |
1 files changed, 6 insertions, 31 deletions
diff --git a/arch/parisc/kernel/traps.c b/arch/parisc/kernel/traps.c index 318815212518..68f10f87073d 100644 --- a/arch/parisc/kernel/traps.c +++ b/arch/parisc/kernel/traps.c @@ -45,7 +45,7 @@ #include "../math-emu/math-emu.h" /* for handle_fpe() */ -static void parisc_show_stack(struct task_struct *task, unsigned long *sp, +static void parisc_show_stack(struct task_struct *task, struct pt_regs *regs); static int printbinary(char *buf, unsigned long x, int nbits) @@ -152,7 +152,7 @@ void show_regs(struct pt_regs *regs) printk("%s IAOQ[1]: %pS\n", level, (void *) regs->iaoq[1]); printk("%s RP(r2): %pS\n", level, (void *) regs->gr[2]); - parisc_show_stack(current, NULL, regs); + parisc_show_stack(current, regs); } } @@ -185,44 +185,19 @@ static void do_show_stack(struct unwind_frame_info *info) printk(KERN_CRIT "\n"); } -static void parisc_show_stack(struct task_struct *task, unsigned long *sp, +static void parisc_show_stack(struct task_struct *task, struct pt_regs *regs) { struct unwind_frame_info info; - struct task_struct *t; - t = task ? task : current; - if (regs) { - unwind_frame_init(&info, t, regs); - goto show_stack; - } - - if (t == current) { - unsigned long sp; - -HERE: - asm volatile ("copy %%r30, %0" : "=r"(sp)); - { - struct pt_regs r; - - memset(&r, 0, sizeof(struct pt_regs)); - r.iaoq[0] = (unsigned long)&&HERE; - r.gr[2] = (unsigned long)__builtin_return_address(0); - r.gr[30] = sp; - - unwind_frame_init(&info, current, &r); - } - } else { - unwind_frame_init_from_blocked_task(&info, t); - } + unwind_frame_init_task(&info, task, regs); -show_stack: do_show_stack(&info); } void show_stack(struct task_struct *t, unsigned long *sp) { - return parisc_show_stack(t, sp, NULL); + parisc_show_stack(t, NULL); } int is_valid_bugaddr(unsigned long iaoq) @@ -557,7 +532,7 @@ void notrace handle_interruption(int code, struct pt_regs *regs) cpu_lpmc(5, regs); return; - case 6: + case PARISC_ITLB_TRAP: /* Instruction TLB miss fault/Instruction page fault */ fault_address = regs->iaoq[0]; fault_space = regs->iasq[0]; |