diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-12-16 16:54:16 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-12-16 16:54:16 -0500 |
commit | 0db2812a5240f2663b92d8d4b761122dd2e0c6c3 (patch) | |
tree | 4966ada2a4a75dc89b7038ac1694a8acc4d3aa3f /arch/tile/kernel/kgdb.c | |
parent | eb64c3c6cdb8fa8a4d324eb71a9033b62e150918 (diff) | |
parent | c47b15c4928c46b889a1ea2e9b54f4110514e1c3 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile
Pull arch/tile updates from Chris Metcalf:
"Note that one of the changes converts my old cmetcalf@tilera.com email
in MAINTAINERS to the cmetcalf@ezchip.com email that you see on this
email"
* git://git.kernel.org/pub/scm/linux/kernel/git/cmetcalf/linux-tile:
arch/tile: update MAINTAINERS email to EZchip
tile: avoid undefined behavior with regs[TREG_TP] etc
arch: tile: kernel: kgdb.c: Use memcpy() instead of pointer copy one by one
tile: Use the more common pr_warn instead of pr_warning
arch: tile: gxio: Export symbols for module using in 'mpipe.c'
arch: tile: kernel: signal.c: Use __copy_from/to_user() instead of __get/put_user()
Diffstat (limited to 'arch/tile/kernel/kgdb.c')
-rw-r--r-- | arch/tile/kernel/kgdb.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/arch/tile/kernel/kgdb.c b/arch/tile/kernel/kgdb.c index 4cd88381a83e..ff5335ae050d 100644 --- a/arch/tile/kernel/kgdb.c +++ b/arch/tile/kernel/kgdb.c | |||
@@ -125,9 +125,7 @@ int dbg_set_reg(int regno, void *mem, struct pt_regs *regs) | |||
125 | void | 125 | void |
126 | sleeping_thread_to_gdb_regs(unsigned long *gdb_regs, struct task_struct *task) | 126 | sleeping_thread_to_gdb_regs(unsigned long *gdb_regs, struct task_struct *task) |
127 | { | 127 | { |
128 | int reg; | ||
129 | struct pt_regs *thread_regs; | 128 | struct pt_regs *thread_regs; |
130 | unsigned long *ptr = gdb_regs; | ||
131 | 129 | ||
132 | if (task == NULL) | 130 | if (task == NULL) |
133 | return; | 131 | return; |
@@ -136,9 +134,7 @@ sleeping_thread_to_gdb_regs(unsigned long *gdb_regs, struct task_struct *task) | |||
136 | memset(gdb_regs, 0, NUMREGBYTES); | 134 | memset(gdb_regs, 0, NUMREGBYTES); |
137 | 135 | ||
138 | thread_regs = task_pt_regs(task); | 136 | thread_regs = task_pt_regs(task); |
139 | for (reg = 0; reg <= TREG_LAST_GPR; reg++) | 137 | memcpy(gdb_regs, thread_regs, TREG_LAST_GPR * sizeof(unsigned long)); |
140 | *(ptr++) = thread_regs->regs[reg]; | ||
141 | |||
142 | gdb_regs[TILEGX_PC_REGNUM] = thread_regs->pc; | 138 | gdb_regs[TILEGX_PC_REGNUM] = thread_regs->pc; |
143 | gdb_regs[TILEGX_FAULTNUM_REGNUM] = thread_regs->faultnum; | 139 | gdb_regs[TILEGX_FAULTNUM_REGNUM] = thread_regs->faultnum; |
144 | } | 140 | } |