]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
osd/ReplicatedPG: fix cache full -> not full requeueing when !active
authorSage Weil <sage@redhat.com>
Fri, 25 Jul 2014 21:43:48 +0000 (14:43 -0700)
committerSage Weil <sage@redhat.com>
Fri, 25 Jul 2014 21:50:51 +0000 (14:50 -0700)
We only want to do this if is_active().  Otherwise, the normal
requeueing code will do its thing, taking care to get the queue orders
correct.

Backport: firefly
Signed-off-by: Sage Weil <sage@redhat.com>
src/osd/ReplicatedPG.cc

index 1d3af34c33ffc7bd84d13ebf574a88c7d3e14e85..d38d7e13cf771b6fdbc1a6b162d95aade0ea9602 100644 (file)
@@ -11573,8 +11573,10 @@ void ReplicatedPG::agent_choose_mode(bool restart)
            << " -> "
            << TierAgentState::get_evict_mode_name(evict_mode)
            << dendl;
-    if (agent_state->evict_mode == TierAgentState::EVICT_MODE_FULL) {
+    if (agent_state->evict_mode == TierAgentState::EVICT_MODE_FULL &&
+       is_active()) {
       requeue_ops(waiting_for_cache_not_full);
+      requeue_ops(waiting_for_active);
     }
     agent_state->evict_mode = evict_mode;
   }