* gdb stopped working in 2.5.10 - works fine in 2.4.x
@ 2002-04-26 12:57 Jurriaan on Alpha
2002-04-26 14:07 ` [patch] " Ivan Kokshaysky
0 siblings, 1 reply; 2+ messages in thread
From: Jurriaan on Alpha @ 2002-04-26 12:57 UTC (permalink / raw)
To: linux-kernel
ALPHA :gdb ./angband
GNU gdb 5.1.1
Copyright 2002 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "alpha-linux"...
(gdb) run
Starting program: /usr/local/games/angband-2.9.7-alpha1/./angband
warning: Cannot insert breakpoint -2:
Cannot access memory at address 0xcc1088a823d9d62c
(gdb) q
The program is running. Exit anyway? (y or n) y
ALPHA :
the breakpoint with a negative number, followed by the message 'Cannot
access memory at ...' happens on any executable I try with gdb.
This didn't happen with the 2.4.x kernels, so I suspect something in
2.5.x. Any ideas?
Thanks,
Jurriaan
--
After penetrating your skull the decibel storm of raucous riffs and
blistering glissandos starts rearranging the synapses in your brain.
You have arrived on the territory of Tribe Apocalyptica.
Apocalyptica, liner notes to 'Cult'
GNU/Linux 2.5.10 on Debian/Alpha 990 bogomips load:0.15 0.53 0.66
^ permalink raw reply [flat|nested] 2+ messages in thread
* [patch] Re: gdb stopped working in 2.5.10 - works fine in 2.4.x
2002-04-26 12:57 gdb stopped working in 2.5.10 - works fine in 2.4.x Jurriaan on Alpha
@ 2002-04-26 14:07 ` Ivan Kokshaysky
0 siblings, 0 replies; 2+ messages in thread
From: Ivan Kokshaysky @ 2002-04-26 14:07 UTC (permalink / raw)
To: Jurriaan on Alpha; +Cc: Linus Torvalds, Richard Henderson, linux-kernel
On Fri, Apr 26, 2002 at 02:57:36PM +0200, Jurriaan on Alpha wrote:
> the breakpoint with a negative number, followed by the message 'Cannot
> access memory at ...' happens on any executable I try with gdb.
>
> This didn't happen with the 2.4.x kernels, so I suspect something in
> 2.5.x. Any ideas?
Yes, gdb and strace are broken since 2.5.6, IIRC.
Some necessary 'thread_info' changes still are missing in ptrace.c.
Fix appended.
Ivan.
--- 2.5.9/arch/alpha/kernel/ptrace.c Sun Apr 14 23:18:55 2002
+++ linux/arch/alpha/kernel/ptrace.c Mon Apr 15 18:36:43 2002
@@ -106,7 +106,7 @@ get_reg_addr(struct task_struct * task,
zero = 0;
addr = &zero;
} else {
- addr = (long *)((long)task + regoff[regno]);
+ addr = (long *)((long)task->thread_info + regoff[regno]);
}
return addr;
}
@@ -340,9 +340,9 @@ sys_ptrace(long request, long pid, long
if ((unsigned long) data > _NSIG)
goto out;
if (request == PTRACE_SYSCALL)
- set_thread_flag(TIF_SYSCALL_TRACE);
+ set_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
else
- clear_thread_flag(TIF_SYSCALL_TRACE);
+ clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
child->exit_code = data;
wake_up_process(child);
/* make sure single-step breakpoint is gone. */
@@ -371,7 +371,7 @@ sys_ptrace(long request, long pid, long
goto out;
/* Mark single stepping. */
child->thread_info->bpt_nsaved = -1;
- clear_thread_flag(TIF_SYSCALL_TRACE);
+ clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE);
wake_up_process(child);
child->exit_code = data;
/* give it a chance to run. */
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2002-04-26 14:07 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-04-26 12:57 gdb stopped working in 2.5.10 - works fine in 2.4.x Jurriaan on Alpha
2002-04-26 14:07 ` [patch] " Ivan Kokshaysky
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox