summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/ctree.h
diff options
context:
space:
mode:
authorChris Mason2008-06-25 22:01:30 +0200
committerChris Mason2008-09-25 17:04:03 +0200
commita213501153fd66e2359e091b1612841305ba6551 (patch)
tree1f4c316c9d3cad0eb6d9be14cb0e67e46e815dce /fs/btrfs/ctree.h
parentBtrfs: Start btree concurrency work. (diff)
downloadkernel-qcow2-linux-a213501153fd66e2359e091b1612841305ba6551.tar.gz
kernel-qcow2-linux-a213501153fd66e2359e091b1612841305ba6551.tar.xz
kernel-qcow2-linux-a213501153fd66e2359e091b1612841305ba6551.zip
Btrfs: Replace the big fs_mutex with a collection of other locks
Extent alloctions are still protected by a large alloc_mutex. Objectid allocations are covered by a objectid mutex Other btree operations are protected by a lock on individual btree nodes Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/ctree.h')
-rw-r--r--fs/btrfs/ctree.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h
index 50891b39f366..692b8ea42de1 100644
--- a/fs/btrfs/ctree.h
+++ b/fs/btrfs/ctree.h
@@ -519,9 +519,9 @@ struct btrfs_fs_info {
struct backing_dev_info bdi;
spinlock_t hash_lock;
struct mutex trans_mutex;
- struct mutex fs_mutex;
struct mutex alloc_mutex;
struct mutex chunk_mutex;
+ struct mutex drop_mutex;
struct list_head trans_list;
struct list_head hashers;
struct list_head dead_roots;
@@ -554,7 +554,7 @@ struct btrfs_fs_info {
struct completion kobj_unregister;
int do_barriers;
int closing;
- unsigned long throttles;
+ atomic_t throttles;
u64 total_pinned;
struct list_head dirty_cowonly_roots;
@@ -594,6 +594,7 @@ struct btrfs_root {
struct inode *inode;
struct kobject root_kobj;
struct completion kobj_unregister;
+ struct mutex objectid_mutex;
u64 objectid;
u64 last_trans;