diff options
author | Anton Altaparmakov <aia21@cantab.net> | 2004-11-18 08:46:45 -0500 |
---|---|---|
committer | Anton Altaparmakov <aia21@cantab.net> | 2005-05-05 05:30:29 -0400 |
commit | 367636772f094fd840d2d79e75257bcfaa28e70f (patch) | |
tree | a8d8f3154eea80710a8cad2b7de082046aa012f0 /fs/ntfs/inode.h | |
parent | 899101aebb9ab3692aa8efe2805174ee0ee3edb5 (diff) |
NTFS: - In fs/ntfs/compress.c, use i_size_read() at the start and then use the
cached value everywhere. Cache the initialized_size in the same way
and protect the critical region where the two sizes are read using the
new size_lock of the ntfs inode.
- Add the new size_lock to the ntfs_inode structure (fs/ntfs/inode.h)
and initialize it (fs/ntfs/inode.c).
Signed-off-by: Anton Altaparmakov <aia21@cantab.net>
Diffstat (limited to 'fs/ntfs/inode.h')
-rw-r--r-- | fs/ntfs/inode.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/ntfs/inode.h b/fs/ntfs/inode.h index 99580455f2ed..56b2d6ec33f7 100644 --- a/fs/ntfs/inode.h +++ b/fs/ntfs/inode.h | |||
@@ -44,6 +44,7 @@ typedef struct _ntfs_inode ntfs_inode; | |||
44 | * fields already provided in the VFS inode. | 44 | * fields already provided in the VFS inode. |
45 | */ | 45 | */ |
46 | struct _ntfs_inode { | 46 | struct _ntfs_inode { |
47 | rwlock_t size_lock; /* Lock serializing access to inode sizes. */ | ||
47 | s64 initialized_size; /* Copy from the attribute record. */ | 48 | s64 initialized_size; /* Copy from the attribute record. */ |
48 | s64 allocated_size; /* Copy from the attribute record. */ | 49 | s64 allocated_size; /* Copy from the attribute record. */ |
49 | unsigned long state; /* NTFS specific flags describing this inode. | 50 | unsigned long state; /* NTFS specific flags describing this inode. |