Motr  M0
ulnet_core.c File Reference
#include <sys/types.h>
#include <sys/stat.h>
#include <sys/ioctl.h>
#include <fcntl.h>
#include <unistd.h>
#include "lib/errno.h"
Include dependency graph for ulnet_core.c:

Go to the source code of this file.

Macros

#define NLX_IP_SET(f)   ud->ud_##f = ip.ddi_##f
 
#define NLX_UCORE_BUF_OP(op, loc, ...)
 

Functions

static bool nlx_ucore_domain_invariant (const struct nlx_ucore_domain *ud)
 
static bool nlx_ucore_buffer_invariant (const struct nlx_ucore_buffer *ub)
 
static bool nlx_ucore_tm_invariant (const struct nlx_ucore_transfer_mc *utm)
 
M0_INTERNAL void * nlx_core_mem_alloc (size_t size, unsigned shift)
 
M0_INTERNAL void nlx_core_mem_free (void *data, size_t size, unsigned shift)
 
static int nlx_ucore_ioctl (int fd, unsigned long cmd, void *arg)
 
static int nlx_ucore_nidstrs_get (struct nlx_ucore_domain *ud, char ***nidary)
 
static void nlx_ucore_nidstrs_put (struct nlx_ucore_domain *ud, char ***nidary)
 
M0_INTERNAL int nlx_core_dom_init (struct m0_net_domain *dom, struct nlx_core_domain *cd)
 
M0_INTERNAL void nlx_core_dom_fini (struct nlx_core_domain *cd)
 
M0_INTERNAL m0_bcount_t nlx_core_get_max_buffer_size (struct nlx_core_domain *cd)
 
M0_INTERNAL m0_bcount_t nlx_core_get_max_buffer_segment_size (struct nlx_core_domain *cd)
 
M0_INTERNAL int32_t nlx_core_get_max_buffer_segments (struct nlx_core_domain *cd)
 
M0_INTERNAL int nlx_core_buf_register (struct nlx_core_domain *cd, nlx_core_opaque_ptr_t buffer_id, const struct m0_bufvec *bvec, struct nlx_core_buffer *cb)
 
M0_INTERNAL void nlx_core_buf_deregister (struct nlx_core_domain *cd, struct nlx_core_buffer *cb)
 
M0_INTERNAL int nlx_core_buf_msg_recv (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, struct nlx_core_buffer *cb)
 
M0_INTERNAL int nlx_core_buf_msg_send (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, struct nlx_core_buffer *cb)
 
M0_INTERNAL int nlx_core_buf_active_recv (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, struct nlx_core_buffer *cb)
 
M0_INTERNAL int nlx_core_buf_active_send (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, struct nlx_core_buffer *cb)
 
M0_INTERNAL int nlx_core_buf_passive_recv (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, struct nlx_core_buffer *cb)
 
M0_INTERNAL int nlx_core_buf_passive_send (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, struct nlx_core_buffer *cb)
 
M0_INTERNAL int nlx_core_buf_del (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, struct nlx_core_buffer *cb)
 
int nlx_core_buf_event_wait (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, m0_time_t timeout)
 
M0_INTERNAL int nlx_core_nidstr_decode (struct nlx_core_domain *cd, const char *nidstr, uint64_t *nid)
 
M0_INTERNAL int nlx_core_nidstr_encode (struct nlx_core_domain *cd, uint64_t nid, char nidstr[M0_NET_LNET_NIDSTR_SIZE])
 
M0_INTERNAL int nlx_core_nidstrs_get (struct nlx_core_domain *cd, char ***nidary)
 
M0_INTERNAL void nlx_core_nidstrs_put (struct nlx_core_domain *cd, char ***nidary)
 
static void nlx_ucore_tm_stop (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm)
 
M0_INTERNAL int nlx_core_tm_start (struct nlx_core_domain *cd, struct m0_net_transfer_mc *tm, struct nlx_core_transfer_mc *ctm)
 
M0_INTERNAL void nlx_core_tm_stop (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm)
 
M0_INTERNAL int nlx_core_new_blessed_bev (struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, struct nlx_core_buffer_event **bevp)
 
static void nlx_core_fini (void)
 
static int nlx_core_init (void)
 

Variables

static const char * nlx_ucore_dev_name = "/dev/" M0_LNET_DEV
 
static unsigned nlx_ucore_nidstrs_thunk = 128
 

Macro Definition Documentation

◆ NLX_IP_SET

#define NLX_IP_SET (   f)    ud->ud_##f = ip.ddi_##f