diff options
author | Glenn Elliott <gelliott@cs.unc.edu> | 2012-03-04 19:47:13 -0500 |
---|---|---|
committer | Glenn Elliott <gelliott@cs.unc.edu> | 2012-03-04 19:47:13 -0500 |
commit | c71c03bda1e86c9d5198c5d83f712e695c4f2a1e (patch) | |
tree | ecb166cb3e2b7e2adb3b5e292245fefd23381ac8 /fs/gfs2/inode.h | |
parent | ea53c912f8a86a8567697115b6a0d8152beee5c8 (diff) | |
parent | 6a00f206debf8a5c8899055726ad127dbeeed098 (diff) |
Merge branch 'mpi-master' into wip-k-fmlpwip-k-fmlp
Conflicts:
litmus/sched_cedf.c
Diffstat (limited to 'fs/gfs2/inode.h')
-rw-r--r-- | fs/gfs2/inode.h | 33 |
1 files changed, 22 insertions, 11 deletions
diff --git a/fs/gfs2/inode.h b/fs/gfs2/inode.h index 300ada3f21de..31606076f701 100644 --- a/fs/gfs2/inode.h +++ b/fs/gfs2/inode.h | |||
@@ -19,6 +19,8 @@ extern int gfs2_releasepage(struct page *page, gfp_t gfp_mask); | |||
19 | extern int gfs2_internal_read(struct gfs2_inode *ip, | 19 | extern int gfs2_internal_read(struct gfs2_inode *ip, |
20 | struct file_ra_state *ra_state, | 20 | struct file_ra_state *ra_state, |
21 | char *buf, loff_t *pos, unsigned size); | 21 | char *buf, loff_t *pos, unsigned size); |
22 | extern void gfs2_page_add_databufs(struct gfs2_inode *ip, struct page *page, | ||
23 | unsigned int from, unsigned int to); | ||
22 | extern void gfs2_set_aops(struct inode *inode); | 24 | extern void gfs2_set_aops(struct inode *inode); |
23 | 25 | ||
24 | static inline int gfs2_is_stuffed(const struct gfs2_inode *ip) | 26 | static inline int gfs2_is_stuffed(const struct gfs2_inode *ip) |
@@ -80,27 +82,36 @@ static inline void gfs2_inum_out(const struct gfs2_inode *ip, | |||
80 | dent->de_inum.no_addr = cpu_to_be64(ip->i_no_addr); | 82 | dent->de_inum.no_addr = cpu_to_be64(ip->i_no_addr); |
81 | } | 83 | } |
82 | 84 | ||
85 | static inline int gfs2_check_internal_file_size(struct inode *inode, | ||
86 | u64 minsize, u64 maxsize) | ||
87 | { | ||
88 | u64 size = i_size_read(inode); | ||
89 | if (size < minsize || size > maxsize) | ||
90 | goto err; | ||
91 | if (size & ((1 << inode->i_blkbits) - 1)) | ||
92 | goto err; | ||
93 | return 0; | ||
94 | err: | ||
95 | gfs2_consist_inode(GFS2_I(inode)); | ||
96 | return -EIO; | ||
97 | } | ||
83 | 98 | ||
84 | extern void gfs2_set_iop(struct inode *inode); | ||
85 | extern struct inode *gfs2_inode_lookup(struct super_block *sb, unsigned type, | 99 | extern struct inode *gfs2_inode_lookup(struct super_block *sb, unsigned type, |
86 | u64 no_addr, u64 no_formal_ino); | 100 | u64 no_addr, u64 no_formal_ino, |
87 | extern void gfs2_process_unlinked_inode(struct super_block *sb, u64 no_addr); | 101 | int non_block); |
88 | extern struct inode *gfs2_ilookup(struct super_block *sb, u64 no_addr); | 102 | extern struct inode *gfs2_lookup_by_inum(struct gfs2_sbd *sdp, u64 no_addr, |
103 | u64 *no_formal_ino, | ||
104 | unsigned int blktype); | ||
105 | extern struct inode *gfs2_ilookup(struct super_block *sb, u64 no_addr, int nonblock); | ||
89 | 106 | ||
90 | extern int gfs2_inode_refresh(struct gfs2_inode *ip); | 107 | extern int gfs2_inode_refresh(struct gfs2_inode *ip); |
91 | 108 | ||
92 | extern int gfs2_dinode_dealloc(struct gfs2_inode *inode); | ||
93 | extern int gfs2_change_nlink(struct gfs2_inode *ip, int diff); | ||
94 | extern struct inode *gfs2_lookupi(struct inode *dir, const struct qstr *name, | 109 | extern struct inode *gfs2_lookupi(struct inode *dir, const struct qstr *name, |
95 | int is_root); | 110 | int is_root); |
96 | extern struct inode *gfs2_createi(struct gfs2_holder *ghs, | 111 | extern int gfs2_permission(struct inode *inode, int mask, unsigned int flags); |
97 | const struct qstr *name, | ||
98 | unsigned int mode, dev_t dev); | ||
99 | extern int gfs2_permission(struct inode *inode, int mask); | ||
100 | extern int gfs2_setattr_simple(struct gfs2_inode *ip, struct iattr *attr); | 112 | extern int gfs2_setattr_simple(struct gfs2_inode *ip, struct iattr *attr); |
101 | extern struct inode *gfs2_lookup_simple(struct inode *dip, const char *name); | 113 | extern struct inode *gfs2_lookup_simple(struct inode *dip, const char *name); |
102 | extern void gfs2_dinode_out(const struct gfs2_inode *ip, void *buf); | 114 | extern void gfs2_dinode_out(const struct gfs2_inode *ip, void *buf); |
103 | extern void gfs2_dinode_print(const struct gfs2_inode *ip); | ||
104 | 115 | ||
105 | extern const struct inode_operations gfs2_file_iops; | 116 | extern const struct inode_operations gfs2_file_iops; |
106 | extern const struct inode_operations gfs2_dir_iops; | 117 | extern const struct inode_operations gfs2_dir_iops; |