regarding kgdb in ppc

Vijay Sampath vsampath at gmail.com
Fri Dec 29 12:02:21 EST 2006


> >  I have checked all the above and are enabled in the config.  I have tried
> > changing the kernel command line argumnets.
> >
> >  I get the same error saying:  (All from init/main.c)
> >  ----
> >  unable to open an initial console
> >  No init found.  Try passing init= option to kernel.

You need to pass init=/path/to/initprogram and console=ttySx,9600n81
or something similar. This will however only work if you have
configured your root filesystem correctly. This could be a ramdisk,
harddisk partition, flash or nfs. The method for doing each is
different.

> >  I am getting the following error:
> >
> >  root at localhost sudheer]# /opt/eldk-3.1.1/usr/bin/ppc_85xx-gdb vmlinux
> >  GNU gdb Red Hat Linux (6.3.0.0-1.21_1rh)
> >  ...
> >  This GDB was configured as "--host=i386-redhat-linux --target=ppc-linux"...
> >  (gdb) set remotebaud 115200
> >  (gdb) target remote /dev/ttyS0
> >  Remote debugging using /dev/ttyS0
> >  Ignoring packet error, continuing...

This probably means that gdb on host could not communicate with the
gdb stub on target. To ensure target is running gdb stub, connect a
terminal program (example minicom on /dev/ttyS0) and ensure you are
getting output similar to this line: "$T0740:30300a00;01:c0621fb0;#45"

If you are getting this output, you should be able to close the
terminal program and connect gdb using the same serial port. If you
are not getting this output, then there could be many things wrong.
Did you try passing the kgdb=halt argument to the kernel.

Vijay



More information about the Linuxppc-embedded mailing list