diff options
Diffstat (limited to 'Documentation/filesystems/vfs.txt')
-rw-r--r-- | Documentation/filesystems/vfs.txt | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/Documentation/filesystems/vfs.txt b/Documentation/filesystems/vfs.txt index 0d0492028082..efd23f481704 100644 --- a/Documentation/filesystems/vfs.txt +++ b/Documentation/filesystems/vfs.txt | |||
@@ -363,7 +363,7 @@ struct inode_operations { | |||
363 | ssize_t (*getxattr) (struct dentry *, const char *, void *, size_t); | 363 | ssize_t (*getxattr) (struct dentry *, const char *, void *, size_t); |
364 | ssize_t (*listxattr) (struct dentry *, char *, size_t); | 364 | ssize_t (*listxattr) (struct dentry *, char *, size_t); |
365 | int (*removexattr) (struct dentry *, const char *); | 365 | int (*removexattr) (struct dentry *, const char *); |
366 | void (*truncate_range)(struct inode *, loff_t, loff_t); | 366 | void (*update_time)(struct inode *, struct timespec *, int); |
367 | }; | 367 | }; |
368 | 368 | ||
369 | Again, all methods are called without any locks being held, unless | 369 | Again, all methods are called without any locks being held, unless |
@@ -472,9 +472,9 @@ otherwise noted. | |||
472 | removexattr: called by the VFS to remove an extended attribute from | 472 | removexattr: called by the VFS to remove an extended attribute from |
473 | a file. This method is called by removexattr(2) system call. | 473 | a file. This method is called by removexattr(2) system call. |
474 | 474 | ||
475 | truncate_range: a method provided by the underlying filesystem to truncate a | 475 | update_time: called by the VFS to update a specific time or the i_version of |
476 | range of blocks , i.e. punch a hole somewhere in a file. | 476 | an inode. If this is not defined the VFS will update the inode itself |
477 | 477 | and call mark_inode_dirty_sync. | |
478 | 478 | ||
479 | The Address Space Object | 479 | The Address Space Object |
480 | ======================== | 480 | ======================== |
@@ -760,7 +760,7 @@ struct file_operations | |||
760 | ---------------------- | 760 | ---------------------- |
761 | 761 | ||
762 | This describes how the VFS can manipulate an open file. As of kernel | 762 | This describes how the VFS can manipulate an open file. As of kernel |
763 | 2.6.22, the following members are defined: | 763 | 3.5, the following members are defined: |
764 | 764 | ||
765 | struct file_operations { | 765 | struct file_operations { |
766 | struct module *owner; | 766 | struct module *owner; |
@@ -790,6 +790,8 @@ struct file_operations { | |||
790 | int (*flock) (struct file *, int, struct file_lock *); | 790 | int (*flock) (struct file *, int, struct file_lock *); |
791 | ssize_t (*splice_write)(struct pipe_inode_info *, struct file *, size_t, unsigned int); | 791 | ssize_t (*splice_write)(struct pipe_inode_info *, struct file *, size_t, unsigned int); |
792 | ssize_t (*splice_read)(struct file *, struct pipe_inode_info *, size_t, unsigned int); | 792 | ssize_t (*splice_read)(struct file *, struct pipe_inode_info *, size_t, unsigned int); |
793 | int (*setlease)(struct file *, long arg, struct file_lock **); | ||
794 | long (*fallocate)(struct file *, int mode, loff_t offset, loff_t len); | ||
793 | }; | 795 | }; |
794 | 796 | ||
795 | Again, all methods are called without any locks being held, unless | 797 | Again, all methods are called without any locks being held, unless |
@@ -858,6 +860,11 @@ otherwise noted. | |||
858 | splice_read: called by the VFS to splice data from file to a pipe. This | 860 | splice_read: called by the VFS to splice data from file to a pipe. This |
859 | method is used by the splice(2) system call | 861 | method is used by the splice(2) system call |
860 | 862 | ||
863 | setlease: called by the VFS to set or release a file lock lease. | ||
864 | setlease has the file_lock_lock held and must not sleep. | ||
865 | |||
866 | fallocate: called by the VFS to preallocate blocks or punch a hole. | ||
867 | |||
861 | Note that the file operations are implemented by the specific | 868 | Note that the file operations are implemented by the specific |
862 | filesystem in which the inode resides. When opening a device node | 869 | filesystem in which the inode resides. When opening a device node |
863 | (character or block special) most filesystems will call special | 870 | (character or block special) most filesystems will call special |