kgdb shows No source available

42 Views Asked by At

I am debugging a kernel module with kgdb.With kgdb I am able to hit the breakpoints on the required function but the tui interface shows

No source available.

Also putting breakpoints on particular line number does not works. When i am trying to put breakpoints on particular line number following message is displayed on gdb interface. "No line N in <file_name>.c"

Attached is the image.enter image description here

  1. I tried putting breakpoints on particular line number in file. Used the following command.

    (gdb)break <file_name>.c:line_number

    (gdb)No line <line_number> in file "<file_name>.c".

    (gdb)Make breakpoint pending on future shared library load? (y or [n]) `

`2) I tried putting breakpoint on particular function. Used following command.

(gdb)break <function_name>

result: breakpoint hits but KGDB tui interface shows No source available

1

There are 1 best solutions below

0
vka On

I upgraded ubuntu from 18.04 to 20.04 and now i am able to hit the breakpoints with source code available in tui interface. Not sure,Looks like there was some issue with 18.04 release.