diff options
author | Sage Weil <sage@newdream.net> | 2009-12-21 23:40:34 -0500 |
---|---|---|
committer | Sage Weil <sage@newdream.net> | 2009-12-23 11:17:14 -0500 |
commit | 5dacf09121ffb2e5fc7d15b78cae0b77042a1935 (patch) | |
tree | 8a4ec2fde459f93936a91644d024673d37347408 /fs/ceph/mds_client.h | |
parent | 7067f797b8409f1e10ec95ac2c1e17a200173d13 (diff) |
ceph: do not touch_caps while iterating over caps list
Avoid confusing iterate_session_caps(), flag the session while we are
iterating so that __touch_cap does not rearrange items on the list.
All other modifiers of session->s_caps do so under the protection of
s_mutex.
Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'fs/ceph/mds_client.h')
-rw-r--r-- | fs/ceph/mds_client.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/ceph/mds_client.h b/fs/ceph/mds_client.h index 41af5ca316e6..b1c2025227c5 100644 --- a/fs/ceph/mds_client.h +++ b/fs/ceph/mds_client.h | |||
@@ -114,6 +114,7 @@ struct ceph_mds_session { | |||
114 | int s_num_cap_releases; | 114 | int s_num_cap_releases; |
115 | struct list_head s_cap_releases; /* waiting cap_release messages */ | 115 | struct list_head s_cap_releases; /* waiting cap_release messages */ |
116 | struct list_head s_cap_releases_done; /* ready to send */ | 116 | struct list_head s_cap_releases_done; /* ready to send */ |
117 | bool s_iterating_caps; | ||
117 | 118 | ||
118 | /* protected by mutex */ | 119 | /* protected by mutex */ |
119 | struct list_head s_cap_flushing; /* inodes w/ flushing caps */ | 120 | struct list_head s_cap_flushing; /* inodes w/ flushing caps */ |