From: Samuel Just Date: Thu, 9 May 2013 23:49:46 +0000 (-0700) Subject: PG: no need to wait on DeletingStateRef for flush X-Git-Tag: v0.63~48^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=d3dd99b725afaa026fe6f700ddc14a7f657f2170;p=ceph.git PG: no need to wait on DeletingStateRef for flush Signed-off-by: Samuel Just --- diff --git a/src/osd/OSD.h b/src/osd/OSD.h index 2a9f28274885..528896a73a53 100644 --- a/src/osd/OSD.h +++ b/src/osd/OSD.h @@ -143,7 +143,6 @@ typedef std::tr1::shared_ptr SequencerRef; class DeletingState { Mutex lock; Cond cond; - list on_deletion_complete; enum { QUEUED, CLEARING_DIR, @@ -155,17 +154,6 @@ class DeletingState { public: DeletingState() : lock("DeletingState::lock"), status(QUEUED), stop_deleting(false) {} - void register_on_delete(Context *completion) { - Mutex::Locker l(lock); - on_deletion_complete.push_front(completion); - } - ~DeletingState() { - for (list::iterator i = on_deletion_complete.begin(); - i != on_deletion_complete.end(); - ++i) { - (*i)->complete(0); - } - } /// check whether removal was canceled bool check_canceled() { diff --git a/src/osd/PG.cc b/src/osd/PG.cc index 31aaae36a1f7..46427f0ee476 100644 --- a/src/osd/PG.cc +++ b/src/osd/PG.cc @@ -5001,9 +5001,6 @@ void PG::start_flush(ObjectStore::Transaction *t, flushed = false; on_applied->push_back(new ContainerContext(flush_trigger)); on_safe->push_back(new ContainerContext(flush_trigger)); - DeletingStateRef del = osd->deleting_pgs.lookup(info.pgid); - if (del) - del->register_on_delete(new ContainerContext(flush_trigger)); } /* Called before initializing peering during advance_map */