Commit cde3f860 authored by Artem Bityutskiy's avatar Artem Bityutskiy Committed by Russell King

ARM: 5759/1: Add register information of threads to coredump

Defines ELF_CORE_COPY_TASK_REGS so that CPU register information
of every thread is included in coredump. Without this, only the faulting
thread is coredumped.

Cc: Roger Quadros <ext-roger.quadros@nokia.com>
Cc: linux-arm-kernel@lists.infradead.org
Signed-off-by: default avatarMika Westerberg <mika.westerberg@iki.fi>
Signed-off-by: default avatarArtem Bityutskiy <Artem.Bityutskiy@nokia.com>
Signed-off-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
parent a771fe6e
...@@ -98,6 +98,9 @@ extern int elf_check_arch(const struct elf32_hdr *); ...@@ -98,6 +98,9 @@ extern int elf_check_arch(const struct elf32_hdr *);
extern int arm_elf_read_implies_exec(const struct elf32_hdr *, int); extern int arm_elf_read_implies_exec(const struct elf32_hdr *, int);
#define elf_read_implies_exec(ex,stk) arm_elf_read_implies_exec(&(ex), stk) #define elf_read_implies_exec(ex,stk) arm_elf_read_implies_exec(&(ex), stk)
int dump_task_regs(struct task_struct *t, elf_gregset_t *elfregs);
#define ELF_CORE_COPY_TASK_REGS dump_task_regs
#define USE_ELF_CORE_DUMP #define USE_ELF_CORE_DUMP
#define ELF_EXEC_PAGESIZE 4096 #define ELF_EXEC_PAGESIZE 4096
......
...@@ -327,6 +327,15 @@ copy_thread(unsigned long clone_flags, unsigned long stack_start, ...@@ -327,6 +327,15 @@ copy_thread(unsigned long clone_flags, unsigned long stack_start,
return 0; return 0;
} }
/*
* Fill in the task's elfregs structure for a core dump.
*/
int dump_task_regs(struct task_struct *t, elf_gregset_t *elfregs)
{
elf_core_copy_regs(elfregs, task_pt_regs(t));
return 1;
}
/* /*
* fill in the fpe structure for a core dump... * fill in the fpe structure for a core dump...
*/ */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment