insmod: Unknown symbol in module or no symbol version for
2010-11-08 21:48
477 查看
搞了半天原来是Makefile的问题
vdisk.c中
vhdd.c中
一开始分别使用Makefile生成的就出错了
dmesg结果
![](http://hi.csdn.net/attachment/201011/8/0_12892246477jfD.gif)
正确的Makefile:
export-objs是关键
vdisk.c中
char * vdisk[VHDD_MAX_DEVICE]={NULL,}; EXPORT_SYMBOL(vdisk);
vhdd.c中
extern char *vdisk[VHDD_MAX_DEVICE];
一开始分别使用Makefile生成的就出错了
dmesg结果
![](http://hi.csdn.net/attachment/201011/8/0_12892246477jfD.gif)
正确的Makefile:
obj-m :=vhdd.o export-objs :=vdisk.o KDIR :=/lib/modules/$(shell uname -r)/build PWD :=$(shell pwd) default: $(MAKE) -C $(KDIR) SUBDIRS=$(PWD) modules clean: rm -rf *.ko rm -rf *.mod.* rm -rf .*.cmd rm -rf *.o
export-objs是关键
相关文章推荐
- 往开发板写led驱动时出现错误:insmod: can't insert 's3c_led.ko': unknown symbol in module or invalid parameter
- insmod: no symbol version for module_layout
- 安装Dahdi模块出现insmod: can't insert 'dahdi.ko': unknown symbol in module or invalid parameter
- insmod: error inserting './scull.ko': -1 Unknown symbol in module
- linux驱动模块加载出错insmod: error inserting './usb_driver.ko': -1 Unknown symbol in module
- insmod: error inserting 'sequans_usb.ko': -1 Unknown symbol in module
- "no symbol version for module_layout“
- 解决FATAL: Error inserting ip_vs ... Unknown symbol in module, or unknown parameter
- kvm 模块加载时报错:insmod: error inserting 'kvm.ko': -1 Unknown symbol in module
- arm上加载insmod驱动时出现Unknown symbol in module
- insmod: error inserting './igb.ko': -1 Unknown symbol in module 的问题所在
- no symbol version for module_layout 解决办法
- insmod: error inserting 'myvivi.ko': -1 Unknown symbol in module 问题解决办法
- no symbol version for module_layout 解决方法
- insmod: error inserting 'vivid.ko': -1 Unknown symbol in module
- insmod: error inserting './sctp.ko': -1 Unknown symbol in module
- no symbol version for module_layout
- 导出内核符号 EXPORT_SYMBOL insmod: error inserting 'mod2.ko': -1 Unknown symbol in module
- insmod: error inserting './igb.ko': -1 Unknown symbol in module 的问题所在
- Maven报错 解决方案。ERROR: No goals have been specified for this build. You must specify a valid lifecycle phase or a goal in the format <plugin-prefix>:<goal> or <plugin-group-id>:<plugin-artifact-id