Slide 27
Slide 27 text
27
●
struct file_operations {
struct module *owner;
(*read) (struct file *, char __user *, size_t,
loff_t *);
(*write) (struct file *, const char __user *,
size_t, loff_t *);
(*poll) (struct file *, struct poll_table_struct
*);
(*ioctl) (struct inode *, struct file *, unsigned
int, unsigned long);
(*mmap) (struct file *, struct vm_area_struct *);
(*open) (struct inode *, struct file *);
(*release) (struct inode *, struct file *);
};
提供系統呼叫介面