应用调试-----配置内核输出应用程序的段错误信息
__do_user_fault(struct task_struct *tsk, unsigned long addr,
{
#ifdef CONFIG_DEBUG_USER
#endif
2. uboot: set bootargs user_debug=0xff
set bootargs console=ttySAC0 root=/dev/nfs nfsroot=192.168.1.123:/work/nfs_root/first_fs ip=192.168.1.17 ipaddr=192.168.1.17 user_debug=0xff
3. 执行APP
./test_debug
a = 0x12
pgd = c04c8000
[00000000] *pgd=33d08031, *pte=00000000, *ppte=00000000
Pid: 772, comm:
CPU: 0
PC is at 0x84ac
LR is at 0x84d0
pc : [<000084ac>]
sp : bed9fe40
r10: 4013365c
r7 : 00000001
r3 : 00000012
Flags: nZCv
Control: c000717f
[] (show_regs+0x0/0x4c) from [] (__do_user_fault+0x5c/0xa4)
[] (__do_user_fault+0x0/0xa4) from [] (do_page_fault+0x1dc/0x20c)
[] (do_page_fault+0x0/0x20c) from [] (do_DataAbort+0x3c/0xa0)
[] (do_DataAbort+0x0/0xa0) from [] (ret_from_exception+0x0/0x10)
Exception stack(0xc3e7bfb0 to 0xc3e7bff8)
bfa0:
bfc0: bed9fec4 00008568 000085cc 00000001 00008514 00000000 4013365c bed9fe50
bfe0: bed9fe54 bed9fe40 000084d0 000084ac 60000010 ffffffff
Segmentation fault
Stack:
00000000 becd3e64 becd3e54 000084d0 000084a0 00000000 becd3e78 becd3e68
Cs sp
000084f0 000084c4 00000000 becd3e98 becd3e7c 00008554 000084e4 00000000
ret addr
00000012 becd3ec4 00000001 00000000 becd3e9c 40034f14 00008524 00000000
00000000 0000839c 00000000 00000000 4001d594 000083c4 000085cc 4000c02c
becd3ec4 becd3f7b 00000000 becd3f88 becd3f92 becd3f99 becd3fad becd3fb8
becd3fdb becd3fe9 00000000 00000010 00000003 00000006 00001000 00000011
00000064 00000003 00008034 00000004 00000020 00000005 00000006 00000007
40000000 00000008 00000000 00000009 0000839c 0000000b 00000000 0000000c
00000000 0000000d 00000000 0000000e 00000000 00000017 00000000 0000000f
becd3f77 00000000 00000000 00000000 00000000 76000000 2e006c34 7365742f
65645f74 00677562 52455355 6f6f723d 4f480074 2f3d454d 61706900 3d726464
2e323931 2e383631 37312e31 52455400 74763d4d 00323031 48544150 62732f3d
2f3a6e69 2f727375 6e696273 69622f3a 752f3a6e 622f7273 53006e69 4c4c4548
69622f3d 68732f6e 44575000 2e002f3d 7365742f 65645f74 00677562 00000000
4. 反汇编app:
arm-linux-objdump -D test_debug > test_debug.dis
对于静态链接的test_debug
arm-linux-gcc -o
PC is at 0x81e0
LR is at 0x8204
pc : [<000081e0>]
sp : be93dc60
r10: 000085f4
r7 : 00000001
r3 : 00000012
Flags: nZCv
Stack:
00000000 be93dc84 be93dc74 00008204 000081d4 00000000 be93dc98 be93dc88
Csp
00008224 000081f8 00000000 be93dcb8 be93dc9c 00008288 00008218 00000000
ret addr
应用调试内核输出段错误信 相关文章:
- Windows CE 进程、线程和内存管理(11-09)
- RedHatLinux新手入门教程(5)(11-12)
- uClinux介绍(11-09)
- openwebmailV1.60安装教学(11-12)
- Linux嵌入式系统开发平台选型探讨(11-09)
- Windows CE 进程、线程和内存管理(二)(11-09)