]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: fix eval_gather for sync->mix(2) and mix->sync(2)
authorSage Weil <sage@newdream.net>
Tue, 23 Mar 2010 18:41:33 +0000 (11:41 -0700)
committerSage Weil <sage@newdream.net>
Tue, 23 Mar 2010 19:13:14 +0000 (12:13 -0700)
These states never move to next state on the client on their own.
The auth mds needs to tell them to switch states.

src/mds/Locker.cc

index f3eef4ba2f6de1b11ee3b4b639c4f11ff5f256de..361a3c250ebc0176e60147e57e98bffe79ad0208 100644 (file)
@@ -419,7 +419,10 @@ void Locker::eval_gather(SimpleLock *lock, bool first, bool *pneed_issue)
       (lock->get_sm()->states[next].can_lease || !lock->is_leased()) &&
       (!caps || ((~lock->gcaps_allowed(CAP_ANY, next) & other_issued) == 0 &&
                 (~lock->gcaps_allowed(CAP_LONER, next) & loner_issued) == 0 &&
-                (~lock->gcaps_allowed(CAP_XLOCKER, next) & xlocker_issued) == 0))) {
+                (~lock->gcaps_allowed(CAP_XLOCKER, next) & xlocker_issued) == 0)) &&
+      lock->get_state() != LOCK_SYNC_MIX2 &&  // these states need an explicit trigger from the auth mds
+      lock->get_state() != LOCK_MIX_SYNC2
+      ) {
     dout(7) << "eval_gather finished gather on " << *lock
            << " on " << *lock->get_parent() << dendl;