1
0
mirror of https://github.com/ceph/ceph synced 2024-12-26 13:33:57 +00:00

osd/OSDMap: add CRUSH_CHOOSEARGS feature bit

Signed-off-by: Sage Weil <sage@redhat.com>
This commit is contained in:
Sage Weil 2017-05-04 12:41:14 -05:00
parent 04b9e9f1a3
commit ef1ef284ac
2 changed files with 8 additions and 2 deletions

View File

@ -101,6 +101,7 @@ DEFINE_CEPH_FEATURE(21, 2, SERVER_LUMINOUS)
DEFINE_CEPH_FEATURE(21, 2, RESEND_ON_SPLIT) // overlap
DEFINE_CEPH_FEATURE(21, 2, RADOS_BACKOFF) // overlap
DEFINE_CEPH_FEATURE(21, 2, OSDMAP_PG_UPMAP) // overlap
DEFINE_CEPH_FEATURE(21, 2, CRUSH_CHOOSEARGS) // overlap
DEFINE_CEPH_FEATURE_RETIRED(22, 1, BACKFILL_RESERVATION, JEWEL, LUMINOUS)
DEFINE_CEPH_FEATURE(23, 1, MSG_AUTH)
@ -251,7 +252,8 @@ DEFINE_CEPH_FEATURE_DEPRECATED(63, 1, RESERVED_BROKEN, LUMINOUS) // client-facin
CEPH_FEATURE_CRUSH_TUNABLES3 | \
CEPH_FEATURE_CRUSH_TUNABLES5 | \
CEPH_FEATURE_CRUSH_V2 | \
CEPH_FEATURE_CRUSH_V4)
CEPH_FEATURE_CRUSH_V4 | \
CEPH_FEATURE_CRUSH_CHOOSEARGS)
/*
* make sure we don't try to use the reserved features

View File

@ -1167,6 +1167,8 @@ uint64_t OSDMap::get_features(int entity_type, uint64_t *pmask) const
features |= CEPH_FEATURE_CRUSH_V4;
if (crush->has_nondefault_tunables5())
features |= CEPH_FEATURE_CRUSH_TUNABLES5;
if (crush->has_incompat_chooseargs())
features |= CEPH_FEATURE_CRUSH_CHOOSEARGS;
mask |= CEPH_FEATURES_CRUSH;
if (!pg_upmap.empty() || !pg_upmap_items.empty())
@ -1247,7 +1249,9 @@ pair<string,string> OSDMap::get_min_compat_client() const
{
uint64_t f = get_features(CEPH_ENTITY_TYPE_CLIENT, nullptr);
if (HAVE_FEATURE(f, OSDMAP_PG_UPMAP)) { // v12.0.0-1733-g27d6f43
if (HAVE_FEATURE(f, OSDMAP_PG_UPMAP) || // v12.0.0-1733-g27d6f43
#warning update this commit description right before or after merge
HAVE_FEATURE(f, CRUSH_CHOOSEARGS)) { // FIXME
return make_pair("luminous", "12.2.0");
}
if (HAVE_FEATURE(f, CRUSH_TUNABLES5)) { // v10.0.0-612-g043a737