Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
[linux-2.6-block.git] / fs / jffs2 / jffs2_fs_i.h
CommitLineData
182ec4ee 1/* $Id: jffs2_fs_i.h,v 1.19 2005/11/07 11:14:52 gleixner Exp $ */
1da177e4
LT
2
3#ifndef _JFFS2_FS_I
4#define _JFFS2_FS_I
5
6#include <linux/version.h>
7#include <linux/rbtree.h>
aa98d7cf 8#include <linux/posix_acl.h>
1da177e4
LT
9#include <asm/semaphore.h>
10
11struct jffs2_inode_info {
1b1dcc1b 12 /* We need an internal mutex similar to inode->i_mutex.
1da177e4
LT
13 Unfortunately, we can't used the existing one, because
14 either the GC would deadlock, or we'd have to release it
15 before letting GC proceed. Or we'd have to put ugliness
1b1dcc1b 16 into the GC code so it didn't attempt to obtain the i_mutex
1da177e4
LT
17 for the inode(s) which are already locked */
18 struct semaphore sem;
19
20 /* The highest (datanode) version number used for this ino */
21 uint32_t highest_version;
22
23 /* List of data fragments which make up the file */
24 struct rb_root fragtree;
25
26 /* There may be one datanode which isn't referenced by any of the
27 above fragments, if it contains a metadata update but no actual
28 data - or if this is a directory inode */
182ec4ee 29 /* This also holds the _only_ dnode for symlinks/device nodes,
1da177e4
LT
30 etc. */
31 struct jffs2_full_dnode *metadata;
32
33 /* Directory entries */
34 struct jffs2_full_dirent *dents;
35
2b79adcc
AB
36 /* The target path if this is the inode of a symlink */
37 unsigned char *target;
38
1da177e4
LT
39 /* Some stuff we just have to keep in-core at all times, for each inode. */
40 struct jffs2_inode_cache *inocache;
41
42 uint16_t flags;
43 uint8_t usercompr;
1da177e4 44 struct inode vfs_inode;
aa98d7cf
KK
45#ifdef CONFIG_JFFS2_FS_POSIX_ACL
46 struct posix_acl *i_acl_access;
47 struct posix_acl *i_acl_default;
48#endif
1da177e4
LT
49};
50
51#endif /* _JFFS2_FS_I */