Motr  M0
ag.c File Reference
#include "lib/trace.h"
#include "lib/string.h"
#include "lib/misc.h"
#include "lib/errno.h"
#include "motr/magic.h"
#include "cm/sw.h"
#include "cm/proxy.h"
#include "cm/ag.h"
#include "cm/cm.h"
#include "cm/cp.h"
Include dependency graph for ag.c:

Go to the source code of this file.

Macros

#define M0_TRACE_SUBSYSTEM   M0_TRACE_SUBSYS_CM
 

Functions

 M0_TL_DESCR_DEFINE (aggr_grps_in, "aggregation groups incoming", M0_INTERNAL, struct m0_cm_aggr_group, cag_cm_in_linkage, cag_magic, CM_AG_LINK_MAGIX, CM_AG_HEAD_MAGIX)
 
 M0_TL_DEFINE (aggr_grps_in, M0_INTERNAL, struct m0_cm_aggr_group)
 
 M0_TL_DESCR_DEFINE (aggr_grps_out, "aggregation groups outgoing", M0_INTERNAL, struct m0_cm_aggr_group, cag_cm_out_linkage, cag_magic, CM_AG_LINK_MAGIX, CM_AG_HEAD_MAGIX)
 
 M0_TL_DEFINE (aggr_grps_out, M0_INTERNAL, struct m0_cm_aggr_group)
 
 M0_BOB_DEFINE (static M0_UNUSED, &ag_bob, m0_cm_aggr_group)
 
M0_INTERNAL void m0_cm_ag_lock (struct m0_cm_aggr_group *ag)
 
M0_INTERNAL void m0_cm_ag_unlock (struct m0_cm_aggr_group *ag)
 
M0_INTERNAL bool m0_cm_ag_is_locked (struct m0_cm_aggr_group *ag)
 
M0_INTERNAL int m0_cm_ag_id_cmp (const struct m0_cm_ag_id *id0, const struct m0_cm_ag_id *id1)
 
M0_INTERNAL void m0_cm_ag_id_copy (struct m0_cm_ag_id *dst, const struct m0_cm_ag_id *src)
 
M0_INTERNAL bool m0_cm_ag_id_is_set (const struct m0_cm_ag_id *id)
 
static void _fini_ast_cb (struct m0_sm_group *grp, struct m0_sm_ast *ast)
 
M0_INTERNAL void m0_cm_aggr_group_init (struct m0_cm_aggr_group *ag, struct m0_cm *cm, const struct m0_cm_ag_id *id, bool has_incoming, const struct m0_cm_aggr_group_ops *ag_ops)
 
M0_INTERNAL void m0_cm_aggr_group_fini (struct m0_cm_aggr_group *ag)
 
M0_INTERNAL void m0_cm_aggr_group_fini_and_progress (struct m0_cm_aggr_group *ag)
 
static struct m0_cm_aggr_group__aggr_group_locate (const struct m0_cm_ag_id *id, const struct m0_tl_descr *descr, struct m0_tl *head)
 
M0_INTERNAL struct m0_cm_aggr_groupm0_cm_aggr_group_locate (struct m0_cm *cm, const struct m0_cm_ag_id *id, bool has_incoming)
 
static void __aggr_group_add (struct m0_cm_aggr_group *ag, const struct m0_tl_descr *descr, struct m0_tl *head)
 
M0_INTERNAL void m0_cm_aggr_group_add (struct m0_cm *cm, struct m0_cm_aggr_group *ag, bool has_incoming)
 
M0_INTERNAL int m0_cm_aggr_group_alloc (struct m0_cm *cm, const struct m0_cm_ag_id *id, bool has_incoming, struct m0_cm_aggr_group **out)
 
M0_INTERNAL bool m0_cm_aggr_group_tlists_are_empty (struct m0_cm *cm)
 
M0_INTERNAL int m0_cm_ag_advance (struct m0_cm *cm)
 
M0_INTERNAL struct m0_cm_aggr_groupm0_cm_ag_in_hi (const struct m0_cm *cm)
 
M0_INTERNAL struct m0_cm_aggr_groupm0_cm_ag_in_lo (const struct m0_cm *cm)
 
M0_INTERNAL struct m0_cm_aggr_groupm0_cm_ag_out_lo (const struct m0_cm *cm)
 
M0_INTERNAL struct m0_cm_aggr_groupm0_cm_ag_out_hi (const struct m0_cm *cm)
 
M0_INTERNAL void m0_cm_ag_in_interval (const struct m0_cm *cm, struct m0_cm_sw *in_interval)
 
M0_INTERNAL void m0_cm_ag_out_interval (const struct m0_cm *cm, struct m0_cm_sw *out_interval)
 
static void cm_ag_get (struct m0_cm_aggr_group *ag)
 
static void cm_ag_put (struct m0_cm_aggr_group *ag)
 
M0_INTERNAL void m0_cm_ag_get (struct m0_cm_aggr_group *ag)
 
M0_INTERNAL void m0_cm_ag_put (struct m0_cm_aggr_group *ag)
 
M0_INTERNAL void m0_cm_ag_cp_add_locked (struct m0_cm_aggr_group *ag, struct m0_cm_cp *cp)
 
M0_INTERNAL void m0_cm_ag_cp_add (struct m0_cm_aggr_group *ag, struct m0_cm_cp *cp)
 
M0_INTERNAL void m0_cm_ag_cp_del (struct m0_cm_aggr_group *ag, struct m0_cm_cp *cp)
 
M0_INTERNAL void m0_cm_ag_fini_post (struct m0_cm_aggr_group *ag)
 
M0_INTERNAL bool m0_cm_ag_can_fini (struct m0_cm_aggr_group *ag)
 

Variables

struct m0_bob_type ag_bob
 

Macro Definition Documentation

◆ M0_TRACE_SUBSYSTEM

#define M0_TRACE_SUBSYSTEM   M0_TRACE_SUBSYS_CM

Definition at line 23 of file ag.c.

Function Documentation

◆ __aggr_group_add()

static void __aggr_group_add ( struct m0_cm_aggr_group ag,
const struct m0_tl_descr descr,
struct m0_tl head 
)
static

Definition at line 282 of file ag.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ __aggr_group_locate()

static struct m0_cm_aggr_group* __aggr_group_locate ( const struct m0_cm_ag_id id,
const struct m0_tl_descr descr,
struct m0_tl head 
)
static

Definition at line 244 of file ag.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ _fini_ast_cb()

static void _fini_ast_cb ( struct m0_sm_group grp,
struct m0_sm_ast ast 
)
static

Definition at line 104 of file ag.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ cm_ag_get()

static void cm_ag_get ( struct m0_cm_aggr_group ag)
static

Definition at line 472 of file ag.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ cm_ag_put()

static void cm_ag_put ( struct m0_cm_aggr_group ag)
static

Definition at line 479 of file ag.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ M0_BOB_DEFINE()

M0_BOB_DEFINE ( static  M0_UNUSED,
ag_bob,
m0_cm_aggr_group   
)

◆ M0_TL_DEFINE() [1/2]

M0_TL_DEFINE ( aggr_grps_in  ,
M0_INTERNAL  ,
struct m0_cm_aggr_group   
)

◆ M0_TL_DEFINE() [2/2]

M0_TL_DEFINE ( aggr_grps_out  ,
M0_INTERNAL  ,
struct m0_cm_aggr_group   
)

◆ M0_TL_DESCR_DEFINE() [1/2]

M0_TL_DESCR_DEFINE ( aggr_grps_in  ,
"aggregation groups incoming"  ,
M0_INTERNAL  ,
struct m0_cm_aggr_group  ,
cag_cm_in_linkage  ,
cag_magic  ,
CM_AG_LINK_MAGIX  ,
CM_AG_HEAD_MAGIX   
)

◆ M0_TL_DESCR_DEFINE() [2/2]

M0_TL_DESCR_DEFINE ( aggr_grps_out  ,
"aggregation groups outgoing"  ,
M0_INTERNAL  ,
struct m0_cm_aggr_group  ,
cag_cm_out_linkage  ,
cag_magic  ,
CM_AG_LINK_MAGIX  ,
CM_AG_HEAD_MAGIX   
)

Variable Documentation

◆ ag_bob

struct m0_bob_type ag_bob

Definition at line 54 of file ag.c.