Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

crush: add SET_CHOOSELEAF_VARY_R step

This lets you adjust the vary_r tunable on a per-rule basis.

Reflects ceph.git commit f944ccc20aee60a7d8da7e405ec75ad1cd449fac.

Signed-off-by: Ilya Dryomov <ilya.dryomov@inktank.com>
Reviewed-by: Josh Durgin <josh.durgin@inktank.com>

authored by

Ilya Dryomov and committed by
Sage Weil
d83ed858 e2b149cc

+6
+1
include/linux/crush/crush.h
··· 51 51 CRUSH_RULE_SET_CHOOSELEAF_TRIES = 9, /* override chooseleaf_descend_once */ 52 52 CRUSH_RULE_SET_CHOOSE_LOCAL_TRIES = 10, 53 53 CRUSH_RULE_SET_CHOOSE_LOCAL_FALLBACK_TRIES = 11, 54 + CRUSH_RULE_SET_CHOOSELEAF_VARY_R = 12 54 55 }; 55 56 56 57 /*
+5
net/ceph/crush/mapper.c
··· 709 709 choose_local_fallback_retries = curstep->arg1; 710 710 break; 711 711 712 + case CRUSH_RULE_SET_CHOOSELEAF_VARY_R: 713 + if (curstep->arg1 >= 0) 714 + vary_r = curstep->arg1; 715 + break; 716 + 712 717 case CRUSH_RULE_CHOOSELEAF_FIRSTN: 713 718 case CRUSH_RULE_CHOOSE_FIRSTN: 714 719 firstn = 1;