]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
osd: cache tiering: fix the atime logic of the eviction 2815/head
authorZhiqiang Wang <zhiqiang.wang@intel.com>
Tue, 28 Oct 2014 01:37:11 +0000 (09:37 +0800)
committerZhiqiang Wang <zhiqiang.wang@intel.com>
Tue, 28 Oct 2014 01:37:11 +0000 (09:37 +0800)
Reported-by: Xinze Chi <xmdxcxz@gmail.com>
Signed-off-by: Zhiqiang Wang <zhiqiang.wang@intel.com>
src/osd/ReplicatedPG.cc

index dcef9a76ed90e91b1204cb875378a286a7f0480d..f669cd665e347aad3125a09ed36295f61df0bf99 100644 (file)
@@ -11657,8 +11657,7 @@ bool ReplicatedPG::agent_maybe_evict(ObjectContextRef& obc)
 
     // FIXME: ignore temperature for now.
 
-    // KISS: if [lower,upper] spans our target effort, evict it.
-    if (atime_lower >= agent_state->evict_effort)
+    if (1000000 - atime_upper >= agent_state->evict_effort)
       return false;
   }