diff options
author | Christoph Hellwig <hch@infradead.org> | 2007-10-11 03:44:08 -0400 |
---|---|---|
committer | Lachlan McIlroy <lachlan@redback.melbourne.sgi.com> | 2008-02-07 00:48:58 -0500 |
commit | 613d70436c1aeda6843ca8b70c7fab6d0484a591 (patch) | |
tree | e8cc8d1f2cf3720285f0439c9d057555ab293b0c /fs/xfs/xfs_inode.h | |
parent | 007c61c68640ea17c036785b698d05da67b4365e (diff) |
[XFS] kill xfs_iocore_t
xfs_iocore_t is a structure embedded in xfs_inode. Except for one field it
just duplicates fields already in xfs_inode, and there is nothing this
abstraction buys us on XFS/Linux. This patch removes it and shrinks source
and binary size of xfs aswell as shrinking the size of xfs_inode by 60/44
bytes in debug/non-debug builds.
SGI-PV: 970852
SGI-Modid: xfs-linux-melb:xfs-kern:29754a
Signed-off-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Lachlan McIlroy <lachlan@sgi.com>
Signed-off-by: Tim Shimmin <tes@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_inode.h')
-rw-r--r-- | fs/xfs/xfs_inode.h | 43 |
1 files changed, 1 insertions, 42 deletions
diff --git a/fs/xfs/xfs_inode.h b/fs/xfs/xfs_inode.h index c3e21ef02662..88caadde6077 100644 --- a/fs/xfs/xfs_inode.h +++ b/fs/xfs/xfs_inode.h | |||
@@ -132,45 +132,6 @@ typedef struct dm_attrs_s { | |||
132 | __uint16_t da_pad; /* DMIG extra padding */ | 132 | __uint16_t da_pad; /* DMIG extra padding */ |
133 | } dm_attrs_t; | 133 | } dm_attrs_t; |
134 | 134 | ||
135 | typedef struct xfs_iocore { | ||
136 | void *io_obj; /* pointer to container | ||
137 | * inode or dcxvn structure */ | ||
138 | struct xfs_mount *io_mount; /* fs mount struct ptr */ | ||
139 | #ifdef DEBUG | ||
140 | mrlock_t *io_lock; /* inode IO lock */ | ||
141 | mrlock_t *io_iolock; /* inode IO lock */ | ||
142 | #endif | ||
143 | |||
144 | /* I/O state */ | ||
145 | xfs_fsize_t io_new_size; /* sz when write completes */ | ||
146 | |||
147 | /* Miscellaneous state. */ | ||
148 | unsigned int io_flags; /* IO related flags */ | ||
149 | |||
150 | /* DMAPI state */ | ||
151 | dm_attrs_t io_dmattrs; | ||
152 | |||
153 | } xfs_iocore_t; | ||
154 | |||
155 | #define io_dmevmask io_dmattrs.da_dmevmask | ||
156 | #define io_dmstate io_dmattrs.da_dmstate | ||
157 | |||
158 | #define XFS_IO_INODE(io) ((xfs_inode_t *) ((io)->io_obj)) | ||
159 | #define XFS_IO_DCXVN(io) ((dcxvn_t *) ((io)->io_obj)) | ||
160 | |||
161 | /* | ||
162 | * Flags in the flags field | ||
163 | */ | ||
164 | |||
165 | #define XFS_IOCORE_RT 0x1 | ||
166 | |||
167 | /* | ||
168 | * xfs_iocore prototypes | ||
169 | */ | ||
170 | |||
171 | extern void xfs_iocore_inode_init(struct xfs_inode *); | ||
172 | extern void xfs_iocore_inode_reinit(struct xfs_inode *); | ||
173 | |||
174 | /* | 135 | /* |
175 | * This is the xfs inode cluster structure. This structure is used by | 136 | * This is the xfs inode cluster structure. This structure is used by |
176 | * xfs_iflush to find inodes that share a cluster and can be flushed to disk at | 137 | * xfs_iflush to find inodes that share a cluster and can be flushed to disk at |
@@ -283,9 +244,6 @@ typedef struct xfs_inode { | |||
283 | struct xfs_inode **i_refcache; /* ptr to entry in ref cache */ | 244 | struct xfs_inode **i_refcache; /* ptr to entry in ref cache */ |
284 | struct xfs_inode *i_release; /* inode to unref */ | 245 | struct xfs_inode *i_release; /* inode to unref */ |
285 | #endif | 246 | #endif |
286 | /* I/O state */ | ||
287 | xfs_iocore_t i_iocore; /* I/O core */ | ||
288 | |||
289 | /* Miscellaneous state. */ | 247 | /* Miscellaneous state. */ |
290 | unsigned short i_flags; /* see defined flags below */ | 248 | unsigned short i_flags; /* see defined flags below */ |
291 | unsigned char i_update_core; /* timestamps/size is dirty */ | 249 | unsigned char i_update_core; /* timestamps/size is dirty */ |
@@ -298,6 +256,7 @@ typedef struct xfs_inode { | |||
298 | struct hlist_node i_cnode; /* cluster link node */ | 256 | struct hlist_node i_cnode; /* cluster link node */ |
299 | 257 | ||
300 | xfs_fsize_t i_size; /* in-memory size */ | 258 | xfs_fsize_t i_size; /* in-memory size */ |
259 | xfs_fsize_t i_new_size; /* size when write completes */ | ||
301 | atomic_t i_iocount; /* outstanding I/O count */ | 260 | atomic_t i_iocount; /* outstanding I/O count */ |
302 | /* Trace buffers per inode. */ | 261 | /* Trace buffers per inode. */ |
303 | #ifdef XFS_INODE_TRACE | 262 | #ifdef XFS_INODE_TRACE |