#include
此为控制台打出的信息
drivers/net/dm9000.c:93: error: expected declaration specifiers or '...' before string constant
drivers/net/dm9000.c:93: warning: data definition has no type or storage class
drivers/net/dm9000.c:93: warning: type defaults to 'int' in declaration of 'printk'
drivers/net/dm9000.c:93: warning: function declaration isn't a prototype
drivers/net/dm9000.c:93: error: conflicting types for 'printk'
drivers/net/dm9000.c:93: note: a parameter list with an ellipsis can't match an empty parameter name list declaration
include/linux/kernel.h:266: error: previous declaration of 'printk' was here
make[2]: *** [drivers/net/dm9000.o] 错误 1
make[1]: *** [drivers/net] 错误 2
make: *** [drivers] 错误 2
kernel.h里的问题行内容为
asmlinkage int printk(const char * fmt, ...)
__attribute__ ((format (printf, 1, 2))) __cold;
删除我在dm9000内添加的printk语句后编译正常
已经解决了问题
但是在控制台键入dmesg却无法打出printk中的信息