Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DAOS-16209 pool: return mem file size on pool query #15511

Open
wants to merge 10 commits into
base: master
Choose a base branch
from
7 changes: 4 additions & 3 deletions src/control/common/proto/logging.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ func Debug(msg proto.Message) string {
fmt.Fprintf(&bld, "ranks:%s ", ranks.String())
fmt.Fprint(&bld, "tiers:")
for i, b := range m.TierBytes {
fmt.Fprintf(&bld, "%d: %d ", i, b)
fmt.Fprintf(&bld, "%d: %s (%d)", i, humanize.Bytes(b), b)
if len(m.TierRatio) > i+1 {
fmt.Fprintf(&bld, "(%.02f%%) ", m.TierRatio[i])
}
Expand All @@ -112,9 +112,10 @@ func Debug(msg proto.Message) string {
fmt.Fprintf(&bld, "tgt_ranks:%s ", ranks.String())
fmt.Fprint(&bld, "tiers:")
for i, b := range m.TierBytes {
fmt.Fprintf(&bld, "%d:%d ", i, b)
fmt.Fprintf(&bld, "%d: %s (%d)", i, humanize.Bytes(b), b)
}
fmt.Fprintf(&bld, "meta-file-size:%s", humanize.Bytes(m.MemFileBytes))
fmt.Fprintf(&bld, "meta-file-size: %s (%d)", humanize.Bytes(m.MemFileBytes),
m.MemFileBytes)
case *mgmtpb.PoolEvictReq:
fmt.Fprintf(&bld, "%T pool:%s", m, m.Id)
if len(m.Handles) > 0 {
Expand Down
29 changes: 21 additions & 8 deletions src/control/server/mgmt_pool.go
Original file line number Diff line number Diff line change
Expand Up @@ -482,6 +482,14 @@ func (svc *mgmtSvc) poolCreate(parent context.Context, req *mgmtpb.PoolCreateReq
return nil, errors.Wrap(err, "unmarshal PoolCreate response")
}

// Zero mem_file_bytes in non-MD-on-SSD mode.
if !svc.harness.Instances()[0].GetStorage().BdevRoleMetaConfigured() {
resp.MemFileBytes = 0
} else {
svc.log.Tracef("%T mem_file_bytes: %s (%d)", resp,
humanize.Bytes(resp.MemFileBytes), resp.MemFileBytes)
}

if resp.GetStatus() != 0 {
if err := svc.sysdb.RemovePoolService(ctx, ps.PoolUUID); err != nil {
return nil, err
Expand Down Expand Up @@ -960,11 +968,12 @@ func (svc *mgmtSvc) PoolQuery(ctx context.Context, req *mgmtpb.PoolQueryReq) (*m
// Preserve compatibility with pre-2.6 callers.
resp.Leader = resp.SvcLdr

// TODO DAOS-16209: After VOS query API is updated, zero-value mem_file_bytes will be
// returned in non-MD-on-SSD mode and this hack can be removed.
storage := svc.harness.Instances()[0].GetStorage()
if !storage.ControlMetadataPathConfigured() {
// Zero mem_file_bytes in non-MD-on-SSD mode.
if !svc.harness.Instances()[0].GetStorage().BdevRoleMetaConfigured() {
resp.MemFileBytes = 0
} else {
svc.log.Tracef("%T mem_file_bytes: %s (%d)", resp,
humanize.Bytes(resp.MemFileBytes), resp.MemFileBytes)
}

return resp, nil
Expand All @@ -986,13 +995,17 @@ func (svc *mgmtSvc) PoolQueryTarget(ctx context.Context, req *mgmtpb.PoolQueryTa
return nil, errors.Wrap(err, "unmarshal PoolQueryTarget response")
}

// TODO DAOS-16209: After VOS query API is updated, zero-value mem_file_bytes will be
// returned in non-MD-on-SSD mode and this hack can be removed.
storage := svc.harness.Instances()[0].GetStorage()
if !storage.ControlMetadataPathConfigured() {
// Zero mem_file_bytes in non-MD-on-SSD mode.
if !svc.harness.Instances()[0].GetStorage().BdevRoleMetaConfigured() {
for _, tgtInfo := range resp.Infos {
tgtInfo.MemFileBytes = 0
}
} else {
for _, tgtInfo := range resp.Infos {
svc.log.Tracef("%T mem_file_bytes: %s (%d)", resp,
humanize.Bytes(tgtInfo.MemFileBytes), tgtInfo.MemFileBytes)
break
}
}

return resp, nil
Expand Down
24 changes: 24 additions & 0 deletions src/include/daos_pool.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,15 @@
uint64_t s_total[DAOS_MEDIA_MAX];
/** Free space in bytes */
uint64_t s_free[DAOS_MEDIA_MAX];
/** Memory file size (in bytes) for md-on-ssd phase2 pool */
uint64_t s_total_mem;
};

struct daos_space_v6 {

Check warning on line 77 in src/include/daos_pool.h

View workflow job for this annotation

GitHub Actions / Doxygen

Compound daos_space_v6 is not documented.
/** Total space in bytes */
uint64_t s_total[DAOS_MEDIA_MAX];
/** Free space in bytes */
uint64_t s_free[DAOS_MEDIA_MAX];
};

/** Target information */
Expand Down Expand Up @@ -100,6 +109,21 @@
uint32_t ps_padding;
};

struct daos_pool_space_v6 {

Check warning on line 112 in src/include/daos_pool.h

View workflow job for this annotation

GitHub Actions / Doxygen

Compound daos_pool_space_v6 is not documented.
/** Aggregated space for all live targets */
struct daos_space_v6 ps_space;
/** Min target free space in bytes */
uint64_t ps_free_min[DAOS_MEDIA_MAX];
/** Max target free space in bytes */
uint64_t ps_free_max[DAOS_MEDIA_MAX];
/** Average target free space in bytes */
uint64_t ps_free_mean[DAOS_MEDIA_MAX];
/** Target(VOS) count */
uint32_t ps_ntargets;
/** padding - not used */
uint32_t ps_padding;
};

enum daos_rebuild_state_t {
DRS_IN_PROGRESS = 0,
DRS_NOT_STARTED = 1,
Expand Down
18 changes: 4 additions & 14 deletions src/mgmt/srv_drpc.c
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,7 @@ static int pool_create_fill_resp(Mgmt__PoolCreateResp *resp, uuid_t uuid, d_rank
for (index = 0; index < DAOS_MEDIA_MAX; ++index) {
D_ASSERT(pool_info.pi_space.ps_space.s_total[index] % resp->n_tgt_ranks == 0);
}
D_ASSERT(pool_info.pi_space.ps_space.s_total_mem % resp->n_tgt_ranks == 0);
D_ALLOC_ARRAY(resp->tier_bytes, DAOS_MEDIA_MAX);
if (resp->tier_bytes == NULL) {
rc = -DER_NOMEM;
Expand All @@ -422,6 +423,7 @@ static int pool_create_fill_resp(Mgmt__PoolCreateResp *resp, uuid_t uuid, d_rank
resp->tier_bytes[index] =
pool_info.pi_space.ps_space.s_total[index] / resp->n_tgt_ranks;
}
resp->mem_file_bytes = pool_info.pi_space.ps_space.s_total_mem / resp->n_tgt_ranks;

out:
d_rank_list_free(enabled_ranks);
Expand Down Expand Up @@ -519,14 +521,6 @@ ds_mgmt_drpc_pool_create(Drpc__Call *drpc_req, Drpc__Response *drpc_resp)
rc = pool_create_fill_resp(&resp, pool_uuid, svc);
d_rank_list_free(svc);

/**
* TODO DAOS-16209: Populate per-rank VOS-file sizes. For now just calculate here based on
* the supplied input values but really should be returned from
* ds_mgmt_pool_query() through the VOS query API and set in
* pool_create_fill_resp(). Return zero for non-MD-on-SSD mode.
*/
resp.mem_file_bytes = req->tier_bytes[DAOS_MEDIA_SCM] * req->mem_ratio;

out:
resp.status = rc;
len = mgmt__pool_create_resp__get_packed_size(&resp);
Expand Down Expand Up @@ -1866,12 +1860,7 @@ ds_mgmt_drpc_pool_query(Drpc__Call *drpc_req, Drpc__Response *drpc_resp)
pool_rebuild_status_from_info(&rebuild, &pool_info.pi_rebuild_st);
resp.rebuild = &rebuild;

/**
* TODO DAOS-16209: Populate VOS-file sizes in response. For now just return the meta-blob
* size until VOS query API is updated. When updated, zero-value should
* be returned in non-MD-on-SSD mode.
*/
resp.mem_file_bytes = scm.total;
resp.mem_file_bytes = pool_info.pi_space.ps_space.s_total_mem;

error:
resp.status = rc;
Expand Down Expand Up @@ -1983,6 +1972,7 @@ ds_mgmt_drpc_pool_query_targets(Drpc__Call *drpc_req, Drpc__Response *drpc_resp)
resp.infos[i]->space[j]->free = infos[i].ta_space.s_free[j];
resp.infos[i]->space[j]->media_type = j;
}
resp.infos[i]->mem_file_bytes = infos[i].ta_space.s_total_mem;
}

out_infos:
Expand Down
1 change: 1 addition & 0 deletions src/mgmt/tests/mocks.c
Original file line number Diff line number Diff line change
Expand Up @@ -373,6 +373,7 @@ mock_ds_mgmt_pool_query_targets_gen_infos(uint32_t n_infos)
infos[i].ta_space.s_free[DAOS_MEDIA_SCM] = 800000000 + i;
infos[i].ta_space.s_total[DAOS_MEDIA_NVME] = 9000000000;
infos[i].ta_space.s_free[DAOS_MEDIA_NVME] = 600000000 + i;
infos[i].ta_space.s_total_mem = 2000000000;
}
ds_mgmt_pool_query_targets_info_out = infos;
}
Expand Down
5 changes: 5 additions & 0 deletions src/mgmt/tests/srv_drpc_tests.c
Original file line number Diff line number Diff line change
Expand Up @@ -1329,6 +1329,8 @@ init_test_pool_info(daos_pool_info_t *pool_info)
pool_info->pi_space.ps_free_max[DAOS_MEDIA_NVME] = 8;
pool_info->pi_space.ps_free_min[DAOS_MEDIA_NVME] = 9;
pool_info->pi_space.ps_free_mean[DAOS_MEDIA_NVME] = 10;

pool_info->pi_space.ps_space.s_total_mem = 11;
}

static void
Expand Down Expand Up @@ -1394,6 +1396,8 @@ expect_query_resp_with_info(daos_pool_info_t *exp_info,
expect_storage_usage(&exp_info->pi_space, DAOS_MEDIA_NVME,
pq_resp->tier_stats[DAOS_MEDIA_NVME]);

assert_int_equal(pq_resp->mem_file_bytes, exp_info->pi_space.ps_space.s_total_mem);

assert_non_null(pq_resp->rebuild);
expect_rebuild_status(&exp_info->pi_rebuild_st, exp_state,
pq_resp->rebuild);
Expand Down Expand Up @@ -1604,6 +1608,7 @@ expect_drpc_pool_query_targets_resp_with_targets(Drpc__Response *resp,
assert_int_equal(pqt_resp->infos[i]->type, infos[i].ta_type);
assert_int_equal(pqt_resp->infos[i]->state, infos[i].ta_state);
assert_int_equal(pqt_resp->infos[i]->n_space, DAOS_MEDIA_MAX);
assert_int_equal(pqt_resp->infos[i]->mem_file_bytes, infos[i].ta_space.s_total_mem);

for (j = 0; j < DAOS_MEDIA_MAX; j++) {
Mgmt__StorageTargetUsage *space = pqt_resp->infos[i]->space[j];
Expand Down
10 changes: 5 additions & 5 deletions src/pool/cli.c
Original file line number Diff line number Diff line change
Expand Up @@ -205,15 +205,15 @@ dc_pool_init(void)
daos_register_key(&dc_pool_module_key);

dc_pool_proto_version = 0;
rc = daos_rpc_proto_query(pool_proto_fmt_v5.cpf_base, ver_array, 2, &dc_pool_proto_version);
rc = daos_rpc_proto_query(pool_proto_fmt_v6.cpf_base, ver_array, 2, &dc_pool_proto_version);
if (rc)
return rc;

if (dc_pool_proto_version == DAOS_POOL_VERSION - 1) {
rc = daos_rpc_register(&pool_proto_fmt_v5, POOL_PROTO_CLI_COUNT, NULL,
rc = daos_rpc_register(&pool_proto_fmt_v6, POOL_PROTO_CLI_COUNT, NULL,
DAOS_POOL_MODULE);
} else if (dc_pool_proto_version == DAOS_POOL_VERSION) {
rc = daos_rpc_register(&pool_proto_fmt_v6, POOL_PROTO_CLI_COUNT, NULL,
rc = daos_rpc_register(&pool_proto_fmt_v7, POOL_PROTO_CLI_COUNT, NULL,
DAOS_POOL_MODULE);
} else {
D_ERROR("%d version pool RPC not supported.\n", dc_pool_proto_version);
Expand All @@ -236,9 +236,9 @@ dc_pool_fini(void)
int rc;

if (dc_pool_proto_version == DAOS_POOL_VERSION - 1) {
rc = daos_rpc_unregister(&pool_proto_fmt_v5);
} else if (dc_pool_proto_version == DAOS_POOL_VERSION) {
rc = daos_rpc_unregister(&pool_proto_fmt_v6);
} else if (dc_pool_proto_version == DAOS_POOL_VERSION) {
rc = daos_rpc_unregister(&pool_proto_fmt_v7);
} else {
rc = -DER_PROTO;
DL_ERROR(rc, "%d version pool RPC not supported", dc_pool_proto_version);
Expand Down
68 changes: 21 additions & 47 deletions src/pool/rpc.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ crt_proc_struct_rsvc_hint(crt_proc_t proc, crt_proc_op_t proc_op,
}

CRT_RPC_DEFINE(pool_op, DAOS_ISEQ_POOL_OP, DAOS_OSEQ_POOL_OP)
CRT_RPC_DEFINE(pool_op_v6, DAOS_ISEQ_POOL_OP_V6, DAOS_OSEQ_POOL_OP)

static int
crt_proc_struct_pool_op_in(crt_proc_t proc, crt_proc_op_t proc_op,
Expand All @@ -81,60 +80,41 @@ crt_proc_struct_pool_op_out(crt_proc_t proc, crt_proc_op_t proc_op,
return crt_proc_pool_op_out(proc, data);
}

static int
crt_proc_struct_pool_op_v6_in(crt_proc_t proc, crt_proc_op_t proc_op, struct pool_op_v6_in *data)
{
return crt_proc_pool_op_v6_in(proc, data);
}

CRT_RPC_DEFINE(pool_create, DAOS_ISEQ_POOL_CREATE, DAOS_OSEQ_POOL_CREATE)
CRT_RPC_DEFINE(pool_connect_v6, DAOS_ISEQ_POOL_CONNECT_V6, DAOS_OSEQ_POOL_CONNECT)
CRT_RPC_DEFINE(pool_connect_v6, DAOS_ISEQ_POOL_CONNECT, DAOS_OSEQ_POOL_CONNECT_V6)
CRT_RPC_DEFINE(pool_connect, DAOS_ISEQ_POOL_CONNECT, DAOS_OSEQ_POOL_CONNECT)
CRT_RPC_DEFINE(pool_disconnect_v6, DAOS_ISEQ_POOL_DISCONNECT_V6, DAOS_OSEQ_POOL_DISCONNECT)
CRT_RPC_DEFINE(pool_disconnect, DAOS_ISEQ_POOL_DISCONNECT, DAOS_OSEQ_POOL_DISCONNECT)
CRT_RPC_DEFINE(pool_query_v6, DAOS_ISEQ_POOL_QUERY_V6, DAOS_OSEQ_POOL_QUERY)
CRT_RPC_DEFINE(pool_query_v6, DAOS_ISEQ_POOL_QUERY, DAOS_OSEQ_POOL_QUERY_V6)
CRT_RPC_DEFINE(pool_query, DAOS_ISEQ_POOL_QUERY, DAOS_OSEQ_POOL_QUERY)
CRT_RPC_DEFINE(pool_attr_list_v6, DAOS_ISEQ_POOL_ATTR_LIST_V6, DAOS_OSEQ_POOL_ATTR_LIST)
CRT_RPC_DEFINE(pool_attr_list, DAOS_ISEQ_POOL_ATTR_LIST, DAOS_OSEQ_POOL_ATTR_LIST)
CRT_RPC_DEFINE(pool_attr_get_v6, DAOS_ISEQ_POOL_ATTR_GET_V6, DAOS_OSEQ_POOL_OP)
CRT_RPC_DEFINE(pool_attr_get, DAOS_ISEQ_POOL_ATTR_GET, DAOS_OSEQ_POOL_OP)
CRT_RPC_DEFINE(pool_attr_set_v6, DAOS_ISEQ_POOL_ATTR_SET_V6, DAOS_OSEQ_POOL_OP)
CRT_RPC_DEFINE(pool_attr_set, DAOS_ISEQ_POOL_ATTR_SET, DAOS_OSEQ_POOL_OP)
CRT_RPC_DEFINE(pool_attr_del_v6, DAOS_ISEQ_POOL_ATTR_DEL_V6, DAOS_OSEQ_POOL_OP)
CRT_RPC_DEFINE(pool_attr_del, DAOS_ISEQ_POOL_ATTR_DEL, DAOS_OSEQ_POOL_OP)
CRT_RPC_DEFINE(pool_replicas_add, DAOS_ISEQ_POOL_MEMBERSHIP,
DAOS_OSEQ_POOL_MEMBERSHIP)
CRT_RPC_DEFINE(pool_replicas_remove, DAOS_ISEQ_POOL_MEMBERSHIP,
DAOS_OSEQ_POOL_MEMBERSHIP)
CRT_RPC_DEFINE(pool_extend, DAOS_ISEQ_POOL_EXTEND_V6, DAOS_OSEQ_POOL_EXTEND)
CRT_RPC_DEFINE(pool_add_v6, DAOS_ISEQ_POOL_TGT_UPDATE_V6, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_extend, DAOS_ISEQ_POOL_EXTEND, DAOS_OSEQ_POOL_EXTEND)
CRT_RPC_DEFINE(pool_add, DAOS_ISEQ_POOL_TGT_UPDATE, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_add_in_v6, DAOS_ISEQ_POOL_TGT_UPDATE_V6, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_add_in, DAOS_ISEQ_POOL_TGT_UPDATE, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_exclude_v6, DAOS_ISEQ_POOL_TGT_UPDATE_V6, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_exclude, DAOS_ISEQ_POOL_TGT_UPDATE, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_drain_v6, DAOS_ISEQ_POOL_TGT_UPDATE_V6, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_drain, DAOS_ISEQ_POOL_TGT_UPDATE, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_exclude_out_v6, DAOS_ISEQ_POOL_TGT_UPDATE_V6, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_exclude_out, DAOS_ISEQ_POOL_TGT_UPDATE, DAOS_OSEQ_POOL_TGT_UPDATE)
CRT_RPC_DEFINE(pool_evict, DAOS_ISEQ_POOL_EVICT_V6, DAOS_OSEQ_POOL_EVICT)
CRT_RPC_DEFINE(pool_svc_stop_v6, DAOS_ISEQ_POOL_SVC_STOP_V6, DAOS_OSEQ_POOL_SVC_STOP)
CRT_RPC_DEFINE(pool_evict, DAOS_ISEQ_POOL_EVICT, DAOS_OSEQ_POOL_EVICT)
CRT_RPC_DEFINE(pool_svc_stop, DAOS_ISEQ_POOL_SVC_STOP, DAOS_OSEQ_POOL_SVC_STOP)
CRT_RPC_DEFINE(pool_tgt_disconnect, DAOS_ISEQ_POOL_TGT_DISCONNECT,
DAOS_OSEQ_POOL_TGT_DISCONNECT)
CRT_RPC_DEFINE(pool_tgt_query, DAOS_ISEQ_POOL_TGT_QUERY,
DAOS_OSEQ_POOL_TGT_QUERY)
CRT_RPC_DEFINE(pool_tgt_query_v6, DAOS_ISEQ_POOL_TGT_QUERY, DAOS_OSEQ_POOL_TGT_QUERY_V6)
CRT_RPC_DEFINE(pool_tgt_query, DAOS_ISEQ_POOL_TGT_QUERY, DAOS_OSEQ_POOL_TGT_QUERY)
CRT_RPC_DEFINE(pool_tgt_dist_hdls, DAOS_ISEQ_POOL_TGT_DIST_HDLS,
DAOS_OSEQ_POOL_TGT_DIST_HDLS)
/* NB: prop_get/set, and acl_update/delete, upgrade use V6 input. single version engine<->engine */
CRT_RPC_DEFINE(pool_prop_get, DAOS_ISEQ_POOL_PROP_GET_V6, DAOS_OSEQ_POOL_PROP_GET)
CRT_RPC_DEFINE(pool_prop_set, DAOS_ISEQ_POOL_PROP_SET_V6, DAOS_OSEQ_POOL_PROP_SET)
CRT_RPC_DEFINE(pool_acl_update, DAOS_ISEQ_POOL_ACL_UPDATE_V6, DAOS_OSEQ_POOL_ACL_UPDATE)
CRT_RPC_DEFINE(pool_acl_delete, DAOS_ISEQ_POOL_ACL_DELETE_V6, DAOS_OSEQ_POOL_ACL_DELETE)
CRT_RPC_DEFINE(pool_prop_get, DAOS_ISEQ_POOL_PROP_GET, DAOS_OSEQ_POOL_PROP_GET)
CRT_RPC_DEFINE(pool_prop_set, DAOS_ISEQ_POOL_PROP_SET, DAOS_OSEQ_POOL_PROP_SET)
CRT_RPC_DEFINE(pool_acl_update, DAOS_ISEQ_POOL_ACL_UPDATE, DAOS_OSEQ_POOL_ACL_UPDATE)
CRT_RPC_DEFINE(pool_acl_delete, DAOS_ISEQ_POOL_ACL_DELETE, DAOS_OSEQ_POOL_ACL_DELETE)
CRT_RPC_DEFINE(pool_ranks_get, DAOS_ISEQ_POOL_RANKS_GET,
DAOS_OSEQ_POOL_RANKS_GET)
CRT_RPC_DEFINE(pool_upgrade, DAOS_ISEQ_POOL_UPGRADE_V6, DAOS_OSEQ_POOL_UPGRADE)
CRT_RPC_DEFINE(pool_list_cont_v6, DAOS_ISEQ_POOL_LIST_CONT_V6, DAOS_OSEQ_POOL_LIST_CONT)
CRT_RPC_DEFINE(pool_upgrade, DAOS_ISEQ_POOL_UPGRADE, DAOS_OSEQ_POOL_UPGRADE)
CRT_RPC_DEFINE(pool_list_cont, DAOS_ISEQ_POOL_LIST_CONT, DAOS_OSEQ_POOL_LIST_CONT)

static int
Expand Down Expand Up @@ -214,9 +194,8 @@ crt_proc_daos_pool_cont_filter_t(crt_proc_t proc, crt_proc_op_t proc_op,
return 0;
}

CRT_RPC_DEFINE(pool_filter_cont_v6, DAOS_ISEQ_POOL_FILTER_CONT_V6, DAOS_OSEQ_POOL_FILTER_CONT)
CRT_RPC_DEFINE(pool_filter_cont, DAOS_ISEQ_POOL_FILTER_CONT, DAOS_OSEQ_POOL_FILTER_CONT)
CRT_RPC_DEFINE(pool_query_info_v6, DAOS_ISEQ_POOL_QUERY_INFO_V6, DAOS_OSEQ_POOL_QUERY_INFO)
CRT_RPC_DEFINE(pool_query_info_v6, DAOS_ISEQ_POOL_QUERY_INFO, DAOS_OSEQ_POOL_QUERY_INFO_V6)
CRT_RPC_DEFINE(pool_query_info, DAOS_ISEQ_POOL_QUERY_INFO, DAOS_OSEQ_POOL_QUERY_INFO)
CRT_RPC_DEFINE(pool_tgt_query_map, DAOS_ISEQ_POOL_TGT_QUERY_MAP, DAOS_OSEQ_POOL_TGT_QUERY_MAP)
CRT_RPC_DEFINE(pool_tgt_discard, DAOS_ISEQ_POOL_TGT_DISCARD, DAOS_OSEQ_POOL_TGT_DISCARD)
Expand All @@ -234,29 +213,24 @@ CRT_RPC_DEFINE(pool_tgt_warmup, DAOS_ISEQ_POOL_TGT_WARMUP, DAOS_OSEQ_POOL_TGT_WA
},

static struct crt_proto_rpc_format pool_proto_rpc_fmt_v6[] = {POOL_PROTO_CLI_RPC_LIST(6)
POOL_PROTO_SRV_RPC_LIST};

static struct crt_proto_rpc_format pool_proto_rpc_fmt_v5[] = {
POOL_PROTO_CLI_RPC_LIST(5)
POOL_PROTO_SRV_RPC_LIST
};
POOL_PROTO_SRV_RPC_LIST(6)};
static struct crt_proto_rpc_format pool_proto_rpc_fmt_v7[] = {POOL_PROTO_CLI_RPC_LIST(7)
POOL_PROTO_SRV_RPC_LIST(7)};

#undef X

struct crt_proto_format pool_proto_fmt_v5 = {
.cpf_name = "pool",
.cpf_ver = 5,
.cpf_count = ARRAY_SIZE(pool_proto_rpc_fmt_v5),
.cpf_prf = pool_proto_rpc_fmt_v5,
.cpf_base = DAOS_RPC_OPCODE(0, DAOS_POOL_MODULE, 0)
};

struct crt_proto_format pool_proto_fmt_v6 = {.cpf_name = "pool",
.cpf_ver = 6,
.cpf_count = ARRAY_SIZE(pool_proto_rpc_fmt_v6),
.cpf_prf = pool_proto_rpc_fmt_v6,
.cpf_base = DAOS_RPC_OPCODE(0, DAOS_POOL_MODULE, 0)};

struct crt_proto_format pool_proto_fmt_v7 = {.cpf_name = "pool",
.cpf_ver = 7,
.cpf_count = ARRAY_SIZE(pool_proto_rpc_fmt_v7),
.cpf_prf = pool_proto_rpc_fmt_v7,
.cpf_base = DAOS_RPC_OPCODE(0, DAOS_POOL_MODULE, 0)};

uint64_t
pool_query_bits(daos_pool_info_t *po_info, daos_prop_t *prop)
{
Expand Down
Loading
Loading