Motr  M0
packet.c File Reference
#include "lib/vec.h"
#include "lib/memory.h"
#include "lib/misc.h"
#include "lib/arith.h"
#include "lib/finject.h"
#include "ut/ut.h"
#include "motr/init.h"
#include "motr/magic.h"
#include "fop/fop.h"
#include "rpc/rpc.h"
#include "rpc/rpc_internal.h"
#include "rpc/rpc_opcodes.h"
#include "rpc/it/ping_fop.h"
#include "rpc/it/ping_fop_xc.h"
#include "rpc/it/ping_fop_xc.c"
#include "rpc/it/ping_fom.c"
#include "rpc/it/ping_fop.c"
Include dependency graph for packet.c:

Go to the source code of this file.

Macros

#define cmp_field(obj1, obj2, field)   ((obj1)->field == (obj2)->field)
 

Functions

static struct m0_rpc_itemprepare_ping_fop_item (void)
 
static struct m0_rpc_itemprepare_ping_rep_fop_item (void)
 
static void fill_ping_fop_data (struct m0_fop_ping_arr *fp_arr)
 
static void populate_item (struct m0_rpc_item *item)
 
static void packet_compare (struct m0_rpc_packet *p1, struct m0_rpc_packet *p2)
 
static void item_compare (struct m0_rpc_item *item1, struct m0_rpc_item *item2)
 
static void fop_data_compare (struct m0_fop *fop1, struct m0_fop *fop2)
 
static void cmp_ping_fop_data (struct m0_fop_ping_arr *fp_arr1, struct m0_fop_ping_arr *fp_arr2)
 
static void packet_fini (struct m0_rpc_packet *packet)
 
static int packet_encdec_ut_init (void)
 
static int packet_encdec_ut_fini (void)
 
static void test_packet_encode_decode (void)
 

Variables

static struct m0_rpc_machine rmachine
 
struct m0_ut_suite packet_encdec_ut
 

Macro Definition Documentation

◆ cmp_field

#define cmp_field (   obj1,
  obj2,
  field 
)    ((obj1)->field == (obj2)->field)

Definition at line 40 of file packet.c.

Function Documentation

◆ cmp_ping_fop_data()

static void cmp_ping_fop_data ( struct m0_fop_ping_arr fp_arr1,
struct m0_fop_ping_arr fp_arr2 
)
static

Definition at line 237 of file packet.c.

Here is the caller graph for this function:

◆ fill_ping_fop_data()

static void fill_ping_fop_data ( struct m0_fop_ping_arr fp_arr)
static

Definition at line 155 of file packet.c.

Here is the caller graph for this function:

◆ fop_data_compare()

static void fop_data_compare ( struct m0_fop fop1,
struct m0_fop fop2 
)
static

Definition at line 210 of file packet.c.

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

◆ item_compare()

static void item_compare ( struct m0_rpc_item item1,
struct m0_rpc_item item2 
)
static

Definition at line 200 of file packet.c.

Here is the caller graph for this function:

◆ packet_compare()

static void packet_compare ( struct m0_rpc_packet p1,
struct m0_rpc_packet p2 
)
static

Definition at line 178 of file packet.c.

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

◆ packet_encdec_ut_fini()

static int packet_encdec_ut_fini ( void  )
static

Definition at line 62 of file packet.c.

Here is the call graph for this function:

◆ packet_encdec_ut_init()

static int packet_encdec_ut_init ( void  )
static

Definition at line 55 of file packet.c.

Here is the call graph for this function:

◆ packet_fini()

static void packet_fini ( struct m0_rpc_packet packet)
static

Definition at line 247 of file packet.c.

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

◆ populate_item()

static void populate_item ( struct m0_rpc_item item)
static

Definition at line 167 of file packet.c.

Here is the caller graph for this function:

◆ prepare_ping_fop_item()

static struct m0_rpc_item * prepare_ping_fop_item ( void  )
static

Definition at line 121 of file packet.c.

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

◆ prepare_ping_rep_fop_item()

static struct m0_rpc_item * prepare_ping_rep_fop_item ( void  )
static

Definition at line 140 of file packet.c.

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

◆ test_packet_encode_decode()

static void test_packet_encode_decode ( void  )
static

Definition at line 69 of file packet.c.

Here is the call graph for this function:

Variable Documentation

◆ packet_encdec_ut

struct m0_ut_suite packet_encdec_ut
Initial value:
= {
.ts_name = "rpc-packet-encdec-ut",
.ts_tests = {
{ "packet-encode-decode-test", test_packet_encode_decode},
{ NULL, NULL}
}
}
#define NULL
Definition: misc.h:38
static void test_packet_encode_decode(void)
Definition: packet.c:69
static int packet_encdec_ut_init(void)
Definition: packet.c:55
static int packet_encdec_ut_fini(void)
Definition: packet.c:62

Definition at line 259 of file packet.c.

◆ rmachine

struct m0_rpc_machine rmachine
static

Definition at line 42 of file packet.c.