]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
os/bluestore: drop support for non-bulky extent release. 17913/head
authorRadoslaw Zarzynski <rzarzyns@redhat.com>
Sun, 10 Sep 2017 12:05:26 +0000 (14:05 +0200)
committerRadoslaw Zarzynski <rzarzyns@redhat.com>
Fri, 29 Sep 2017 18:30:53 +0000 (20:30 +0200)
Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
src/os/bluestore/Allocator.h
src/os/bluestore/BitMapAllocator.cc
src/os/bluestore/BitMapAllocator.h
src/os/bluestore/StupidAllocator.cc
src/os/bluestore/StupidAllocator.h

index c32b33c0c17ef70c7c73097251d14c8dea162cd8..025d5b86fde2070a33928186031acc6fbfdc2074 100644 (file)
@@ -43,9 +43,6 @@ public:
     return allocate(want_size, alloc_unit, want_size, hint, extents);
   }
 
-  virtual void release(
-    uint64_t offset, uint64_t length) = 0;
-
   /* Bulk release. Implementations may override this method to handle the whole
    * set at once. This could save e.g. unnecessary mutex dance. */
   virtual void release(const interval_set<uint64_t>& release_set) = 0;
index d63804a56fd4322ab957954ced9bdb5e2f60c6de..a6646bb085fc40a3c7def18ef26c637a4f37b841 100644 (file)
@@ -145,15 +145,6 @@ int64_t BitMapAllocator::allocate_dis(
   return num * m_block_size;
 }
 
-void BitMapAllocator::release(
-  uint64_t offset, uint64_t length)
-{
-  dout(10) << __func__ << " 0x"
-           << std::hex << offset << "~" << length << std::dec
-           << dendl;
-  insert_free(offset, length);
-}
-
 void BitMapAllocator::release(
   const interval_set<uint64_t>& release_set)
 {
index 36483705db0c1e52a06086b21deed55d59ddb66d..5a3010409c48ca21888359d87e41e983810d02be 100644 (file)
@@ -35,8 +35,6 @@ public:
     uint64_t want_size, uint64_t alloc_unit, uint64_t max_alloc_size,
     int64_t hint, mempool::bluestore_alloc::vector<AllocExtent> *extents) override;
 
-  void release(
-    uint64_t offset, uint64_t length) override;
   void release(
     const interval_set<uint64_t>& release_set) override;
 
index f422fc52c03bf1df454041646038a4bd0ebfd24b..0c28fa1730afef4385a29e5bafba03e848ab4134 100644 (file)
@@ -241,16 +241,6 @@ int64_t StupidAllocator::allocate(
   return allocated_size;
 }
 
-void StupidAllocator::release(
-  uint64_t offset, uint64_t length)
-{
-  std::lock_guard<std::mutex> l(lock);
-  ldout(cct, 10) << __func__ << " 0x" << std::hex << offset << "~" << length
-                << std::dec << dendl;
-  _insert_free(offset, length);
-  num_free += length;
-}
-
 void StupidAllocator::release(
   const interval_set<uint64_t>& release_set)
 {
index 0b6780c9b16c4eb5c5a860f152b5a9190b7670ab..c8e6b28120f394bd485316aed772b3b93b9a63bb 100644 (file)
@@ -46,8 +46,6 @@ public:
     uint64_t want_size, uint64_t alloc_unit, int64_t hint,
     uint64_t *offset, uint32_t *length);
 
-  void release(
-    uint64_t offset, uint64_t length) override;
   void release(
     const interval_set<uint64_t>& release_set) override;