Skip to content

Load symbols for kernel module to allow natural debugging by symbol names  #137

@usiegj00

Description

@usiegj00

Currently, a debugging session starts with symbols unmapped to addresses. This limits ease of debugging and operations like b some_func are not available.

Typically, this is solved by finding the symbol offsets from an active kernel module and then loading a symbol file like:

# On debugee:
cat /sys/module/the_mod/sections/.text
cat /sys/module/the_mod/sections/.data
cat /sys/module/the_mod/sections/.bss
# On debuger:
add-symbol-file the_mod.ko 0xffffffff... -s .data 0xffffffff... -s .bss 0xffffffff...

Or alternatively using /proc/kallsyms.

A workaround could be made if #71 were available because a kernel module could be easily uploaded and the rest orchestrated.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions