Motr  M0
xcode_xc.c File Reference
#include "lib/misc.h"
#include "lib/assert.h"
#include "xcode/xcode.h"
#include "net/sock/xcode.h"
#include "net/sock/xcode_xc.h"
Include dependency graph for xcode_xc.c:

Go to the source code of this file.

Data Structures

struct  _addrdata_s
 
struct  _addr_s
 
struct  _bdesc_s
 
struct  _packet_s
 

Functions

 M0_BASSERT (offsetof(struct _addrdata_s, _child[0])==offsetof(struct m0_xcode_type, xct_child[0]))
 
 M0_BASSERT (offsetof(struct _addr_s, _child[0])==offsetof(struct m0_xcode_type, xct_child[0]))
 
 M0_BASSERT (offsetof(struct _bdesc_s, _child[0])==offsetof(struct m0_xcode_type, xct_child[0]))
 
 M0_BASSERT (offsetof(struct _packet_s, _child[0])==offsetof(struct m0_xcode_type, xct_child[0]))
 
 M0_BASSERT (sizeof(struct addrdata)==16U)
 
 M0_BASSERT (sizeof((struct addrdata *) 0) ->v_data==16U)
 
 M0_BASSERT (offsetof(struct addrdata, v_data)==0U)
 
 M0_BASSERT (sizeof(struct addr)==32U)
 
 M0_BASSERT (sizeof((struct addr *) 0) ->a_family==4U)
 
 M0_BASSERT (offsetof(struct addr, a_family)==0U)
 
 M0_BASSERT (offsetof(struct addr, a_socktype)==4U)
 
 M0_BASSERT (offsetof(struct addr, a_protocol)==8U)
 
 M0_BASSERT (offsetof(struct addr, a_port)==12U)
 
 M0_BASSERT (offsetof(struct addr, a_data)==16U)
 
 M0_BASSERT (sizeof(struct bdesc)==48U)
 
 M0_BASSERT (sizeof((struct bdesc *) 0) ->bd_addr==32U)
 
 M0_BASSERT (offsetof(struct bdesc, bd_addr)==0U)
 
 M0_BASSERT (offsetof(struct bdesc, bd_cookie)==32U)
 
 M0_BASSERT (sizeof(struct packet)==160U)
 
 M0_BASSERT (sizeof((struct packet *) 0) ->p_header==16U)
 
 M0_BASSERT (offsetof(struct packet, p_header)==0U)
 
 M0_BASSERT (offsetof(struct packet, p_src)==16U)
 
 M0_BASSERT (offsetof(struct packet, p_dst)==64U)
 
 M0_BASSERT (offsetof(struct packet, p_idx)==112U)
 
 M0_BASSERT (offsetof(struct packet, p_nr)==116U)
 
 M0_BASSERT (offsetof(struct packet, p_size)==120U)
 
 M0_BASSERT (offsetof(struct packet, p_offset)==128U)
 
 M0_BASSERT (offsetof(struct packet, p_totalsize)==136U)
 
 M0_BASSERT (offsetof(struct packet, p_footer)==144U)
 
M0_INTERNAL void m0_xc_addrdata_struct_init (void)
 
M0_INTERNAL void m0_xc_addr_struct_init (void)
 
M0_INTERNAL void m0_xc_bdesc_struct_init (void)
 
M0_INTERNAL void m0_xc_packet_struct_init (void)
 
M0_INTERNAL void m0_xc_net_sock_xcode_init (void)
 
M0_INTERNAL void m0_xc_net_sock_xcode_fini (void)
 

Variables

struct m0_xcode_typeaddrdata_xc = &_addrdata._type
 
struct m0_xcode_typeaddr_xc = &_addr._type
 
struct m0_xcode_typebdesc_xc = &_bdesc._type
 
struct m0_xcode_typepacket_xc = &_packet._type
 
static struct _addrdata_s _addrdata
 
static struct _addr_s _addr
 
static struct _bdesc_s _bdesc
 
static struct _packet_s _packet
 

Function Documentation

◆ M0_BASSERT() [1/29]

M0_BASSERT ( offsetof(struct _addrdata_s, _child[0])  = =offsetof(struct m0_xcode_type, xct_child[0]))

◆ M0_BASSERT() [2/29]

M0_BASSERT ( offsetof(struct _addr_s, _child[0])  = =offsetof(struct m0_xcode_type, xct_child[0]))

◆ M0_BASSERT() [3/29]

M0_BASSERT ( offsetof(struct _bdesc_s, _child[0])  = =offsetof(struct m0_xcode_type, xct_child[0]))

◆ M0_BASSERT() [4/29]

M0_BASSERT ( offsetof(struct _packet_s, _child[0])  = =offsetof(struct m0_xcode_type, xct_child[0]))

◆ M0_BASSERT() [5/29]

M0_BASSERT ( sizeof(struct addrdata = =16U)

◆ M0_BASSERT() [6/29]

M0_BASSERT ( sizeof((struct addrdata *) 0) ->  v_data = =16U)

◆ M0_BASSERT() [7/29]

M0_BASSERT ( offsetof(struct addrdata, v_data = =0U)

◆ M0_BASSERT() [8/29]

M0_BASSERT ( sizeof(struct addr = =32U)

◆ M0_BASSERT() [9/29]

M0_BASSERT ( sizeof((struct addr *) 0) ->  a_family = =4U)

◆ M0_BASSERT() [10/29]

M0_BASSERT ( offsetof(struct addr, a_family = =0U)

◆ M0_BASSERT() [11/29]

M0_BASSERT ( offsetof(struct addr, a_socktype = =4U)

◆ M0_BASSERT() [12/29]

M0_BASSERT ( offsetof(struct addr, a_protocol = =8U)

◆ M0_BASSERT() [13/29]

M0_BASSERT ( offsetof(struct addr, a_port = =12U)

◆ M0_BASSERT() [14/29]

M0_BASSERT ( offsetof(struct addr, a_data = =16U)

◆ M0_BASSERT() [15/29]

M0_BASSERT ( sizeof(struct bdesc = =48U)

◆ M0_BASSERT() [16/29]

M0_BASSERT ( sizeof((struct bdesc *) 0) ->  bd_addr = =32U)

◆ M0_BASSERT() [17/29]

M0_BASSERT ( offsetof(struct bdesc, bd_addr = =0U)

◆ M0_BASSERT() [18/29]

M0_BASSERT ( offsetof(struct bdesc, bd_cookie = =32U)

◆ M0_BASSERT() [19/29]

M0_BASSERT ( sizeof(struct packet = =160U)

◆ M0_BASSERT() [20/29]

M0_BASSERT ( sizeof((struct packet *) 0) ->  p_header = =16U)

◆ M0_BASSERT() [21/29]

M0_BASSERT ( offsetof(struct packet, p_header = =0U)

◆ M0_BASSERT() [22/29]

M0_BASSERT ( offsetof(struct packet, p_src = =16U)

◆ M0_BASSERT() [23/29]

M0_BASSERT ( offsetof(struct packet, p_dst = =64U)

◆ M0_BASSERT() [24/29]

M0_BASSERT ( offsetof(struct packet, p_idx = =112U)

◆ M0_BASSERT() [25/29]

M0_BASSERT ( offsetof(struct packet, p_nr = =116U)

◆ M0_BASSERT() [26/29]

M0_BASSERT ( offsetof(struct packet, p_size = =120U)

◆ M0_BASSERT() [27/29]

M0_BASSERT ( offsetof(struct packet, p_offset = =128U)

◆ M0_BASSERT() [28/29]

M0_BASSERT ( offsetof(struct packet, p_totalsize = =136U)

◆ M0_BASSERT() [29/29]

M0_BASSERT ( offsetof(struct packet, p_footer = =144U)

◆ m0_xc_addr_struct_init()

M0_INTERNAL void m0_xc_addr_struct_init ( void  )

Definition at line 152 of file xcode_xc.c.

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

◆ m0_xc_addrdata_struct_init()

M0_INTERNAL void m0_xc_addrdata_struct_init ( void  )

Definition at line 132 of file xcode_xc.c.

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

◆ m0_xc_bdesc_struct_init()

M0_INTERNAL void m0_xc_bdesc_struct_init ( void  )

Definition at line 232 of file xcode_xc.c.

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

◆ m0_xc_net_sock_xcode_fini()

M0_INTERNAL void m0_xc_net_sock_xcode_fini ( void  )

Definition at line 415 of file xcode_xc.c.

◆ m0_xc_net_sock_xcode_init()

M0_INTERNAL void m0_xc_net_sock_xcode_init ( void  )

Definition at line 407 of file xcode_xc.c.

Here is the call graph for this function:

◆ m0_xc_packet_struct_init()

M0_INTERNAL void m0_xc_packet_struct_init ( void  )

Definition at line 267 of file xcode_xc.c.

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

Variable Documentation

◆ _addr

struct _addr_s _addr
static
Initial value:
= {
._type = {
.xct_aggr = M0_XA_RECORD,
.xct_name = "addr",
.xct_sizeof = sizeof (struct addr),
.xct_nr = 5,
}
}
Definition: xcode.h:73

◆ _addrdata

struct _addrdata_s _addrdata
static
Initial value:
= {
._type = {
.xct_aggr = M0_XA_ARRAY,
.xct_name = "addrdata",
.xct_sizeof = sizeof (struct addrdata),
.xct_nr = 1,
}
}
Definition: xcode.h:68

◆ _bdesc

struct _bdesc_s _bdesc
static
Initial value:
= {
._type = {
.xct_aggr = M0_XA_RECORD,
.xct_name = "bdesc",
.xct_sizeof = sizeof (struct bdesc),
.xct_nr = 2,
}
}
Definition: xcode.h:89

◆ _packet

struct _packet_s _packet
static
Initial value:
= {
._type = {
.xct_aggr = M0_XA_RECORD,
.xct_name = "packet",
.xct_sizeof = sizeof (struct packet),
.xct_nr = 9,
}
}
Definition: xcode.h:95

◆ addr_xc

struct m0_xcode_type * addr_xc = &_addr._type

Definition at line 11 of file xcode_xc.c.

◆ addrdata_xc

struct m0_xcode_type * addrdata_xc = &_addrdata._type

Definition at line 10 of file xcode_xc.c.

◆ bdesc_xc

struct m0_xcode_type * bdesc_xc = &_bdesc._type

Definition at line 12 of file xcode_xc.c.

◆ packet_xc

struct m0_xcode_type * packet_xc = &_packet._type

Definition at line 13 of file xcode_xc.c.