Motr  M0
link_ut.c File Reference
#include "ut/ut.h"
#include "lib/finject.h"
#include "lib/memory.h"
#include "lib/trace.h"
#include "reqh/reqh.h"
#include "rpc/session.h"
#include "rpc/rpc_opcodes.h"
#include "net/lnet/lnet.h"
#include "rpc/link.h"
#include "rpc/rpc.h"
#include "fop/fop.h"
#include "sss/ss_fops.h"
#include "ha/ut/helper.h"
#include "rpc/ut/clnt_srv_ctx.c"
Include dependency graph for link_ut.c:

Go to the source code of this file.

Enumerations

enum  { RLUT_MAX_RPCS_IN_FLIGHT = 10, RLUT_CONN_TIMEOUT = 40, RLUT_SESS_TIMEOUT = 20 }
 

Functions

static void rlut_init (struct m0_net_domain *net_dom, struct m0_net_buffer_pool *buf_pool, struct m0_reqh *reqh, struct m0_rpc_machine *rmachine)
 
static void rlut_fini (struct m0_net_domain *net_dom, struct m0_net_buffer_pool *buf_pool, struct m0_reqh *reqh, struct m0_rpc_machine *rmachine)
 
static void rlut_remote_unreachable (void)
 
static void rlut_reconnect (void)
 
static void rlut_remote_delay (void)
 
static void rlut_reset (void)
 
static struct m0_foput_fop_alloc (const char *name, uint32_t cmd)
 
static void ut_req (struct m0_rpc_session *sess, const char *name, uint32_t cmd)
 
void rlut_connect_async ()
 

Variables

struct m0_clink clink
 
uint32_t m0_rpc__filter_opcode [4]
 
struct m0_ut_suite link_lib_ut
 

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
RLUT_MAX_RPCS_IN_FLIGHT 
RLUT_CONN_TIMEOUT 
RLUT_SESS_TIMEOUT 

Definition at line 39 of file link_ut.c.

Function Documentation

◆ rlut_connect_async()

void rlut_connect_async ( )

Definition at line 358 of file link_ut.c.

Here is the call graph for this function:

◆ rlut_fini()

static void rlut_fini ( struct m0_net_domain net_dom,
struct m0_net_buffer_pool buf_pool,
struct m0_reqh reqh,
struct m0_rpc_machine rmachine 
)
static

Definition at line 90 of file link_ut.c.

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

◆ rlut_init()

static void rlut_init ( struct m0_net_domain net_dom,
struct m0_net_buffer_pool buf_pool,
struct m0_reqh reqh,
struct m0_rpc_machine rmachine 
)
static

Definition at line 47 of file link_ut.c.

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

◆ rlut_reconnect()

static void rlut_reconnect ( void  )
static

Definition at line 132 of file link_ut.c.

Here is the call graph for this function:

◆ rlut_remote_delay()

static void rlut_remote_delay ( void  )
static

Definition at line 186 of file link_ut.c.

Here is the call graph for this function:

◆ rlut_remote_unreachable()

static void rlut_remote_unreachable ( void  )
static

Definition at line 102 of file link_ut.c.

Here is the call graph for this function:

◆ rlut_reset()

static void rlut_reset ( void  )
static

Definition at line 267 of file link_ut.c.

Here is the call graph for this function:

◆ ut_fop_alloc()

static struct m0_fop* ut_fop_alloc ( const char *  name,
uint32_t  cmd 
)
static

Definition at line 326 of file link_ut.c.

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

◆ ut_req()

static void ut_req ( struct m0_rpc_session sess,
const char *  name,
uint32_t  cmd 
)
static

Definition at line 346 of file link_ut.c.

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

Variable Documentation

◆ clink

struct m0_clink clink

Definition at line 45 of file link_ut.c.

◆ link_lib_ut

struct m0_ut_suite link_lib_ut
Initial value:
= {
.ts_name = "rpc-link-ut",
.ts_tests = {
{ "remote-unreacheable", rlut_remote_unreachable },
{ "reconnect", rlut_reconnect },
{ "remote-delay", rlut_remote_delay },
{ "reset", rlut_reset },
{ "connect-async", rlut_connect_async },
{ NULL, NULL }
}
}
#define NULL
Definition: misc.h:38

Definition at line 405 of file link_ut.c.