summaryrefslogtreecommitdiffstats
path: root/recipes-extended/ceph/ceph/0005-kv-rocksdb_cache-mark-Shard-const.patch
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-extended/ceph/ceph/0005-kv-rocksdb_cache-mark-Shard-const.patch')
-rw-r--r--recipes-extended/ceph/ceph/0005-kv-rocksdb_cache-mark-Shard-const.patch32
1 files changed, 0 insertions, 32 deletions
diff --git a/recipes-extended/ceph/ceph/0005-kv-rocksdb_cache-mark-Shard-const.patch b/recipes-extended/ceph/ceph/0005-kv-rocksdb_cache-mark-Shard-const.patch
deleted file mode 100644
index bc18574c..00000000
--- a/recipes-extended/ceph/ceph/0005-kv-rocksdb_cache-mark-Shard-const.patch
+++ /dev/null
@@ -1,32 +0,0 @@
1From 52c57e25a5e2c617bc797b8ce50060b5894bd7fc Mon Sep 17 00:00:00 2001
2From: Kefu Chai <kchai@redhat.com>
3Date: Tue, 17 Aug 2021 18:06:31 +0800
4Subject: [PATCH 5/6] kv/rocksdb_cache: mark Shard() const
5
6it does not mutate anything, so mark it `const`.
7
8Signed-off-by: Kefu Chai <kchai@redhat.com>
9
10Upstream-Status: Backport [0296ac4458c0be0609f033e15b0fa8c6c9c20049]
11
12Signed-off-by: Sakib Sajal <sakib.sajal@windriver.com>
13---
14 src/kv/rocksdb_cache/ShardedCache.h | 2 +-
15 1 file changed, 1 insertion(+), 1 deletion(-)
16
17diff --git a/src/kv/rocksdb_cache/ShardedCache.h b/src/kv/rocksdb_cache/ShardedCache.h
18index 4d3ca302..f98421a0 100644
19--- a/src/kv/rocksdb_cache/ShardedCache.h
20+++ b/src/kv/rocksdb_cache/ShardedCache.h
21@@ -136,7 +136,7 @@ class ShardedCache : public rocksdb::Cache, public PriorityCache::PriCache {
22 // return Hash(s.data(), s.size(), 0);
23 }
24
25- uint32_t Shard(uint32_t hash) {
26+ uint32_t Shard(uint32_t hash) const {
27 // Note, hash >> 32 yields hash in gcc, not the zero we expect!
28 return (num_shard_bits_ > 0) ? (hash >> (32 - num_shard_bits_)) : 0;
29 }
30--
312.33.0
32