[LEDE-DEV] How to build kernel module with debugging symbols?

Ben Greear greearb at candelatech.com
Thu Jul 28 15:09:10 PDT 2016


I am trying to debug a crash in my ath10k-ct kernel driver.
I can only reproduce this on LEDE, so my normal debug tricks are not working.

How can I get LEDE to build the module with symbols so that LEDE's gdb can open it?

I verified that '-g' is being passed when compiling the module, and it does not appear
to be stripped, but symbols are not found:

file /home/greearb/git/lede-linksys/build_dir/target-arm_cortex-a15+neon-vfpv4_musl-1.1.15_eabi/linux-ipq806x/ath10k-ct-2016-07-21/ath10k/ath10k_core.ko
/home/greearb/git/lede-linksys/build_dir/target-arm_cortex-a15+neon-vfpv4_musl-1.1.15_eabi/linux-ipq806x/ath10k-ct-2016-07-21/ath10k/ath10k_core.ko: ELF 32-bit 
LSB relocatable, ARM, EABI5 version 1 (SYSV), BuildID[sha1]=1e15f0ff10a3d64ab36e7bcf1e4a7f8121581c3b, not stripped


./build_dir/toolchain-arm_cortex-a15+neon-vfpv4_gcc-5.4.0_musl-1.1.15_eabi/gdb-7.11.1/gdb/gdb 
/home/greearb/git/lede-linksys/build_dir/target-arm_cortex-a15+neon-vfpv4_musl-1.1.15_eabi/linux-ipq806x/ath10k-ct-2016-07-21/ath10k/ath10k_core.ko
GNU gdb (GDB) 7.11.1
Copyright (C) 2016 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-redhat-linux --target=arm-openwrt-linux-muslgnueabi".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
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 
/home/greearb/git/lede-linksys/build_dir/target-arm_cortex-a15+neon-vfpv4_musl-1.1.15_eabi/linux-ipq806x/ath10k-ct-2016-07-21/ath10k/ath10k_core.ko...(no 
debugging symbols found)...done.

??

Thanks,
Ben

-- 
Ben Greear <greearb at candelatech.com>
Candela Technologies Inc  http://www.candelatech.com




More information about the Lede-dev mailing list