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.h29
1 files changed, 19 insertions, 10 deletions
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 73e9b643e455..a79f48373e7e 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -715,7 +715,7 @@ struct posix_acl;
715 715
716struct inode { 716struct inode {
717 struct hlist_node i_hash; 717 struct hlist_node i_hash;
718 struct list_head i_list; 718 struct list_head i_list; /* backing dev IO list */
719 struct list_head i_sb_list; 719 struct list_head i_sb_list;
720 struct list_head i_dentry; 720 struct list_head i_dentry;
721 unsigned long i_ino; 721 unsigned long i_ino;
@@ -1336,9 +1336,6 @@ struct super_block {
1336 struct xattr_handler **s_xattr; 1336 struct xattr_handler **s_xattr;
1337 1337
1338 struct list_head s_inodes; /* all inodes */ 1338 struct list_head s_inodes; /* all inodes */
1339 struct list_head s_dirty; /* dirty inodes */
1340 struct list_head s_io; /* parked for writeback */
1341 struct list_head s_more_io; /* parked for more writeback */
1342 struct hlist_head s_anon; /* anonymous dentries for (nfs) exporting */ 1339 struct hlist_head s_anon; /* anonymous dentries for (nfs) exporting */
1343 struct list_head s_files; 1340 struct list_head s_files;
1344 /* s_dentry_lru and s_nr_dentry_unused are protected by dcache_lock */ 1341 /* s_dentry_lru and s_nr_dentry_unused are protected by dcache_lock */
@@ -1528,6 +1525,7 @@ struct inode_operations {
1528 void (*put_link) (struct dentry *, struct nameidata *, void *); 1525 void (*put_link) (struct dentry *, struct nameidata *, void *);
1529 void (*truncate) (struct inode *); 1526 void (*truncate) (struct inode *);
1530 int (*permission) (struct inode *, int); 1527 int (*permission) (struct inode *, int);
1528 int (*check_acl)(struct inode *, int);
1531 int (*setattr) (struct dentry *, struct iattr *); 1529 int (*setattr) (struct dentry *, struct iattr *);
1532 int (*getattr) (struct vfsmount *mnt, struct dentry *, struct kstat *); 1530 int (*getattr) (struct vfsmount *mnt, struct dentry *, struct kstat *);
1533 int (*setxattr) (struct dentry *, const char *,const void *,size_t,int); 1531 int (*setxattr) (struct dentry *, const char *,const void *,size_t,int);
@@ -1788,6 +1786,7 @@ extern int get_sb_pseudo(struct file_system_type *, char *,
1788 struct vfsmount *mnt); 1786 struct vfsmount *mnt);
1789extern void simple_set_mnt(struct vfsmount *mnt, struct super_block *sb); 1787extern void simple_set_mnt(struct vfsmount *mnt, struct super_block *sb);
1790int __put_super_and_need_restart(struct super_block *sb); 1788int __put_super_and_need_restart(struct super_block *sb);
1789void put_super(struct super_block *sb);
1791 1790
1792/* Alas, no aliases. Too much hassle with bringing module.h everywhere */ 1791/* Alas, no aliases. Too much hassle with bringing module.h everywhere */
1793#define fops_get(fops) \ 1792#define fops_get(fops) \
@@ -1998,12 +1997,25 @@ extern void bd_release_from_disk(struct block_device *, struct gendisk *);
1998#define CHRDEV_MAJOR_HASH_SIZE 255 1997#define CHRDEV_MAJOR_HASH_SIZE 255
1999extern int alloc_chrdev_region(dev_t *, unsigned, unsigned, const char *); 1998extern int alloc_chrdev_region(dev_t *, unsigned, unsigned, const char *);
2000extern int register_chrdev_region(dev_t, unsigned, const char *); 1999extern int register_chrdev_region(dev_t, unsigned, const char *);
2001extern int register_chrdev(unsigned int, const char *, 2000extern int __register_chrdev(unsigned int major, unsigned int baseminor,
2002 const struct file_operations *); 2001 unsigned int count, const char *name,
2003extern void unregister_chrdev(unsigned int, const char *); 2002 const struct file_operations *fops);
2003extern void __unregister_chrdev(unsigned int major, unsigned int baseminor,
2004 unsigned int count, const char *name);
2004extern void unregister_chrdev_region(dev_t, unsigned); 2005extern void unregister_chrdev_region(dev_t, unsigned);
2005extern void chrdev_show(struct seq_file *,off_t); 2006extern void chrdev_show(struct seq_file *,off_t);
2006 2007
2008static inline int register_chrdev(unsigned int major, const char *name,
2009 const struct file_operations *fops)
2010{
2011 return __register_chrdev(major, 0, 256, name, fops);
2012}
2013
2014static inline void unregister_chrdev(unsigned int major, const char *name)
2015{
2016 __unregister_chrdev(major, 0, 256, name);
2017}
2018
2007/* fs/block_dev.c */ 2019/* fs/block_dev.c */
2008#define BDEVNAME_SIZE 32 /* Largest string for a blockdev identifier */ 2020#define BDEVNAME_SIZE 32 /* Largest string for a blockdev identifier */
2009#define BDEVT_SIZE 10 /* Largest string for MAJ:MIN for blkdev */ 2021#define BDEVT_SIZE 10 /* Largest string for MAJ:MIN for blkdev */
@@ -2070,8 +2082,6 @@ static inline void invalidate_remote_inode(struct inode *inode)
2070extern int invalidate_inode_pages2(struct address_space *mapping); 2082extern int invalidate_inode_pages2(struct address_space *mapping);
2071extern int invalidate_inode_pages2_range(struct address_space *mapping, 2083extern int invalidate_inode_pages2_range(struct address_space *mapping,
2072 pgoff_t start, pgoff_t end); 2084 pgoff_t start, pgoff_t end);
2073extern void generic_sync_sb_inodes(struct super_block *sb,
2074 struct writeback_control *wbc);
2075extern int write_inode_now(struct inode *, int); 2085extern int write_inode_now(struct inode *, int);
2076extern int filemap_fdatawrite(struct address_space *); 2086extern int filemap_fdatawrite(struct address_space *);
2077extern int filemap_flush(struct address_space *); 2087extern int filemap_flush(struct address_space *);
@@ -2186,7 +2196,6 @@ extern int bdev_read_only(struct block_device *);
2186extern int set_blocksize(struct block_device *, int); 2196extern int set_blocksize(struct block_device *, int);
2187extern int sb_set_blocksize(struct super_block *, int); 2197extern int sb_set_blocksize(struct super_block *, int);
2188extern int sb_min_blocksize(struct super_block *, int); 2198extern int sb_min_blocksize(struct super_block *, int);
2189extern int sb_has_dirty_inodes(struct super_block *);
2190 2199
2191extern int generic_file_mmap(struct file *, struct vm_area_struct *); 2200extern int generic_file_mmap(struct file *, struct vm_area_struct *);
2192extern int generic_file_readonly_mmap(struct file *, struct vm_area_struct *); 2201extern int generic_file_readonly_mmap(struct file *, struct vm_area_struct *);