]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crush: remove straw_calc_version check from has_*_tunables()
authorSage Weil <sage@redhat.com>
Tue, 8 Mar 2016 01:37:04 +0000 (20:37 -0500)
committerSage Weil <sage@redhat.com>
Tue, 8 Mar 2016 01:50:49 +0000 (20:50 -0500)
Since we do not set this when we set tunables, we should not check it
when we report which tunables they have set.  For example, a savvy
operator on firefly tunables should set straw_calc_version to 1 but we
still want the cluster to report that they are on firefly tunables.

Signed-off-by: Sage Weil <sage@redhat.com>
src/crush/CrushWrapper.h

index d5bcddda382a85ab7f94abdcd0c127f86ffd8374..0c25bb9d3815385a33154f580f3c1012db12ea4b 100644 (file)
@@ -232,7 +232,6 @@ public:
       crush->chooseleaf_descend_once == 0 &&
       crush->chooseleaf_vary_r == 0 &&
       crush->chooseleaf_stable == 0 &&
-      crush->straw_calc_version == 0 &&
       crush->allowed_bucket_algs == CRUSH_LEGACY_ALLOWED_BUCKET_ALGS;
   }
   bool has_bobtail_tunables() const {
@@ -243,7 +242,6 @@ public:
       crush->chooseleaf_descend_once == 1 &&
       crush->chooseleaf_vary_r == 0 &&
       crush->chooseleaf_stable == 0 &&
-      crush->straw_calc_version == 0 &&
       crush->allowed_bucket_algs == CRUSH_LEGACY_ALLOWED_BUCKET_ALGS;
   }
   bool has_firefly_tunables() const {
@@ -254,7 +252,6 @@ public:
       crush->chooseleaf_descend_once == 1 &&
       crush->chooseleaf_vary_r == 1 &&
       crush->chooseleaf_stable == 0 &&
-      crush->straw_calc_version == 0 &&
       crush->allowed_bucket_algs == CRUSH_LEGACY_ALLOWED_BUCKET_ALGS;
   }
   bool has_hammer_tunables() const {
@@ -265,7 +262,6 @@ public:
       crush->chooseleaf_descend_once == 1 &&
       crush->chooseleaf_vary_r == 1 &&
       crush->chooseleaf_stable == 0 &&
-      crush->straw_calc_version == 1 &&
       crush->allowed_bucket_algs == ((1 << CRUSH_BUCKET_UNIFORM) |
                                      (1 << CRUSH_BUCKET_LIST) |
                                      (1 << CRUSH_BUCKET_STRAW) |
@@ -279,7 +275,6 @@ public:
       crush->chooseleaf_descend_once == 1 &&
       crush->chooseleaf_vary_r == 1 &&
       crush->chooseleaf_stable == 1 &&
-      crush->straw_calc_version == 1 &&
       crush->allowed_bucket_algs == ((1 << CRUSH_BUCKET_UNIFORM) |
                                      (1 << CRUSH_BUCKET_LIST) |
                                      (1 << CRUSH_BUCKET_STRAW) |