标签:style blog http color 使用 io 2014 ar
error message:
原因: 从2.6.36开始,file_operations结构发生了重大变化
具体看 xx../include/linux/fs.h定义:
取消了原先的
int (*ioctl)(struct inode*, struct file*, unsigned int, unsigned long);
添加来新的成员
long (*unlocked_ioctl) (struct file *, unsigned int, unsigned long);原来的ioctl 但是返回值变为long
long (*compat_ioctl) (struct file *, unsigned int, unsigned long);内核空间64位,用户空间32位
所以:
1,取消inode:
2,使用unlocked_ioctl
OK.
error: unknown field 'ioctl' specified in initializer,布布扣,bubuko.com
error: unknown field 'ioctl' specified in initializer
标签:style blog http color 使用 io 2014 ar
原文地址:http://www.cnblogs.com/skynext/p/3880682.html