diff options
author | Christoph Hellwig <hch@tuxera.com> | 2010-10-01 05:45:08 +0200 |
---|---|---|
committer | Christoph Hellwig <hch@lst.de> | 2010-10-01 05:45:08 +0200 |
commit | 7ac9fb9c2a50963b699b3548e6f00698c1554dc6 (patch) | |
tree | 3660bfb2985c65838b5969694e54043ae6639b3a /fs/hfsplus/hfsplus_fs.h | |
parent | 58a818f532e83f337689358c102ba2048d1b37f5 (diff) | |
download | kernel_samsung_tuna-7ac9fb9c2a50963b699b3548e6f00698c1554dc6.zip kernel_samsung_tuna-7ac9fb9c2a50963b699b3548e6f00698c1554dc6.tar.gz kernel_samsung_tuna-7ac9fb9c2a50963b699b3548e6f00698c1554dc6.tar.bz2 |
hfsplus: add per-superblock lock for volume header updates
Lock updates to the mutal fields in the volume header, and document the
locing in the hfsplus_sb_info structure.
Signed-off-by: Christoph Hellwig <hch@tuxera.com>
Diffstat (limited to 'fs/hfsplus/hfsplus_fs.h')
-rw-r--r-- | fs/hfsplus/hfsplus_fs.h | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/fs/hfsplus/hfsplus_fs.h b/fs/hfsplus/hfsplus_fs.h index 0cd9ba0..08865ed 100644 --- a/fs/hfsplus/hfsplus_fs.h +++ b/fs/hfsplus/hfsplus_fs.h @@ -116,23 +116,26 @@ struct hfsplus_sb_info { struct inode *hidden_dir; struct nls_table *nls; - /* synchronize block allocations */ - struct mutex alloc_mutex; - /* Runtime variables */ u32 blockoffset; u32 sect_count; int fs_shift; - /* Stuff in host order from Vol Header */ + /* immutable data from the volume header */ u32 alloc_blksz; int alloc_blksz_shift; u32 total_blocks; + u32 data_clump_blocks, rsrc_clump_blocks; + + /* mutable data from the volume header, protected by alloc_mutex */ u32 free_blocks; + struct mutex alloc_mutex; + + /* mutable data from the volume header, protected by vh_mutex */ u32 next_cnid; u32 file_count; u32 folder_count; - u32 data_clump_blocks, rsrc_clump_blocks; + struct mutex vh_mutex; /* Config options */ u32 creator; |