“irq_to_desc” undefined?
来源:互联网 发布:安卓6.0java模拟器 编辑:程序博客网 时间:2024/05/13 12:24
自己在编写内核模块后,make时产生了一个这样的错误:Error: "irq_to_desc" [*.ko] undefined ! 在网上找了好久终于找到原因了。来自stackoverflow:
I don't believe you can use irq_to_desc()
in a module.
If CONFIG_GENERIC_HARDIRQS
isn't defined, then irq_to_desc()
is#defined
as a macro in include/linux/irqnr.h
. Since the variable it references,irq_desc
, isn't in an EXPORT_SYMBOL
or EXPORT_SYMBOL_GPL
declaration, I don't think you could link a module using that variable into the kernel -- only statically compiled in-kernel code can use it.
If CONFIG_GENERIC_HARDIRQS
is defined, then a function irq_to_desc()
is declared in include/linux/irqnr.h
and defined inkernel/irq/irqdesc.c
. There are two definitions of irq_to_desc()
inkernel/irq/irqdesc.c
depending upon the value of CONFIG_SPARSE_IRQ
. There is no correspondingEXPORT_SYMBOL
or EXPORT_SYMBOL_GPL
declaration for the function, so it can't be used in modules -- only statically compiled in-kernel code.
大意就是如果要在module中使用irq_to_desc()时,就必须把该模块编译进内核。
- “irq_to_desc” undefined?
- undefined
- undefined
- 比较undefined和“undefined”
- undefined与"undefined"
- undefined reference
- IP_RECVDSTADDR undefined
- Undefined symbol
- Undefined index
- Undefined symbols
- javascript undefined
- undefined index
- Undefined Behaviour
- js undefined
- undefined 类型
- undefined处理
- off_t undefined
- addRow1 undefined
- iOS上线流程
- Cstring 的赋值格式转换等
- NS2数据包结构解析
- Linux下高并发socket最大连接数
- 转载:Oracle从10g升级到11g详细步骤
- “irq_to_desc” undefined?
- C# 强引用与弱引用的区别
- JAVA_JDBC_DEMO
- 复制内容到剪贴板
- 双向bfs注意点
- Linux备份
- C++内存分析(一)
- NS2多接口跨层扩展库
- mvn命令