标准C的标记化结构初始化语法
1 struct file_operations {
2 struct module *owner;
3 loff_t (*llseek) (struct file *, loff_t, int);
4 ssize_t (*read) (struct file *, char __user *, size_t, loff_t *);
5 ssize_t (*write) (struct file *, const char __user *, size_t, loff_t *);
6 ssize_t (*aio_read) (struct kiocb *, const struct iovec *, unsigned long, loff_t);
7 ssize_t (*aio_write) (struct kiocb *, const struct iovec *, unsigned long, loff_t);
8 int (*readdir) (struct file *, void *, filldir_t);
9 unsigned int (*poll) (struct file *, struct poll_table_struct *);
10 int (*ioctl) (struct inode *, struct file *, unsigned int, unsigned long);
11 long (*unlocked_ioctl) (struct file *, unsigned int, unsigned long);
12 long (*compat_ioctl) (struct file *, unsigned int, unsigned long);
13 int (*mmap) (struct file *, struct vm_area_struct *);
14 int (*open) (struct inode *, struct file *);
15 int (*flush) (struct file *, fl_owner_t id);
16 int (*release) (struct inode *, struct file *);
17 int (*fsync) (struct file *, struct dentry *, int datasync);
18 int (*aio_fsync) (struct kiocb *, int datasync);
19 int (*fasync) (int, struct file *, int);
20 int (*lock) (struct file *, int, struct file_lock *);
21 ssize_t (*sendfile) (struct file *, loff_t *, size_t, read_actor_t, void *);
22 ssize_t (*sendpage) (struct file *, struct page *, int, size_t, loff_t *, int);
23 unsigned long (*get_unmapped_area)(struct file *, unsigned long, unsigned long, unsigned long, unsigned long);
24 int (*check_flags)(int);
25 int (*dir_notify)(struct file *filp, unsigned long arg);
26 int (*flock) (struct file *, int, struct file_lock *);
27 ssize_t (*splice_write)(struct pipe_inode_info *, struct file *, loff_t *, size_t, unsigned int);
28 ssize_t (*splice_read)(struct file *, loff_t *, struct pipe_inode_info *, size_t, unsigned int);
29 };
1 .open .write .owner };
允许对结构成员进行重新排列。
最新文章
- 无线连接Android设备
- Emacs学习心得之 基础操作
- URL重写案例
- android网络编程
- Asp.Net 母版页
- mac下导出kindle单词本的单词
- 201421123042 《Java程序设计》第10周学习总结
- Spring boot admin 节点状态一直为DOWN的排查
- SQL Server 2005 企业版没有 Microsoft SQL Server Management
- 不规范的json文档 转化成 java 对象的处理
- C借函数指针构造映射
- python-day37--协程
- 马尔可夫毯(Markov Blanket)
- memory management
- 安装android-sdk,gradle mac 篇
- C++ string 类
- ng-深度学习-课程笔记-16: 自然语言处理与词嵌入(Week2)
- Oracle数据库02
- 【BZOJ4654】【NOI2016】国王饮水记(动态规划,斜率优化)
- 为啥Android手机总会越用越慢?
热门文章
- 解决EFCore缓存机制导致的数据查询错误问题
- spring boot中不能识别RestController
- LeetCode 876. Middle of the Linked List(获得链表中心结点)
- 方法重载(Overload)
- 丰田开放混动专利后,真能PK赢纯电动汽车吗?
- 嵌入式编程中使用 do{...} while(0) 的解释
- redis 之redis-sentinel主从复制高可用
- JAVA培训—线程同步--卖票问题
- Numpy 广播(Broadcast)
- 吴裕雄 Bootstrap 前端框架开发——Bootstrap 辅助类:";text-success"; 类的文本样式