mirror of
https://github.com/ceph/ceph
synced 2024-12-28 22:43:29 +00:00
crush/CrushWrapper: add bucket_set_alg()
Signed-off-by: Sage Weil <sage@redhat.com>
This commit is contained in:
parent
e6668b5646
commit
edc411ee4c
@ -1842,6 +1842,16 @@ int CrushWrapper::bucket_remove_item(crush_bucket *bucket, int item)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int CrushWrapper::bucket_set_alg(int bid, int alg)
|
||||
{
|
||||
crush_bucket *b = get_bucket(bid);
|
||||
if (!b) {
|
||||
return -ENOENT;
|
||||
}
|
||||
b->alg = alg;
|
||||
return 0;
|
||||
}
|
||||
|
||||
int CrushWrapper::update_device_class(int id,
|
||||
const string& class_name,
|
||||
const string& name,
|
||||
|
@ -1252,6 +1252,7 @@ public:
|
||||
crush_finalize(crush);
|
||||
have_uniform_rules = !has_legacy_rule_ids();
|
||||
}
|
||||
int bucket_set_alg(int id, int alg);
|
||||
|
||||
int update_device_class(int id, const string& class_name, const string& name, ostream *ss);
|
||||
int remove_device_class(CephContext *cct, int id, ostream *ss);
|
||||
|
Loading…
Reference in New Issue
Block a user