编译驱动.ko模块时候报如下错误:
WARNING: "mxs_spi_setup" [/mnt/hgfs/share/work/lcmxo2-2000hc/cpld_lcmxo2-2000hc.ko] undefined!
WARNING: "mxs_spi_transfer" [/mnt/hgfs/share/work/lcmxo2-2000hc/cpld_lcmxo2-2000hc.ko] undefined!
CC /mnt/hgfs/share/work/lcmxo2-2000hc/cpld_lcmxo2-2000hc.mod.o
LD [M] /mnt/hgfs/share/work/lcmxo2-2000hc/cpld_lcmxo2-2000hc.ko
make[2]: warning: Clock skew detected. Your build may be incomplete.
make[1]: Leaving directory `/home/666/ltib/rpm/BUILD/linux-2.6.35.3'
解决办法:
出现这种情况是"mxs_spi_setup"和""mxs_spi_transfer"函数对应的符号没有EXPORT_SYMBOL或者没有在驱动模块源码中添加EXPORT_SYMBOL_GPL()导致的。
在 "mxs_spi_setup"和"mxs_spi_transfer"函数所在文件中添加EXPORT_SYMBOL(mxs_spi_setup);和EXPORT_SYMBOL(mxs_spi_transfer);
阅读(9566) | 评论(1) | 转发(0) |