首页 > 系统服务 > 详细

linux kernel driver debug

时间:2019-02-15 14:01:17      阅读:378      评论:0      收藏:0      [点我收藏+]

1. print 

printk(): never

pr_debug(): always good

dev_dbg(): prefered when you have a struct device object

netdev_dbg(): prefered when you have a struct netdevice object

[something]_dbg(): prefered when you have a that something object

2. using file system proc/ memory large file or sequence file

 

3. using Ioctrl to get/set specific data

 

Below shall enable the kernel debug.

4. gdb list command to idenfiy the line of oops

5. addr2line command to identify the line of oops

 

linux kernel driver debug

原文:https://www.cnblogs.com/zjbfvfv/p/10383201.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!