From: Radoslaw Zarzynski Date: Sun, 10 Sep 2017 12:05:26 +0000 (+0200) Subject: os/bluestore: drop support for non-bulky extent release. X-Git-Tag: v12.2.12~16^2~25 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=656984a8fc435228bad8239a162e5bb750f0cd71;p=ceph.git os/bluestore: drop support for non-bulky extent release. Signed-off-by: Radoslaw Zarzynski (cherry picked from commit 90bbcd7cbb538d5e96c0e7e12de6365a13cbf9de) --- diff --git a/src/os/bluestore/Allocator.h b/src/os/bluestore/Allocator.h index c32b33c0c17e..025d5b86fde2 100644 --- a/src/os/bluestore/Allocator.h +++ b/src/os/bluestore/Allocator.h @@ -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& release_set) = 0; diff --git a/src/os/bluestore/BitMapAllocator.cc b/src/os/bluestore/BitMapAllocator.cc index d63804a56fd4..a6646bb085fc 100644 --- a/src/os/bluestore/BitMapAllocator.cc +++ b/src/os/bluestore/BitMapAllocator.cc @@ -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& release_set) { diff --git a/src/os/bluestore/BitMapAllocator.h b/src/os/bluestore/BitMapAllocator.h index 6da4561f63da..b9a51714e880 100644 --- a/src/os/bluestore/BitMapAllocator.h +++ b/src/os/bluestore/BitMapAllocator.h @@ -34,8 +34,6 @@ public: uint64_t want_size, uint64_t alloc_unit, uint64_t max_alloc_size, int64_t hint, mempool::bluestore_alloc::vector *extents) override; - void release( - uint64_t offset, uint64_t length) override; void release( const interval_set& release_set) override; diff --git a/src/os/bluestore/StupidAllocator.cc b/src/os/bluestore/StupidAllocator.cc index 6aa527fe9538..d386af76eeb8 100644 --- a/src/os/bluestore/StupidAllocator.cc +++ b/src/os/bluestore/StupidAllocator.cc @@ -240,16 +240,6 @@ int64_t StupidAllocator::allocate( return allocated_size; } -void StupidAllocator::release( - uint64_t offset, uint64_t length) -{ - std::lock_guard l(lock); - dout(10) << __func__ << " 0x" << std::hex << offset << "~" << length - << std::dec << dendl; - _insert_free(offset, length); - num_free += length; -} - void StupidAllocator::release( const interval_set& release_set) { diff --git a/src/os/bluestore/StupidAllocator.h b/src/os/bluestore/StupidAllocator.h index d432868b38a7..ccf0f0ec14b6 100644 --- a/src/os/bluestore/StupidAllocator.h +++ b/src/os/bluestore/StupidAllocator.h @@ -49,8 +49,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& release_set) override;