aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/fs.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux/fs.h')
-rw-r--r--include/linux/fs.h40
1 files changed, 16 insertions, 24 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 3b534e527e09..1ff5e4e01952 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -729,8 +729,8 @@ struct inode {
729 struct timespec i_atime; 729 struct timespec i_atime;
730 struct timespec i_mtime; 730 struct timespec i_mtime;
731 struct timespec i_ctime; 731 struct timespec i_ctime;
732 unsigned int i_blkbits;
733 blkcnt_t i_blocks; 732 blkcnt_t i_blocks;
733 unsigned int i_blkbits;
734 unsigned short i_bytes; 734 unsigned short i_bytes;
735 umode_t i_mode; 735 umode_t i_mode;
736 spinlock_t i_lock; /* i_blocks, i_bytes, maybe i_size */ 736 spinlock_t i_lock; /* i_blocks, i_bytes, maybe i_size */
@@ -751,13 +751,12 @@ struct inode {
751 struct block_device *i_bdev; 751 struct block_device *i_bdev;
752 struct cdev *i_cdev; 752 struct cdev *i_cdev;
753 }; 753 };
754 int i_cindex;
755 754
756 __u32 i_generation; 755 __u32 i_generation;
757 756
758#ifdef CONFIG_DNOTIFY 757#ifdef CONFIG_FSNOTIFY
759 unsigned long i_dnotify_mask; /* Directory notify events */ 758 __u32 i_fsnotify_mask; /* all events this inode cares about */
760 struct dnotify_struct *i_dnotify; /* for directory notifications */ 759 struct hlist_head i_fsnotify_mark_entries; /* fsnotify mark entries */
761#endif 760#endif
762 761
763#ifdef CONFIG_INOTIFY 762#ifdef CONFIG_INOTIFY
@@ -880,7 +879,7 @@ struct file_ra_state {
880 there are only # of pages ahead */ 879 there are only # of pages ahead */
881 880
882 unsigned int ra_pages; /* Maximum readahead window */ 881 unsigned int ra_pages; /* Maximum readahead window */
883 int mmap_miss; /* Cache miss stat for mmap accesses */ 882 unsigned int mmap_miss; /* Cache miss stat for mmap accesses */
884 loff_t prev_pos; /* Cache last read() position */ 883 loff_t prev_pos; /* Cache last read() position */
885}; 884};
886 885
@@ -1108,6 +1107,7 @@ extern void locks_copy_lock(struct file_lock *, struct file_lock *);
1108extern void __locks_copy_lock(struct file_lock *, const struct file_lock *); 1107extern void __locks_copy_lock(struct file_lock *, const struct file_lock *);
1109extern void locks_remove_posix(struct file *, fl_owner_t); 1108extern void locks_remove_posix(struct file *, fl_owner_t);
1110extern void locks_remove_flock(struct file *); 1109extern void locks_remove_flock(struct file *);
1110extern void locks_release_private(struct file_lock *);
1111extern void posix_test_lock(struct file *, struct file_lock *); 1111extern void posix_test_lock(struct file *, struct file_lock *);
1112extern int posix_lock_file(struct file *, struct file_lock *, struct file_lock *); 1112extern int posix_lock_file(struct file *, struct file_lock *, struct file_lock *);
1113extern int posix_lock_file_wait(struct file *, struct file_lock *); 1113extern int posix_lock_file_wait(struct file *, struct file_lock *);
@@ -1321,7 +1321,7 @@ struct super_block {
1321 struct rw_semaphore s_umount; 1321 struct rw_semaphore s_umount;
1322 struct mutex s_lock; 1322 struct mutex s_lock;
1323 int s_count; 1323 int s_count;
1324 int s_need_sync_fs; 1324 int s_need_sync;
1325 atomic_t s_active; 1325 atomic_t s_active;
1326#ifdef CONFIG_SECURITY 1326#ifdef CONFIG_SECURITY
1327 void *s_security; 1327 void *s_security;
@@ -1372,11 +1372,6 @@ struct super_block {
1372 * generic_show_options() 1372 * generic_show_options()
1373 */ 1373 */
1374 char *s_options; 1374 char *s_options;
1375
1376 /*
1377 * storage for asynchronous operations
1378 */
1379 struct list_head s_async_list;
1380}; 1375};
1381 1376
1382extern struct timespec current_fs_time(struct super_block *sb); 1377extern struct timespec current_fs_time(struct super_block *sb);
@@ -1800,7 +1795,7 @@ extern struct vfsmount *kern_mount_data(struct file_system_type *, void *data);
1800extern int may_umount_tree(struct vfsmount *); 1795extern int may_umount_tree(struct vfsmount *);
1801extern int may_umount(struct vfsmount *); 1796extern int may_umount(struct vfsmount *);
1802extern long do_mount(char *, char *, char *, unsigned long, void *); 1797extern long do_mount(char *, char *, char *, unsigned long, void *);
1803extern struct vfsmount *collect_mounts(struct vfsmount *, struct dentry *); 1798extern struct vfsmount *collect_mounts(struct path *);
1804extern void drop_collected_mounts(struct vfsmount *); 1799extern void drop_collected_mounts(struct vfsmount *);
1805 1800
1806extern int vfs_statfs(struct dentry *, struct kstatfs *); 1801extern int vfs_statfs(struct dentry *, struct kstatfs *);
@@ -1925,8 +1920,9 @@ extern void __init vfs_caches_init(unsigned long);
1925 1920
1926extern struct kmem_cache *names_cachep; 1921extern struct kmem_cache *names_cachep;
1927 1922
1928#define __getname() kmem_cache_alloc(names_cachep, GFP_KERNEL) 1923#define __getname_gfp(gfp) kmem_cache_alloc(names_cachep, (gfp))
1929#define __putname(name) kmem_cache_free(names_cachep, (void *)(name)) 1924#define __getname() __getname_gfp(GFP_KERNEL)
1925#define __putname(name) kmem_cache_free(names_cachep, (void *)(name))
1930#ifndef CONFIG_AUDITSYSCALL 1926#ifndef CONFIG_AUDITSYSCALL
1931#define putname(name) __putname(name) 1927#define putname(name) __putname(name)
1932#else 1928#else
@@ -1947,8 +1943,6 @@ extern struct super_block *freeze_bdev(struct block_device *);
1947extern void emergency_thaw_all(void); 1943extern void emergency_thaw_all(void);
1948extern int thaw_bdev(struct block_device *bdev, struct super_block *sb); 1944extern int thaw_bdev(struct block_device *bdev, struct super_block *sb);
1949extern int fsync_bdev(struct block_device *); 1945extern int fsync_bdev(struct block_device *);
1950extern int fsync_super(struct super_block *);
1951extern int fsync_no_super(struct block_device *);
1952#else 1946#else
1953static inline void bd_forget(struct inode *inode) {} 1947static inline void bd_forget(struct inode *inode) {}
1954static inline int sync_blockdev(struct block_device *bdev) { return 0; } 1948static inline int sync_blockdev(struct block_device *bdev) { return 0; }
@@ -1964,6 +1958,7 @@ static inline int thaw_bdev(struct block_device *bdev, struct super_block *sb)
1964 return 0; 1958 return 0;
1965} 1959}
1966#endif 1960#endif
1961extern int sync_filesystem(struct super_block *);
1967extern const struct file_operations def_blk_fops; 1962extern const struct file_operations def_blk_fops;
1968extern const struct file_operations def_chr_fops; 1963extern const struct file_operations def_chr_fops;
1969extern const struct file_operations bad_sock_fops; 1964extern const struct file_operations bad_sock_fops;
@@ -2043,9 +2038,6 @@ extern int __invalidate_device(struct block_device *);
2043extern int invalidate_partition(struct gendisk *, int); 2038extern int invalidate_partition(struct gendisk *, int);
2044#endif 2039#endif
2045extern int invalidate_inodes(struct super_block *); 2040extern int invalidate_inodes(struct super_block *);
2046unsigned long __invalidate_mapping_pages(struct address_space *mapping,
2047 pgoff_t start, pgoff_t end,
2048 bool be_atomic);
2049unsigned long invalidate_mapping_pages(struct address_space *mapping, 2041unsigned long invalidate_mapping_pages(struct address_space *mapping,
2050 pgoff_t start, pgoff_t end); 2042 pgoff_t start, pgoff_t end);
2051 2043
@@ -2082,12 +2074,8 @@ extern int filemap_fdatawrite_range(struct address_space *mapping,
2082 2074
2083extern int vfs_fsync(struct file *file, struct dentry *dentry, int datasync); 2075extern int vfs_fsync(struct file *file, struct dentry *dentry, int datasync);
2084extern void sync_supers(void); 2076extern void sync_supers(void);
2085extern void sync_filesystems(int wait);
2086extern void __fsync_super(struct super_block *sb);
2087extern void emergency_sync(void); 2077extern void emergency_sync(void);
2088extern void emergency_remount(void); 2078extern void emergency_remount(void);
2089extern int do_remount_sb(struct super_block *sb, int flags,
2090 void *data, int force);
2091#ifdef CONFIG_BLOCK 2079#ifdef CONFIG_BLOCK
2092extern sector_t bmap(struct inode *, sector_t); 2080extern sector_t bmap(struct inode *, sector_t);
2093#endif 2081#endif
@@ -2205,6 +2193,8 @@ extern int generic_segment_checks(const struct iovec *iov,
2205/* fs/splice.c */ 2193/* fs/splice.c */
2206extern ssize_t generic_file_splice_read(struct file *, loff_t *, 2194extern ssize_t generic_file_splice_read(struct file *, loff_t *,
2207 struct pipe_inode_info *, size_t, unsigned int); 2195 struct pipe_inode_info *, size_t, unsigned int);
2196extern ssize_t default_file_splice_read(struct file *, loff_t *,
2197 struct pipe_inode_info *, size_t, unsigned int);
2208extern ssize_t generic_file_splice_write(struct pipe_inode_info *, 2198extern ssize_t generic_file_splice_write(struct pipe_inode_info *,
2209 struct file *, loff_t *, size_t, unsigned int); 2199 struct file *, loff_t *, size_t, unsigned int);
2210extern ssize_t generic_splice_sendpage(struct pipe_inode_info *pipe, 2200extern ssize_t generic_splice_sendpage(struct pipe_inode_info *pipe,
@@ -2354,6 +2344,8 @@ extern void simple_release_fs(struct vfsmount **mount, int *count);
2354extern ssize_t simple_read_from_buffer(void __user *to, size_t count, 2344extern ssize_t simple_read_from_buffer(void __user *to, size_t count,
2355 loff_t *ppos, const void *from, size_t available); 2345 loff_t *ppos, const void *from, size_t available);
2356 2346
2347extern int simple_fsync(struct file *, struct dentry *, int);
2348
2357#ifdef CONFIG_MIGRATION 2349#ifdef CONFIG_MIGRATION
2358extern int buffer_migrate_page(struct address_space *, 2350extern int buffer_migrate_page(struct address_space *,
2359 struct page *, struct page *); 2351 struct page *, struct page *);