Skip to content

Commit

Permalink
DAOS-16809 engine: fix for review feedback
Browse files Browse the repository at this point in the history
Signed-off-by: Fan Yong <[email protected]>
  • Loading branch information
Nasf-Fan committed Jan 15, 2025
1 parent 7aa0703 commit 1245805
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 16 deletions.
2 changes: 1 addition & 1 deletion src/container/srv_target.c
Original file line number Diff line number Diff line change
Expand Up @@ -322,7 +322,7 @@ cont_child_aggregate(struct ds_cont_child *cont, cont_aggregate_cb_t agg_cb,
DAOS_FAIL_CHECK(DAOS_FORCE_EC_AGG_PEER_FAIL)))
interval = 0;
else
interval = cont->sc_agg_eph_gap;
interval = d_sec2hlc(vos_get_agg_gap());

D_ASSERT(hlc > (interval * 2));
/*
Expand Down
2 changes: 0 additions & 2 deletions src/dtx/dtx_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -1855,8 +1855,6 @@ dtx_cont_register(struct ds_cont_child *cont)
D_GOTO(out, rc = -DER_NOMEM);
}

cont->sc_agg_eph_gap = d_sec2hlc(vos_get_agg_gap());

ds_cont_child_get(cont);
dbca->dbca_refs = 0;
dbca->dbca_cont = cont;
Expand Down
5 changes: 2 additions & 3 deletions src/engine/sched.c
Original file line number Diff line number Diff line change
Expand Up @@ -947,7 +947,8 @@ static inline bool
is_pressure_recent(struct sched_info *info, struct sched_pool_info *spi)
{
D_ASSERT(info->si_cur_ts >= spi->spi_pressure_ts);
return (info->si_cur_ts - spi->spi_pressure_ts) < info->si_agg_gap;
return (info->si_cur_ts - spi->spi_pressure_ts) <
(vos_get_agg_gap() + 10) * 1000; /* msecs */
}

static inline uint64_t
Expand Down Expand Up @@ -2240,8 +2241,6 @@ sched_run(ABT_sched sched)
return;
}

dx->dx_sched_info.si_agg_gap = (vos_get_agg_gap() + 10) * 1000; /* msecs */

while (1) {
/* Try to pick network poll ULT */
pool = pools[DSS_POOL_NET_POLL];
Expand Down
2 changes: 0 additions & 2 deletions src/engine/srv_internal.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/*
* (C) Copyright 2016-2024 Intel Corporation.
* (C) Copyright 2025 Hewlett Packard Enterprise Development LP
*
* SPDX-License-Identifier: BSD-2-Clause-Patent
*/
Expand Down Expand Up @@ -61,7 +60,6 @@ struct sched_info {
/* Number of kicked requests for each type in current cycle */
uint32_t si_kicked_req_cnt[SCHED_REQ_MAX];
unsigned int si_stop:1;
uint64_t si_agg_gap;
};

struct mem_stats {
Expand Down
7 changes: 0 additions & 7 deletions src/include/daos_srv/container.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
/*
* (C) Copyright 2015-2024 Intel Corporation.
* (C) Copyright 2025 Hewlett Packard Enterprise Development LP
*
* SPDX-License-Identifier: BSD-2-Clause-Patent
*/
Expand Down Expand Up @@ -130,12 +129,6 @@ struct ds_cont_child {
*/
uint64_t sc_ec_update_timestamp;

/*
* The gap between the max allowed aggregation epoch and current HLC. The modification
* with older epoch out of range may cause conflict with aggregation as to be rejected.
*/
uint64_t sc_agg_eph_gap;

/* The objects with committable DTXs in DRAM. */
daos_handle_t sc_dtx_cos_hdl;
/* The DTX COS-btree. */
Expand Down
2 changes: 1 addition & 1 deletion src/vos/vos_container.c
Original file line number Diff line number Diff line change
Expand Up @@ -925,7 +925,7 @@ vos_cont_get_local_stable_epoch(daos_handle_t coh)
* epoch when reintegrate into the system.
*/
daos_epoch_t
vos_cont_get_globla_stable_epoch(daos_handle_t coh)
vos_cont_get_global_stable_epoch(daos_handle_t coh)
{
struct vos_container *cont;
struct vos_cont_ext_df *cont_ext;
Expand Down

0 comments on commit 1245805

Please sign in to comment.