diff mbox

crush_addition_is_unsafe

Message ID CANX6DanR++1xm9_kQ3dzz7eB0SdGdhCUfrddrm3OqEzG7=a87w@mail.gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Viral Mehta Aug. 13, 2014, 1:38 p.m. UTC
Does this make sense ? I can prepare a patch.


                         return -ERANGE;

                bucket->node_weights[node] += weight;
diff mbox

Patch

diff --git a/src/crush/builder.c b/src/crush/builder.c
index c319620..5700a88 100644
--- a/src/crush/builder.c
+++ b/src/crush/builder.c
@@ -651,7 +651,7 @@  int crush_add_tree_bucket_item(struct
crush_bucket_tree *bucket, int item, int w
        for (j=1; j<depth; j++) {
                node = parent(node);

-                if
(!crush_addition_is_unsafe(bucket->node_weights[node], weight))
+                if
(crush_addition_is_unsafe(bucket->node_weights[node], weight))