kgdb
[Top] [All Lists]

Re: kgdb and 2.2.14-5 from RH 6-2.

To: Douglas Kilpatrick <dougk@xxxxxxxxxxx>
Subject: Re: kgdb and 2.2.14-5 from RH 6-2.
From: sfoehner@xxxxxxxxxxxxxxxxxxx (Scott Foehner)
Date: Mon, 3 Apr 2000 15:05:49 -0700 (PDT)
Cc: kgdb@xxxxxxxxxxx
In-reply-to: Douglas Kilpatrick <dougk@xxxxxxxxxxx> "kgdb and 2.2.14-5 from RH 6-2." (Mar 31, 7:42pm)
References: <Pine.LNX.4.10.10003311929440.19930-100000@xxxxxxxxxxxxxxxxxxxxxxxx>
Sender: owner-kgdb@xxxxxxxxxxx
Doug,

The early connect changes I made to kgdb were accepted by the maintainer
of the kgdb patch.  Thus, instead of maintaining a separate patch, I now just
point people to his patch.  However, he is now only working on 2.3 versions
of the patch.  You can check his stuff out at

ftp://www.gcom.com/pub/linux/src/kgdb-2.3.35

That patch is also available from the kgdb project site on oss.sgi.com.  You
can check out http://oss.sgi.com/projects/kgdb/news.html for more details.

Most of that info was probably not useful to you, though, since it looks like
you need to be working with 2.2.14.  I don't really have plans to advance a
2.2.x series of the patch, but if you were to send me one with the fixes/
additions you noted, I could put it up on the web site.

I don't quite understand why you want to be able to drop into the debugger
when doing a sysrq on the machine you are debugging.  If you just send the
break character from the machine running gdb, it will drop into the debugger.
I think this is the preferred way, because that way you don't have to mess
with the machine running the kernel you are debugging.

I'm not sure why you are seeing the oops.  Are you using kdb as well?  If you
add kdb, you might be able to debug the problem.  If you have more details on
why the kernel is panicing, let me know.

Scott

On Mar 31,  7:42pm, Douglas Kilpatrick wrote:
> Subject: kgdb and 2.2.14-5 from RH 6-2.
>
> First the easy stuff:
>
> init/main.c:
>
> The patch reads:
>
> +               if (!strcmp(line,"gdbttyS=")) {
> +                       gdb_ttyS = simple_strtoul(line+8,NULL,10);
> +                       continue;
> +               }
> +               if (!strcmp(line,"gdbbaud=")) {
> +                       gdb_baud = simple_strtoul(line+8,NULL,10);
> +                       continue;
> +               }
>
> Those are, of course, supposed to be:
>               if (!strncmp(line,"gdbttyS=",8)) {
>
> Also, since going into the debugger at any arbitrary point is usefull
> I added a few lines to sysrq.c.  Sorry this isn't in patch format but
> I'm trying to do module development not kernel development and so don't
> have a clean copy of kernel source to diff.
>
> Anyway, at line 31, after the CONFIG_APM section:
>
> #ifdef CONFIG_GDB
> extern int gdb_hook(void);
> #endif
>
> and at line 141, after the case 'l' section:
>
> #ifdef CONFIG_GDB
>         case 'g':
>                 gdb_hook();
>                 break;
> #endif
>
> Now for the more fundamental issue:
>
> Attaching to the debugger appears to work, but as soon as I continue from
> gdb, the system Oops', then panics and locks.  Things never get sent back
> into gdb, and it crashes too quickly for syslog to write out the oops message
> so I don't know what the stack looks like yet.
>
> This happens if I attach at boot or via sysctl, so I'm pretty sure its not
> something I've done.  If it matters, I can provide my .config, but basically
> its a RH6.2 stock (as if) kernel with SCSI/sound/RAID/stuff I don't need
> removed, and the kgdb0.2-2.2.12 patch applied. (Minus the root-level makefile
> changes that somehow made it into the RH 2.2.14 kernel)
>
>
> Any ideas?  Anyone seen this before?
>
> Doug
> --
> dougk@xxxxxxxxxxx
> dkilpatr@xxxxxxx
> Will crash Linux for food.
>-- End of excerpt from Douglas Kilpatrick



-- 
Scott Foehner                   SGI
sfoehner@xxxxxxxxxxxx           Computer Systems Business Unit
650-933-3473                    Core OS

<Prev in Thread] Current Thread [Next in Thread>