From: Zhiqiang Wang Date: Tue, 28 Oct 2014 01:37:11 +0000 (+0800) Subject: osd: cache tiering: fix the atime logic of the eviction X-Git-Tag: v0.80.10~53^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F3949%2Fhead;p=ceph.git osd: cache tiering: fix the atime logic of the eviction Reported-by: Xinze Chi Signed-off-by: Zhiqiang Wang (cherry picked from commit 622c5ac41707069ef8db92cb67c9185acf125d40) --- diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index f1911c13f94..046e07a755c 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -11409,8 +11409,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; }