1 /*
2 * linux/fs/minix/file.c
3 *
4 * Copyright (C) 1991, 1992 Linus Torvalds
5 *
6 * minix regular file handling primitives
7 */
8
9 #include <linux/fs.h>
10 #include <linux/minix_fs.h>
11
12 /*
13 * We have mostly NULLs here: the current defaults are OK for
14 * the minix filesystem.
15 */
16 static int minix_sync_file(struct file *, struct dentry *, int);
17
18 struct file_operations minix_file_operations = {
19 read: generic_file_read,
20 write: generic_file_write,
21 mmap: generic_file_mmap,
22 fsync: minix_sync_file,
23 };
24
25 struct inode_operations minix_file_inode_operations = {
26 truncate: minix_truncate,
27 };
28
29 static int minix_sync_file(struct file * file,
30 struct dentry *dentry,
31 int datasync)
32 {
33 struct inode *inode = dentry->d_inode;
34
35 if (INODE_VERSION(inode) == MINIX_V1)
36 return V1_minix_sync_file(inode);
37 else
38 return V2_minix_sync_file(inode);
39 }
40
This page was automatically generated by the
LXR engine.
Visit the LXR main site for more
information.