调试篇一之动态调节
2016-01-27 11:22
211 查看
#define BIT(nr) (1UL << (nr))
enum print_reason {
PR_REGISTER = BIT(0),
PR_INTERRUPT = BIT(1),
PR_STATUS = BIT(2),
PR_DUMP = BIT(3),
PR_PM = BIT(4),
PR_MISC = BIT(5),
PR_WIPOWER = BIT(6),
};
staticint smbchg_debug_mask= 46;
module_param_named(
debug_mask, smbchg_debug_mask,int, S_IRUSR | S_IWUSR);
#define pr_smb(reason, fmt,...) \
do { \
if (smbchg_debug_mask& (reason)) \
pr_info(fmt, ##__VA_ARGS__); \
else \
pr_debug(fmt, ##__VA_ARGS__); \
} while (0)
pr_smb(PR_REGISTER, "addr =0x%x writing 0x%x\n", base, reg);
enum print_reason {
PR_REGISTER = BIT(0),
PR_INTERRUPT = BIT(1),
PR_STATUS = BIT(2),
PR_DUMP = BIT(3),
PR_PM = BIT(4),
PR_MISC = BIT(5),
PR_WIPOWER = BIT(6),
};
staticint smbchg_debug_mask= 46;
module_param_named(
debug_mask, smbchg_debug_mask,int, S_IRUSR | S_IWUSR);
#define pr_smb(reason, fmt,...) \
do { \
if (smbchg_debug_mask& (reason)) \
pr_info(fmt, ##__VA_ARGS__); \
else \
pr_debug(fmt, ##__VA_ARGS__); \
} while (0)
pr_smb(PR_REGISTER, "addr =0x%x writing 0x%x\n", base, reg);
相关文章推荐
- 使用scala,java实现使用phenix读取hbase中数据
- 深入了解MyBatis返回值
- Hive-2.HiveQL查询中常用函数
- 无法下载图片 App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insec
- 一个枚举的简单例子
- mysql5.6全量备份
- 图片裁剪的使用——拼图游戏
- 《锋利的JQuery》读书笔记(二)
- js和jQuery实现获取id和点击checkbox全选功能
- Hibernate查出集合里面的对象全部为空原因分析
- 【C#】常用的一些特性
- hdoj 1846 Brave Game【巴什博弈】
- 几个重要库函数的实现
- 共用体的作用
- 使用SecureCRT远程登陆Linux服务器时无法正确显示中文
- iOS开发-基础:keychain的使用
- LeetCode 58 Length of Last Word(最后单词的长度)
- asp.net MVC之创建自定义路由约束
- 修改Python文件日志输出位置
- <frame>框架要点