22 #define M0_TRACE_SUBSYSTEM M0_TRACE_SUBSYS_DTM 132 struct m0_buf temp_buf = {};
177 struct m0_buf empty_buf = {};
619 #undef M0_TRACE_SUBSYSTEM static int ut_dl_init(struct m0_dtm0_tx_desc *txd, struct m0_buf *buf, int rand)
static void tid_init(struct m0_dtm0_tid *tid, int rand)
M0_INTERNAL int m0_dtm0_tx_desc_init(struct m0_dtm0_tx_desc *td, uint32_t nr_pa)
void m0_be_ut_seg_fini(struct m0_be_ut_seg *ut_seg)
static bool txd_check(const struct m0_dtm0_tx_desc *txd, int rand)
M0_INTERNAL void m0_mutex_unlock(struct m0_mutex *mutex)
static void p_state_set(struct m0_dtm0_tx_pa *pa, uint32_t state)
void m0_be_ut_seg_reload(struct m0_be_ut_seg *ut_seg)
M0_INTERNAL bool m0_be_dtm0_plog_can_prune(struct m0_be_dtm0_log *log, const struct m0_dtm0_tid *id, struct m0_be_tx_credit *accum)
M0_INTERNAL void m0_be_dtm0_log_free(struct m0_be_dtm0_log **in_log)
M0_INTERNAL bool m0_buf_eq(const struct m0_buf *x, const struct m0_buf *y)
static void txd_fini(struct m0_dtm0_tx_desc *txd)
static bool ut_dl_verify_buf(struct m0_buf *buf, int rand)
static struct m0_be_dtm0_log * persistent_log_create(void)
struct m0_be_seg * bus_seg
static void persistent_log_operate(struct m0_be_dtm0_log *log)
M0_INTERNAL void m0_be_tx_fini(struct m0_be_tx *tx)
struct m0_dtm0_tx_desc dlr_txd
M0_INTERNAL void m0_be_dtm0_log_fini(struct m0_be_dtm0_log *log)
M0_INTERNAL void m0_be_tx_prep(struct m0_be_tx *tx, const struct m0_be_tx_credit *credit)
void m0_be_ut_seg_init(struct m0_be_ut_seg *ut_seg, struct m0_be_ut_backend *ut_be, m0_bcount_t size)
static int ut_dl_init_buf(struct m0_buf *buf, int rand)
static bool ut_dl_verify_log_rec(struct m0_dtm0_log_rec *rec, int rand)
M0_INTERNAL void m0_mutex_lock(struct m0_mutex *mutex)
M0_INTERNAL int m0_fid_cmp(const struct m0_fid *fid0, const struct m0_fid *fid1)
static void ut_dl_fini_buf(struct m0_buf *buf)
M0_INTERNAL int m0_be_dtm0_plog_prune(struct m0_be_dtm0_log *log, struct m0_be_tx *tx, const struct m0_dtm0_tid *id)
struct m0_buf dlr_payload
static int txd_init(struct m0_dtm0_tx_desc *txd, int rand)
struct m0_dtm0_tid dtd_id
M0_INTERNAL void m0_fid_set(struct m0_fid *fid, uint64_t container, uint64_t key)
static void p_init(struct m0_dtm0_tx_pa *pa, int rand)
static struct m0_be_ut_backend * ut_be
static struct m0_be_seg * seg
M0_INTERNAL int m0_be_dtm0_log_init(struct m0_be_dtm0_log *log, struct m0_be_seg *seg, struct m0_dtm0_clk_src *cs, bool is_plog)
M0_INTERNAL int m0_be_dtm0_log_create(struct m0_be_tx *tx, struct m0_be_seg *seg, struct m0_be_dtm0_log **out)
M0_INTERNAL int m0_be_dtm0_log_alloc(struct m0_be_dtm0_log **out)
struct m0_ut_suite dtm0_log_ut
M0_INTERNAL int m0_be_tx_open_sync(struct m0_be_tx *tx)
static struct m0_be_ut_seg * ut_seg
void m0_be_ut_backend_init(struct m0_be_ut_backend *ut_be)
static bool tid_check(const struct m0_dtm0_tid *tid, int rand)
M0_INTERNAL int m0_buf_alloc(struct m0_buf *buf, size_t size)
static void persistent_log_destroy(struct m0_be_dtm0_log *log)
M0_INTERNAL void m0_buf_free(struct m0_buf *buf)
M0_INTERNAL int m0_be_dtm0_log_prune(struct m0_be_dtm0_log *log, struct m0_be_tx *tx, const struct m0_dtm0_tid *id)
struct m0_dtm0_tx_participants dtd_ps
#define m0_forall(var, nr,...)
struct m0_dtm0_tx_pa * dtp_pa
static void ut_dl_fini(struct m0_dtm0_tx_desc *txd, struct m0_buf *buf)
static void m0_be_ut_dtm0_log_test(void)
static void dtm0_log_check(const struct m0_be_dtm0_log *log)
M0_INTERNAL int m0_be_dtm0_log_update(struct m0_be_dtm0_log *log, struct m0_be_tx *tx, struct m0_dtm0_tx_desc *txd, struct m0_buf *payload)
M0_INTERNAL void m0_dtm0_clk_src_fini(struct m0_dtm0_clk_src *cs)
#define M0_ALLOC_PTR(ptr)
M0_INTERNAL void m0_be_dtm0_log_credit(enum m0_be_dtm0_log_credit_op op, struct m0_dtm0_tx_desc *txd, struct m0_buf *payload, struct m0_be_seg *seg, struct m0_dtm0_log_rec *rec, struct m0_be_tx_credit *accum)
void m0_be_ut_tx_init(struct m0_be_tx *tx, struct m0_be_ut_backend *ut_be)
void m0_be_ut_backend_fini(struct m0_be_ut_backend *ut_be)
struct m0_dtm0_tx_participants dtd_ps
M0_INTERNAL struct m0_dtm0_log_rec * m0_be_dtm0_log_find(struct m0_be_dtm0_log *log, const struct m0_dtm0_tid *id)
M0_INTERNAL void m0_dtm0_clk_src_init(struct m0_dtm0_clk_src *cs, enum m0_dtm0_cs_types type)
static bool p_check(const struct m0_dtm0_tx_pa *pa, int rand)
M0_INTERNAL void m0_dtm0_tx_desc_fini(struct m0_dtm0_tx_desc *td)
void test_volatile_dtm0_log(void)
struct m0_dtm0_tid dtd_id
M0_INTERNAL void m0_be_tx_close_sync(struct m0_be_tx *tx)