summaryrefslogtreecommitdiffstats
path: root/net/ceph
diff options
context:
space:
mode:
authorIlya Dryomov2013-12-24 20:19:26 +0100
committerIlya Dryomov2013-12-31 19:32:23 +0100
commitcc10df4a3a5c34cb1d5b635ac70dd1fc406153ce (patch)
tree76d7ee1a25c12f0abf4d31cdd55025bc521ab242 /net/ceph
parentcrush: apply chooseleaf_tries to firstn mode too (diff)
downloadkernel-qcow2-linux-cc10df4a3a5c34cb1d5b635ac70dd1fc406153ce.tar.gz
kernel-qcow2-linux-cc10df4a3a5c34cb1d5b635ac70dd1fc406153ce.tar.xz
kernel-qcow2-linux-cc10df4a3a5c34cb1d5b635ac70dd1fc406153ce.zip
crush: add SET_CHOOSE_TRIES rule step
Since we can specify the recursive retries in a rule, we may as well also specify the non-recursive tries too for completeness. Reflects ceph.git commit d1b97462cffccc871914859eaee562f2786abfd1. Signed-off-by: Ilya Dryomov <ilya.dryomov@inktank.com> Reviewed-by: Sage Weil <sage@inktank.com>
Diffstat (limited to 'net/ceph')
-rw-r--r--net/ceph/crush/mapper.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/net/ceph/crush/mapper.c b/net/ceph/crush/mapper.c
index c34320518c8b..a1acdea935bf 100644
--- a/net/ceph/crush/mapper.c
+++ b/net/ceph/crush/mapper.c
@@ -661,6 +661,11 @@ int crush_do_rule(const struct crush_map *map,
wsize = 1;
break;
+ case CRUSH_RULE_SET_CHOOSE_TRIES:
+ if (curstep->arg1 > 0)
+ choose_tries = curstep->arg1;
+ break;
+
case CRUSH_RULE_SET_CHOOSE_LEAF_TRIES:
if (curstep->arg1 > 0)
choose_leaf_tries = curstep->arg1;