Debug Android kernel with KGDB

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Debug Android kernel with KGDB

1,154 Views
leonardoprates
Contributor III

I'm trying debug an Android kernel freeze with KGDB. Apparently I can connect to the target and 'c' command to continue kernel execution works. But after that if I try put some break point, for example, I get answer similar to that: 

(gdb) b goodix_i2c_write
Reply contains invalid hex digit 109

I'm calling gdb in this way: 

./arm-linux-androideabi-gdb ../../../../../../kernel_imx/vmlinux

And at start configs is:

GNU gdb (GDB) 7.7
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "--host=x86_64-linux-gnu --target=arm-linux-android".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://source.android.com/source/report-bugs.html>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ../../../../../../kernel_imx/vmlinux...done.
(gdb) target remote localhost:5551
Remote debugging using localhost:5551

What's wrong?

Is my first experience with GDB. Is there a way to show exactly the last line before kernel freeze?

Thanks,

Leonardo

Labels (3)
0 Kudos
1 Reply

694 Views
leonardoprates
Contributor III

Just for reference, I use Android 6.0.1 from NXP and before Android starts I can put breakpoints, just after Android starts breakpoint doesnt work anymore with messages "Reply contains invalid hex digit". Is this Android secure conflicts?

0 Kudos