Commit f2f7ba5237e2fe10ba3e328a4f728b9e1ff141da
1 parent
2bdbc5d739
Exists in
master
and in
4 other branches
[GFS2] Make headers compile on their own
As per Jan Engelhardt's comments, this should make all the headers compile on their own by including and/or declaring structures early. Cc: Jan Engelhardt <jengelh@linux01.gwdg.de> Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
Showing 27 changed files with 77 additions and 2 deletions Side-by-side Diff
- fs/gfs2/acl.h
- fs/gfs2/bmap.h
- fs/gfs2/dir.h
- fs/gfs2/eaops.h
- fs/gfs2/eattr.h
- fs/gfs2/glock.h
- fs/gfs2/glops.h
- fs/gfs2/incore.h
- fs/gfs2/lm.h
- fs/gfs2/log.h
- fs/gfs2/lops.h
- fs/gfs2/meta_io.h
- fs/gfs2/mount.h
- fs/gfs2/ops_address.h
- fs/gfs2/ops_dentry.h
- fs/gfs2/ops_file.h
- fs/gfs2/ops_fstype.h
- fs/gfs2/ops_inode.h
- fs/gfs2/ops_super.h
- fs/gfs2/ops_vm.h
- fs/gfs2/quota.h
- fs/gfs2/recovery.h
- fs/gfs2/rgrp.h
- fs/gfs2/super.h
- fs/gfs2/sys.h
- fs/gfs2/trans.h
- fs/gfs2/util.h
fs/gfs2/acl.h
fs/gfs2/bmap.h
... | ... | @@ -10,6 +10,10 @@ |
10 | 10 | #ifndef __BMAP_DOT_H__ |
11 | 11 | #define __BMAP_DOT_H__ |
12 | 12 | |
13 | +struct inode; | |
14 | +struct gfs2_inode; | |
15 | +struct page; | |
16 | + | |
13 | 17 | int gfs2_unstuff_dinode(struct gfs2_inode *ip, struct page *page); |
14 | 18 | int gfs2_block_map(struct inode *inode, u64 lblock, int *new, u64 *dblock, int *boundary); |
15 | 19 | int gfs2_extent_map(struct inode *inode, u64 lblock, int *new, u64 *dblock, unsigned *extlen); |
fs/gfs2/dir.h
... | ... | @@ -10,6 +10,12 @@ |
10 | 10 | #ifndef __DIR_DOT_H__ |
11 | 11 | #define __DIR_DOT_H__ |
12 | 12 | |
13 | +#include <linux/dcache.h> | |
14 | + | |
15 | +struct inode; | |
16 | +struct gfs2_inode; | |
17 | +struct gfs2_inum; | |
18 | + | |
13 | 19 | /** |
14 | 20 | * gfs2_filldir_t - Report a directory entry to the caller of gfs2_dir_read() |
15 | 21 | * @opaque: opaque data used by the function |
fs/gfs2/eaops.h
fs/gfs2/eattr.h
fs/gfs2/glock.h
fs/gfs2/glops.h
... | ... | @@ -10,6 +10,8 @@ |
10 | 10 | #ifndef __GLOPS_DOT_H__ |
11 | 11 | #define __GLOPS_DOT_H__ |
12 | 12 | |
13 | +#include "incore.h" | |
14 | + | |
13 | 15 | extern const struct gfs2_glock_operations gfs2_meta_glops; |
14 | 16 | extern const struct gfs2_glock_operations gfs2_inode_glops; |
15 | 17 | extern const struct gfs2_glock_operations gfs2_rgrp_glops; |
fs/gfs2/incore.h
fs/gfs2/lm.h
fs/gfs2/log.h
fs/gfs2/lops.h
... | ... | @@ -10,6 +10,9 @@ |
10 | 10 | #ifndef __LOPS_DOT_H__ |
11 | 11 | #define __LOPS_DOT_H__ |
12 | 12 | |
13 | +#include <linux/list.h> | |
14 | +#include "incore.h" | |
15 | + | |
13 | 16 | extern const struct gfs2_log_operations gfs2_glock_lops; |
14 | 17 | extern const struct gfs2_log_operations gfs2_buf_lops; |
15 | 18 | extern const struct gfs2_log_operations gfs2_revoke_lops; |
fs/gfs2/meta_io.h
fs/gfs2/mount.h
fs/gfs2/ops_address.h
... | ... | @@ -10,6 +10,10 @@ |
10 | 10 | #ifndef __OPS_ADDRESS_DOT_H__ |
11 | 11 | #define __OPS_ADDRESS_DOT_H__ |
12 | 12 | |
13 | +#include <linux/fs.h> | |
14 | +#include <linux/buffer_head.h> | |
15 | +#include <linux/mm.h> | |
16 | + | |
13 | 17 | extern const struct address_space_operations gfs2_file_aops; |
14 | 18 | extern int gfs2_get_block(struct inode *inode, sector_t lblock, |
15 | 19 | struct buffer_head *bh_result, int create); |
fs/gfs2/ops_dentry.h
fs/gfs2/ops_file.h
... | ... | @@ -9,6 +9,10 @@ |
9 | 9 | |
10 | 10 | #ifndef __OPS_FILE_DOT_H__ |
11 | 11 | #define __OPS_FILE_DOT_H__ |
12 | + | |
13 | +#include <linux/fs.h> | |
14 | +struct gfs2_inode; | |
15 | + | |
12 | 16 | extern struct file gfs2_internal_file_sentinel; |
13 | 17 | extern int gfs2_internal_read(struct gfs2_inode *ip, |
14 | 18 | struct file_ra_state *ra_state, |
fs/gfs2/ops_fstype.h
fs/gfs2/ops_inode.h
fs/gfs2/ops_super.h
fs/gfs2/ops_vm.h
fs/gfs2/quota.h
fs/gfs2/recovery.h
fs/gfs2/rgrp.h
fs/gfs2/super.h
fs/gfs2/sys.h
... | ... | @@ -10,6 +10,9 @@ |
10 | 10 | #ifndef __SYS_DOT_H__ |
11 | 11 | #define __SYS_DOT_H__ |
12 | 12 | |
13 | +#include <linux/spinlock.h> | |
14 | +struct gfs2_sbd; | |
15 | + | |
13 | 16 | /* Allow args to be passed to GFS2 when using an initial ram disk */ |
14 | 17 | extern char *gfs2_sys_margs; |
15 | 18 | extern spinlock_t gfs2_sys_margs_lock; |
fs/gfs2/trans.h
... | ... | @@ -10,6 +10,11 @@ |
10 | 10 | #ifndef __TRANS_DOT_H__ |
11 | 11 | #define __TRANS_DOT_H__ |
12 | 12 | |
13 | +#include <linux/buffer_head.h> | |
14 | +struct gfs2_sbd; | |
15 | +struct gfs2_rgrpd; | |
16 | +struct gfs2_glock; | |
17 | + | |
13 | 18 | #define RES_DINODE 1 |
14 | 19 | #define RES_INDIRECT 1 |
15 | 20 | #define RES_JDATA 1 |
... | ... | @@ -20,8 +25,8 @@ |
20 | 25 | #define RES_STATFS 1 |
21 | 26 | #define RES_QUOTA 2 |
22 | 27 | |
23 | -int gfs2_trans_begin(struct gfs2_sbd *sdp, | |
24 | - unsigned int blocks, unsigned int revokes); | |
28 | +int gfs2_trans_begin(struct gfs2_sbd *sdp, unsigned int blocks, | |
29 | + unsigned int revokes); | |
25 | 30 | |
26 | 31 | void gfs2_trans_end(struct gfs2_sbd *sdp); |
27 | 32 |