From a0dd46c5d106f5e59b5aaa4b5898df7a37d15ba8 Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Tue, 21 Jun 2016 07:18:35 +0800 Subject: [PATCH] bluestore/BitAllocator: silence warnings of method hidden is_allocated(int64_t *blocks, int64_t num_blocks, int blk_off) only gets called in BitMapAreaIN and its child classes. so it's safe to move this method down to BitMapAreaIN. Signed-off-by: Kefu Chai --- src/os/bluestore/BitAllocator.h | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/os/bluestore/BitAllocator.h b/src/os/bluestore/BitAllocator.h index 9e59edfc415..ec3227caea5 100644 --- a/src/os/bluestore/BitAllocator.h +++ b/src/os/bluestore/BitAllocator.h @@ -191,10 +191,6 @@ public: bmap_area_type_t level_to_type(int level); static int get_level(int64_t total_blocks); virtual bool is_allocated(int64_t start_block, int64_t num_blocks) = 0; - virtual bool is_allocated(int64_t *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); @@ -370,7 +366,7 @@ protected: BitMapAreaList *m_child_list; bool is_allocated(int64_t start_block, int64_t num_blocks); - bool is_allocated(int64_t *blocks, int64_t num_blocks, int64_t blk_off); + virtual bool is_allocated(int64_t *blocks, int64_t num_blocks, int64_t blk_off); virtual bool is_exhausted(); virtual bool child_check_n_lock(BitMapArea *child, int64_t required); virtual void child_unlock(BitMapArea *child); -- 2.39.5