From 5ea4f1a8d1f53c63cb46982b23a57bbf0062d7a9 Mon Sep 17 00:00:00 2001 From: Ramesh Chander Date: Fri, 29 Jul 2016 02:16:57 -0700 Subject: [PATCH] os/bluestore: remove cmake warning from extent alloc functions. tracker link: http://tracker.ceph.com/issues/16766 Signed-off-by: Ramesh Chander --- src/os/bluestore/Allocator.h | 2 +- src/os/bluestore/BitAllocator.h | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/os/bluestore/Allocator.h b/src/os/bluestore/Allocator.h index 774eb1196a678c..0efebd4997cee1 100644 --- a/src/os/bluestore/Allocator.h +++ b/src/os/bluestore/Allocator.h @@ -43,7 +43,7 @@ class Allocator { uint64_t max_alloc_size, int64_t hint, std::vector *extents, int *count) = 0; - virtual int alloc_extents(uint64_t want_size, uint64_t alloc_unit, + int alloc_extents(uint64_t want_size, uint64_t alloc_unit, int64_t hint, std::vector *extents, int *count) { return alloc_extents(want_size, alloc_unit, want_size, hint, extents, count); diff --git a/src/os/bluestore/BitAllocator.h b/src/os/bluestore/BitAllocator.h index d2f4615f43daf0..098ec470eab27c 100644 --- a/src/os/bluestore/BitAllocator.h +++ b/src/os/bluestore/BitAllocator.h @@ -194,10 +194,6 @@ class BitMapArea { static int get_level(int64_t total_blocks); static int64_t get_level_factor(int level); virtual bool is_allocated(int64_t start_block, int64_t num_blocks) = 0; - virtual bool is_allocated(ExtentList *blocks, int64_t num_blocks, int blk_off) { - debug_assert(0); - return true; - } virtual bool is_exhausted() = 0; virtual bool child_check_n_lock(BitMapArea *child, int64_t required) { debug_assert(0); @@ -322,6 +318,7 @@ class BitMapZone: public BitMapArea{ static int64_t total_blocks; static void incr_count() { count++;} static int64_t get_total_blocks() {return total_blocks;} + bool is_allocated(int64_t start_block, int64_t num_blocks); bool is_exhausted(); void reset_marker(); @@ -364,6 +361,7 @@ class BitMapZone: public BitMapArea{ } int64_t alloc_blocks(int64_t num_blocks, int64_t *start_block); + using BitMapArea::alloc_blocks_dis; int64_t alloc_blocks_dis(int64_t num_blocks, int64_t blk_off, ExtentList *block_list); void set_blocks_used(int64_t start_block, int64_t num_blocks); @@ -384,6 +382,8 @@ class BitMapAreaIN: public BitMapArea{ std::mutex m_blocks_lock; BitMapAreaList *m_child_list; + + using BitMapArea::is_allocated; virtual bool is_allocated(int64_t start_block, int64_t num_blocks); virtual bool is_exhausted();