Re: kgdb do not stop in my module ( does not see functions from mymodule.ko)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Mulyadi Santosa wrote:
On Wed, Feb 18, 2009 at 1:36 AM, Lev Olshvang <levo@xxxxxxxxxxxx> wrote:
  
Hello List,

I am trying to debug my module using kgdb

After some retires I made a working host -target serial connection

I use Ubuntu 7.10 as host, and Kernel 2.6.26 on target.

The target indeed stops in boot waits for the gdb to set up  breakpoints,
 ....

So I used  set solib-path-search  command in gdb to set up my driver
location and set a breakpoint within my driver.
Gdb warned me that currently this symbol is not visible and will become
visible on library load.

Ok , I entered   gdb> cont command, the target computer succesfully booted.

Then I load my module on target  hoping that gdb will hit a breakpoint
because the functions I asked to stop in  are inside module initialization
code - but nothing happened.

What do I miss here ?
    

There's a chance that the breakpoint address you have set is no longer
correct since symbol relocation happens during module insertion.

For example:

# cat /sys/module/ip_tables/sections/.init.text
0xe00fe000

# nm ip_tables.ko | grep  init
0000000f T init_module

What do you think?

regards,

Mulyadi.
  
Since I use function name, the gdb will resolve it ti address on module load event


gdb >b MRouterBindAdapter
gdb>_   Function "MRouterBindAdapter" not defined.
gdb > Make breakpoint pending on future shared library load? (y or [n]) y



I have set 2 pparamers for shared lib
set solib-prefix /dev/null
set solib-search-path  /home/2.6.26/

I think I miss somthing on how to setup solib-search-path, or some connected to shared library load parameters


Regards,
Lev

PS

BTW, I do not see my post in web archive at  -http://mail.nl.linux.org/kernelnewbies/2009-02  ???


-- To unsubscribe from this list: send an email with "unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx Please read the FAQ at http://kernelnewbies.org/FAQ

[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux