diff options
author | Sage Weil <sage@inktank.com> | 2013-10-22 19:41:33 -0700 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2013-10-22 19:41:33 -0700 |
commit | a15b21321e7ca1a5aa49db912a4c35c113b0095f (patch) | |
tree | 602def454849a07876a67e54cebe5876e919f6cd | |
parent | 7583c3d941920ef5e6ad37c5ee740f9bf3854348 (diff) | |
download | ceph-a15b21321e7ca1a5aa49db912a4c35c113b0095f.tar.gz |
wip cache_flush
-rw-r--r-- | src/osd/ReplicatedPG.cc | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index 64896d94b5f..ac4d623f1e5 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -2747,6 +2747,21 @@ int ReplicatedPG::do_osd_ops(OpContext *ctx, vector<OSDOp>& ops) } break; + case CEPH_OSD_OP_CACHE_FLUSH: + ++ctx->num_write; + { + if (pool.info.cache_mode == pg_pool_t::CACHEMODE_NONE) { + result = -EINVAL; + break; + } + if (oi.is_dirty()) { + assert(0 == "flush not implemented yet"); + } else { + result = 0; + } + } + break; + case CEPH_OSD_OP_CACHE_EVICT: ++ctx->num_write; { |