]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
Revert "osdc: ObjectCacher flusher might needs additional locks"
authorJason Dillaman <dillaman@redhat.com>
Fri, 13 May 2016 01:54:58 +0000 (21:54 -0400)
committerJason Dillaman <dillaman@redhat.com>
Sat, 27 Aug 2016 23:37:37 +0000 (19:37 -0400)
This reverts commit a38f9e5104a6e08e130dc4f15ad19a06d9e63719.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
src/osdc/ObjectCacher.cc
src/osdc/WritebackHandler.h

index 878e390c0ef543498d2f0df9e16df1fafec00dc5..69facb0454f7142ef2ab09e77dbeb5c0f0b23903 100644 (file)
@@ -1749,7 +1749,6 @@ int ObjectCacher::_wait_for_write(OSDWrite *wr, uint64_t len, ObjectSet *oset,
 void ObjectCacher::flusher_entry()
 {
   ldout(cct, 10) << "flusher start" << dendl;
-  writeback_handler.get_client_lock();
   lock.Lock();
   while (!flusher_stop) {
     loff_t all = get_stat_tx() + get_stat_rx() + get_stat_clean() +
@@ -1791,8 +1790,6 @@ void ObjectCacher::flusher_entry()
       if (!max) {
        // back off the lock to avoid starving other threads
        lock.Unlock();
-       writeback_handler.put_client_lock();
-       writeback_handler.get_client_lock();
        lock.Lock();
        continue;
       }
@@ -1800,12 +1797,7 @@ void ObjectCacher::flusher_entry()
     if (flusher_stop)
       break;
 
-    writeback_handler.put_client_lock();
     flusher_cond.WaitInterval(cct, lock, seconds(1));
-    lock.Unlock();
-
-    writeback_handler.get_client_lock();
-    lock.Lock();
   }
 
   /* Wait for reads to finish. This is only possible if handling
@@ -1821,7 +1813,6 @@ void ObjectCacher::flusher_entry()
   }
 
   lock.Unlock();
-  writeback_handler.put_client_lock();
   ldout(cct, 10) << "flusher finish" << dendl;
 }
 
index 842ae54ae5af11b2f52af56c42fd2de35b20306c..c283532234176dd9cd37464a0c7de8ded4abd6bd 100644 (file)
@@ -48,9 +48,6 @@ class WritebackHandler {
                           Context *oncommit) {
     return 0;
   }
-
-  virtual void get_client_lock() {}
-  virtual void put_client_lock() {}
 };
 
 #endif