forked from lei.chen/myxce
improve resmgr
This commit is contained in:
parent
4db6b039c5
commit
1f1e4fdaba
10 changed files with 107 additions and 221 deletions
|
|
@ -65,7 +65,7 @@ static int update_val_res(cluster_t* c, worker_t* w, xce_resource_t* r,
|
|||
|
||||
if (r->flags & XCE_RESF_SHARED) {
|
||||
/* update shared resource */
|
||||
array = &(c->resmgr.sharedinst);
|
||||
array = &(c->sharedinst);
|
||||
} else {
|
||||
/* update host based resource */
|
||||
array = &(w->host.resvals);
|
||||
|
|
@ -457,7 +457,7 @@ int get_resval(cluster_t* c, char* resname, char* host, xce_val_t* val)
|
|||
|
||||
array = &(w->host.resvals);
|
||||
} else {
|
||||
array = &(c->resmgr.sharedinst);
|
||||
array = &(c->sharedinst);
|
||||
}
|
||||
|
||||
if (r->idx < array->caps) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue