30 #define M0_TRACE_SUBSYSTEM M0_TRACE_SUBSYS_DTM 53 oper_tlist_move_tail(&oper->
oprt_uu, update);
76 ergo(u0->upd_label == u1->upd_label,
78 u0->upd_label == 0)))) &&
85 uint32_t max_label = 0;
101 max_label =
max32u(max_label, update->upd_label);
110 if (update->upd_label == 0)
111 update->upd_label = ++max_label;
114 update->upd_up.up_ver);
133 if (history->
h_rem == rem) {
196 update = oper_tlist_pop(
uu);
264 if (update->upd_label == label)
297 (
unsigned)oper_tlist_length(&oper->
oprt_uu));
303 #undef M0_TRACE_SUBSYSTEM M0_INTERNAL void m0_dtm_op_init(struct m0_dtm_op *op, struct m0_dtm_nu *nu)
M0_INTERNAL int m0_dtm_update_build(struct m0_dtm_update *update, struct m0_dtm_oper *oper, const struct m0_dtm_update_descr *updd)
enum m0_dtm_state up_state
struct m0_dtm_update_data udd_data
M0_INTERNAL void m0_dtm_update_unpack(struct m0_dtm_update *update, const struct m0_dtm_update_descr *updd)
static struct m0_dtm_oper_descr ode[REM_NR][OPER_NR]
#define oper_for(o, update)
struct m0_dtm_oper_updates od_updates
struct m0_dtm_remote * h_rem
#define M0_LOG(level,...)
struct m0_dtm_fol_remote re_fol
M0_INTERNAL void m0_dtm_oper_init(struct m0_dtm_oper *oper, struct m0_dtm *dtm, struct m0_tl *uu)
M0_INTERNAL void m0_dtm_oper_prepared(const struct m0_dtm_oper *oper, const struct m0_dtm_remote *rem)
M0_INTERNAL struct m0_dtm * nu_dtm(struct m0_dtm_nu *nu)
M0_INTERNAL void m0_dtm_oper_done(const struct m0_dtm_oper *oper, const struct m0_dtm_remote *rem)
M0_INTERNAL void up_prepared(struct m0_dtm_up *up)
M0_INTERNAL int m0_dtm_oper_build(struct m0_dtm_oper *oper, struct m0_tl *uu, const struct m0_dtm_oper_descr *ode)
M0_INTERNAL void m0_dtm_remote_add(struct m0_dtm_remote *rem, struct m0_dtm_oper *oper, struct m0_dtm_history *history, struct m0_dtm_update *update)
M0_INTERNAL void dtm_lock(struct m0_dtm *dtm)
struct m0_dtm_history ch_history
M0_INTERNAL void update_print(const struct m0_dtm_update *update)
#define UPDATE_HISTORY(update)
M0_INTERNAL bool oper_update_unique(const struct m0_dtm_oper *oper, const struct m0_dtm_update *update)
M0_INTERNAL void m0_dtm_oper_pack(struct m0_dtm_oper *oper, const struct m0_dtm_remote *rem, struct m0_dtm_oper_descr *ode)
M0_INTERNAL bool m0_dtm_descr_matches_update(const struct m0_dtm_update *update, const struct m0_dtm_update_descr *updd)
#define HISTORY_DTM(history)
M0_INTERNAL bool m0_dtm_controlh_update_is_close(const struct m0_dtm_update *update)
M0_INTERNAL bool m0_dtm_op_invariant(const struct m0_dtm_op *op)
struct m0_dtm_update_descr * ou_update
M0_INTERNAL void history_close(struct m0_dtm_history *history)
M0_INTERNAL void nu_lock(struct m0_dtm_nu *nu)
M0_INTERNAL struct m0_dtm_update * m0_dtm_oper_get(const struct m0_dtm_oper *oper, uint32_t label)
struct m0_dtm_controlh rfo_ch
M0_INTERNAL void m0_dtm_op_close(const struct m0_dtm_op *op)
#define UPDATE_REM(update)
M0_INTERNAL void oper_unlock(const struct m0_dtm_oper *oper)
M0_INTERNAL void m0_dtm_op_fini(struct m0_dtm_op *op)
M0_INTERNAL void nu_unlock(struct m0_dtm_nu *nu)
M0_INTERNAL void m0_dtm_reply_unpack(struct m0_dtm_oper *oper, const struct m0_dtm_oper_descr *reply)
static uint32_t max32u(uint32_t a, uint32_t b)
M0_INTERNAL void m0_dtm_oper_close(struct m0_dtm_oper *oper)
M0_INTERNAL void m0_dtm_update_list_fini(struct m0_tl *list)
M0_INTERNAL bool op_state(const struct m0_dtm_op *op, enum m0_dtm_state state)
M0_INTERNAL void dtm_unlock(struct m0_dtm *dtm)
M0_INTERNAL void m0_dtm_update_pack(const struct m0_dtm_update *update, struct m0_dtm_update_descr *updd)
M0_INTERNAL void m0_dtm_oper_fini(struct m0_dtm_oper *oper)
M0_INTERNAL void oper_print(const struct m0_dtm_oper *oper)
M0_INTERNAL void m0_dtm_update_list_init(struct m0_tl *list)
struct m0_dtm_oper_updates od_updates
static struct m0_dtm_oper_descr reply
static int scan(struct scanner *s)
M0_INTERNAL bool m0_dtm_oper_invariant(const struct m0_dtm_oper *oper)
#define m0_tl_for(name, head, obj)
M0_INTERNAL void advance_try(const struct m0_dtm_op *op)
M0_INTERNAL void oper_lock(const struct m0_dtm_oper *oper)
static uint64_t max64u(uint64_t a, uint64_t b)
M0_INTERNAL void m0_dtm_reply_pack(const struct m0_dtm_oper *oper, const struct m0_dtm_oper_descr *request, struct m0_dtm_oper_descr *reply)
#define m0_tl_forall(name, var, head,...)
#define M0_IMPOSSIBLE(fmt,...)