Motr  M0
LNet Transport XO Interface
Collaboration diagram for LNet Transport XO Interface:

Data Structures

struct  nlx_xo_interceptable_subs
 
struct  nlx_xo_ep
 
struct  nlx_xo_domain
 
struct  nlx_xo_transfer_mc
 
struct  nlx_xo_buffer
 

Macros

#define NLX_core_buf_event_wait(lcdom, lctm, timeout)   (*nlx_xo_iv._nlx_core_buf_event_wait)(lcdom, lctm, timeout)
 
#define NLX_ep_create(epp, tm, cepa)   (*nlx_xo_iv._nlx_ep_create)(epp, tm, cepa)
 
#define NLX_tm_get_buffer_timeout_tick(tm)   (*nlx_xo_iv._nlx_tm_get_buffer_timeout_tick)(tm)
 
#define NLX_tm_timeout_buffers(tm, now)   (*nlx_xo_iv._nlx_tm_timeout_buffers)(tm, now)
 

Enumerations

enum  { M0_NET_LNET_EVT_SHORT_WAIT_SECS = 1, M0_NET_LNET_EVT_LONG_WAIT_SECS = 10, M0_NET_LNET_BUF_TIMEOUT_TICK_SECS = 15 }
 

Functions

static void nlx_ep_release (struct m0_ref *ref)
 
static int nlx_ep_create (struct m0_net_end_point **epp, struct m0_net_transfer_mc *tm, const struct nlx_core_ep_addr *cepa)
 
static bool nlx_tm_invariant (const struct m0_net_transfer_mc *tm)
 
static void nlx_tm_ev_worker (struct m0_net_transfer_mc *tm)
 
static bool nlx_ep_invariant (const struct m0_net_end_point *ep)
 
static bool nlx_xo_buffer_bufvec_invariant (const struct m0_net_buffer *nb)
 
static struct nlx_core_ep_addrnlx_ep_to_core (struct m0_net_end_point *ep)
 
static int nlx_xo_core_bev_to_net_bev (struct m0_net_transfer_mc *tm, struct nlx_core_buffer_event *lcbev, struct m0_net_buffer_event *nbev)
 
static m0_time_t nlx_tm_get_buffer_timeout_tick (const struct m0_net_transfer_mc *tm)
 
static int nlx_tm_timeout_buffers (struct m0_net_transfer_mc *tm, m0_time_t now)
 
static bool all_tm_queues_are_empty (struct m0_net_transfer_mc *tm)
 
static bool nlx_dom_invariant (const struct m0_net_domain *dom)
 
static bool nlx_buffer_invariant (const struct m0_net_buffer *nb)
 
static int nlx_xo_dom_init (const struct m0_net_xprt *xprt, struct m0_net_domain *dom)
 
static void nlx_xo_dom_fini (struct m0_net_domain *dom)
 
static m0_bcount_t nlx_xo_get_max_buffer_size (const struct m0_net_domain *dom)
 
static m0_bcount_t nlx_xo_get_max_buffer_segment_size (const struct m0_net_domain *dom)
 
static int32_t nlx_xo_get_max_buffer_segments (const struct m0_net_domain *dom)
 
static int nlx_xo_end_point_create (struct m0_net_end_point **epp, struct m0_net_transfer_mc *tm, const char *addr)
 
static int nlx_xo_buf_register (struct m0_net_buffer *nb)
 
static void nlx_xo_buf_deregister (struct m0_net_buffer *nb)
 
static int nlx_xo__nbd_allocate (struct m0_net_transfer_mc *tm, const struct nlx_core_buf_desc *cbd, struct m0_net_buf_desc *nbd)
 
static int nlx_xo__nbd_recover (struct m0_net_transfer_mc *tm, const struct m0_net_buf_desc *nbd, struct nlx_core_buf_desc *cbd)
 
static int nlx_xo_buf_add (struct m0_net_buffer *nb)
 
static void nlx_xo_buf_del (struct m0_net_buffer *nb)
 
static int nlx_xo_tm_init (struct m0_net_transfer_mc *tm)
 
static void nlx_xo_tm_fini (struct m0_net_transfer_mc *tm)
 
static int nlx_xo_tm_start (struct m0_net_transfer_mc *tm, const char *addr)
 
static int nlx_xo_tm_stop (struct m0_net_transfer_mc *tm, bool cancel)
 
static int nlx_xo_tm_confine (struct m0_net_transfer_mc *tm, const struct m0_bitmap *processors)
 
static void nlx_xo_bev_deliver_all (struct m0_net_transfer_mc *tm)
 
static int nlx_xo_bev_deliver_sync (struct m0_net_transfer_mc *tm)
 
static bool nlx_xo_bev_pending (struct m0_net_transfer_mc *tm)
 
static void nlx_xo_bev_notify (struct m0_net_transfer_mc *tm, struct m0_chan *chan)
 
static m0_bcount_t nlx_xo_get_max_buffer_desc_size (const struct m0_net_domain *dom)
 
static m0_bcount_t nlx_xo_rpc_max_seg_size (struct m0_net_domain *ndom)
 
static uint32_t nlx_xo_rpc_max_segs_nr (struct m0_net_domain *ndom)
 
static m0_bcount_t nlx_xo_rpc_max_msg_size (struct m0_net_domain *ndom, m0_bcount_t rpc_size)
 
static uint32_t nlx_xo_rpc_max_recv_msgs (struct m0_net_domain *ndom, m0_bcount_t rpc_size)
 

Variables

static struct nlx_xo_interceptable_subs nlx_xo_iv
 
static const struct m0_net_xprt_ops nlx_xo_xprt_ops
 

Detailed Description

Macro Definition Documentation

◆ NLX_core_buf_event_wait

#define NLX_core_buf_event_wait (   lcdom,
  lctm,
  timeout 
)    (*nlx_xo_iv._nlx_core_buf_event_wait)(lcdom, lctm, timeout)

Definition at line 94 of file lnet_xo.c.

◆ NLX_ep_create

#define NLX_ep_create (   epp,
  tm,
  cepa 
)    (*nlx_xo_iv._nlx_ep_create)(epp, tm, cepa)

Definition at line 96 of file lnet_xo.c.

◆ NLX_tm_get_buffer_timeout_tick

#define NLX_tm_get_buffer_timeout_tick (   tm)    (*nlx_xo_iv._nlx_tm_get_buffer_timeout_tick)(tm)

Definition at line 98 of file lnet_xo.c.

◆ NLX_tm_timeout_buffers

#define NLX_tm_timeout_buffers (   tm,
  now 
)    (*nlx_xo_iv._nlx_tm_timeout_buffers)(tm, now)

Definition at line 100 of file lnet_xo.c.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
M0_NET_LNET_EVT_SHORT_WAIT_SECS 

Event thread short wait

M0_NET_LNET_EVT_LONG_WAIT_SECS 

Event thread long wait

M0_NET_LNET_BUF_TIMEOUT_TICK_SECS 

Min timeout granularity

Definition at line 43 of file lnet_xo.h.

Function Documentation

◆ all_tm_queues_are_empty()

static bool all_tm_queues_are_empty ( struct m0_net_transfer_mc tm)
inlinestatic

Definition at line 28 of file lnet_tm.c.

Here is the caller graph for this function:

◆ nlx_buffer_invariant()

static bool nlx_buffer_invariant ( const struct m0_net_buffer nb)
static

Definition at line 45 of file lnet_xo.c.

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

◆ nlx_dom_invariant()

static bool nlx_dom_invariant ( const struct m0_net_domain dom)
static

Definition at line 28 of file lnet_xo.c.

Here is the caller graph for this function:

◆ nlx_ep_create()

static int nlx_ep_create ( struct m0_net_end_point **  epp,
struct m0_net_transfer_mc tm,
const struct nlx_core_ep_addr cepa 
)
static

Definition at line 48 of file lnet_ep.c.

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

◆ nlx_ep_invariant()

static bool nlx_ep_invariant ( const struct m0_net_end_point ep)
static
Here is the caller graph for this function:

◆ nlx_ep_release()

static void nlx_ep_release ( struct m0_ref ref)
static

End point release subroutine invoked when the reference count goes to 0. Unlinks the end point from the TM, and releases the memory. Must be called holding the TM mutex.

Definition at line 33 of file lnet_ep.c.

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

◆ nlx_ep_to_core()

static struct nlx_core_ep_addr* nlx_ep_to_core ( struct m0_net_end_point ep)
inlinestatic

Inline helper to get the Core EP address pointer from an end point.

Definition at line 46 of file lnet_pvt.h.

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

◆ nlx_tm_ev_worker()

static void nlx_tm_ev_worker ( struct m0_net_transfer_mc tm)
static
Here is the caller graph for this function:

◆ nlx_tm_get_buffer_timeout_tick()

static m0_time_t nlx_tm_get_buffer_timeout_tick ( const struct m0_net_transfer_mc tm)
static

◆ nlx_tm_invariant()

static bool nlx_tm_invariant ( const struct m0_net_transfer_mc tm)
static
Here is the caller graph for this function:

◆ nlx_tm_timeout_buffers()

static int nlx_tm_timeout_buffers ( struct m0_net_transfer_mc tm,
m0_time_t  now 
)
static
Here is the caller graph for this function:

◆ nlx_xo__nbd_allocate()

static int nlx_xo__nbd_allocate ( struct m0_net_transfer_mc tm,
const struct nlx_core_buf_desc cbd,
struct m0_net_buf_desc nbd 
)
static

Helper function to allocate a network buffer descriptor. Since it is encoded in little endian format and its size is predefined, it is simply copied to allocated memory.

Definition at line 250 of file lnet_xo.c.

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

◆ nlx_xo__nbd_recover()

static int nlx_xo__nbd_recover ( struct m0_net_transfer_mc tm,
const struct m0_net_buf_desc nbd,
struct nlx_core_buf_desc cbd 
)
static

Helper function to recover the internal network buffer descriptor.

Definition at line 268 of file lnet_xo.c.

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

◆ nlx_xo_bev_deliver_all()

static void nlx_xo_bev_deliver_all ( struct m0_net_transfer_mc tm)
static

Definition at line 480 of file lnet_xo.c.

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

◆ nlx_xo_bev_deliver_sync()

static int nlx_xo_bev_deliver_sync ( struct m0_net_transfer_mc tm)
static

Definition at line 567 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_bev_notify()

static void nlx_xo_bev_notify ( struct m0_net_transfer_mc tm,
struct m0_chan chan 
)
static

Definition at line 585 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_bev_pending()

static bool nlx_xo_bev_pending ( struct m0_net_transfer_mc tm)
static

Definition at line 573 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_buf_add()

static int nlx_xo_buf_add ( struct m0_net_buffer nb)
static

Definition at line 280 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_buf_del()

static void nlx_xo_buf_del ( struct m0_net_buffer nb)
static

Definition at line 379 of file lnet_xo.c.

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

◆ nlx_xo_buf_deregister()

static void nlx_xo_buf_deregister ( struct m0_net_buffer nb)
static

Definition at line 230 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_buf_register()

static int nlx_xo_buf_register ( struct m0_net_buffer nb)
static

Definition at line 203 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_buffer_bufvec_invariant()

static bool nlx_xo_buffer_bufvec_invariant ( const struct m0_net_buffer nb)
static

◆ nlx_xo_core_bev_to_net_bev()

M0_INTERNAL int nlx_xo_core_bev_to_net_bev ( struct m0_net_transfer_mc tm,
struct nlx_core_buffer_event lcbev,
struct m0_net_buffer_event nbev 
)
static

Helper subroutine to create the network buffer event from the internal core buffer event.

Parameters
tmPointer to TM.
lcbevPointer to LNet transport core buffer event.
nbevPointer to network buffer event to fill in.
Precondition
m0_mutex_is_locked(&tm->ntm_mutex)
Postcondition
ergo(nbev->nbe_buffer->nb_flags & M0_NET_BUF_RETAIN, rc == 0 && !lcbev->cbe_unlinked);
rc == 0 || rc == -ENOMEM

Definition at line 240 of file lnet_tm.c.

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

◆ nlx_xo_dom_fini()

static void nlx_xo_dom_fini ( struct m0_net_domain dom)
static

Definition at line 130 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_dom_init()

static int nlx_xo_dom_init ( const struct m0_net_xprt xprt,
struct m0_net_domain dom 
)
static

Definition at line 103 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_end_point_create()

static int nlx_xo_end_point_create ( struct m0_net_end_point **  epp,
struct m0_net_transfer_mc tm,
const char *  addr 
)
static

Definition at line 165 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_get_max_buffer_desc_size()

static m0_bcount_t nlx_xo_get_max_buffer_desc_size ( const struct m0_net_domain dom)
static

Definition at line 601 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_get_max_buffer_segment_size()

static m0_bcount_t nlx_xo_get_max_buffer_segment_size ( const struct m0_net_domain dom)
static

Definition at line 148 of file lnet_xo.c.

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

◆ nlx_xo_get_max_buffer_segments()

static int32_t nlx_xo_get_max_buffer_segments ( const struct m0_net_domain dom)
static

Definition at line 157 of file lnet_xo.c.

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

◆ nlx_xo_get_max_buffer_size()

static m0_bcount_t nlx_xo_get_max_buffer_size ( const struct m0_net_domain dom)
static

Definition at line 140 of file lnet_xo.c.

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

◆ nlx_xo_rpc_max_msg_size()

static m0_bcount_t nlx_xo_rpc_max_msg_size ( struct m0_net_domain ndom,
m0_bcount_t  rpc_size 
)
static

Definition at line 625 of file lnet_xo.c.

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

◆ nlx_xo_rpc_max_recv_msgs()

static uint32_t nlx_xo_rpc_max_recv_msgs ( struct m0_net_domain ndom,
m0_bcount_t  rpc_size 
)
static

Definition at line 633 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_rpc_max_seg_size()

static m0_bcount_t nlx_xo_rpc_max_seg_size ( struct m0_net_domain ndom)
static

Definition at line 609 of file lnet_xo.c.

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

◆ nlx_xo_rpc_max_segs_nr()

static uint32_t nlx_xo_rpc_max_segs_nr ( struct m0_net_domain ndom)
static

Definition at line 617 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_tm_confine()

static int nlx_xo_tm_confine ( struct m0_net_transfer_mc tm,
const struct m0_bitmap processors 
)
static

Definition at line 463 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_tm_fini()

static void nlx_xo_tm_fini ( struct m0_net_transfer_mc tm)
static

Definition at line 413 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_tm_init()

static int nlx_xo_tm_init ( struct m0_net_transfer_mc tm)
static

Definition at line 393 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_tm_start()

static int nlx_xo_tm_start ( struct m0_net_transfer_mc tm,
const char *  addr 
)
static

Definition at line 431 of file lnet_xo.c.

Here is the call graph for this function:

◆ nlx_xo_tm_stop()

static int nlx_xo_tm_stop ( struct m0_net_transfer_mc tm,
bool  cancel 
)
static

Definition at line 450 of file lnet_xo.c.

Here is the call graph for this function:

Variable Documentation

◆ nlx_xo_iv

struct nlx_xo_interceptable_subs nlx_xo_iv
static
Initial value:
= {
#define _NLXIS(s)
}
#define _NLXIS(s)
static m0_time_t nlx_tm_get_buffer_timeout_tick(const struct m0_net_transfer_mc *tm)
static int nlx_ep_create(struct m0_net_end_point **epp, struct m0_net_transfer_mc *tm, const struct nlx_core_ep_addr *cepa)
Definition: lnet_ep.c:48
static int nlx_tm_timeout_buffers(struct m0_net_transfer_mc *tm, m0_time_t now)
M0_INTERNAL int nlx_core_buf_event_wait(struct nlx_core_domain *cd, struct nlx_core_transfer_mc *ctm, m0_time_t timeout)
Definition: klnet_core.c:1685

Definition at line 83 of file lnet_xo.c.

◆ nlx_xo_xprt_ops

const struct m0_net_xprt_ops nlx_xo_xprt_ops
static
Initial value:
= {
.xo_dom_init = nlx_xo_dom_init,
.xo_dom_fini = nlx_xo_dom_fini,
.xo_get_max_buffer_size = nlx_xo_get_max_buffer_size,
.xo_get_max_buffer_segment_size = nlx_xo_get_max_buffer_segment_size,
.xo_get_max_buffer_segments = nlx_xo_get_max_buffer_segments,
.xo_end_point_create = nlx_xo_end_point_create,
.xo_buf_register = nlx_xo_buf_register,
.xo_buf_deregister = nlx_xo_buf_deregister,
.xo_buf_add = nlx_xo_buf_add,
.xo_buf_del = nlx_xo_buf_del,
.xo_tm_init = nlx_xo_tm_init,
.xo_tm_fini = nlx_xo_tm_fini,
.xo_tm_start = nlx_xo_tm_start,
.xo_tm_stop = nlx_xo_tm_stop,
.xo_tm_confine = nlx_xo_tm_confine,
.xo_bev_deliver_all = nlx_xo_bev_deliver_all,
.xo_bev_deliver_sync = nlx_xo_bev_deliver_sync,
.xo_bev_pending = nlx_xo_bev_pending,
.xo_bev_notify = nlx_xo_bev_notify,
.xo_get_max_buffer_desc_size = nlx_xo_get_max_buffer_desc_size,
.xo_rpc_max_seg_size = nlx_xo_rpc_max_seg_size,
.xo_rpc_max_segs_nr = nlx_xo_rpc_max_segs_nr,
.xo_rpc_max_msg_size = nlx_xo_rpc_max_msg_size,
.xo_rpc_max_recv_msgs = nlx_xo_rpc_max_recv_msgs,
}
static m0_bcount_t nlx_xo_get_max_buffer_desc_size(const struct m0_net_domain *dom)
Definition: lnet_xo.c:601
static m0_bcount_t nlx_xo_rpc_max_seg_size(struct m0_net_domain *ndom)
Definition: lnet_xo.c:609
static int32_t nlx_xo_get_max_buffer_segments(const struct m0_net_domain *dom)
Definition: lnet_xo.c:157
static void nlx_xo_dom_fini(struct m0_net_domain *dom)
Definition: lnet_xo.c:130
static void nlx_xo_buf_deregister(struct m0_net_buffer *nb)
Definition: lnet_xo.c:230
static bool nlx_xo_bev_pending(struct m0_net_transfer_mc *tm)
Definition: lnet_xo.c:573
static m0_bcount_t nlx_xo_get_max_buffer_size(const struct m0_net_domain *dom)
Definition: lnet_xo.c:140
static int nlx_xo_tm_confine(struct m0_net_transfer_mc *tm, const struct m0_bitmap *processors)
Definition: lnet_xo.c:463
static int nlx_xo_tm_init(struct m0_net_transfer_mc *tm)
Definition: lnet_xo.c:393
static void nlx_xo_bev_deliver_all(struct m0_net_transfer_mc *tm)
Definition: lnet_xo.c:480
static uint32_t nlx_xo_rpc_max_recv_msgs(struct m0_net_domain *ndom, m0_bcount_t rpc_size)
Definition: lnet_xo.c:633
static uint32_t nlx_xo_rpc_max_segs_nr(struct m0_net_domain *ndom)
Definition: lnet_xo.c:617
static int nlx_xo_buf_add(struct m0_net_buffer *nb)
Definition: lnet_xo.c:280
static int nlx_xo_end_point_create(struct m0_net_end_point **epp, struct m0_net_transfer_mc *tm, const char *addr)
Definition: lnet_xo.c:165
static int nlx_xo_buf_register(struct m0_net_buffer *nb)
Definition: lnet_xo.c:203
static m0_bcount_t nlx_xo_rpc_max_msg_size(struct m0_net_domain *ndom, m0_bcount_t rpc_size)
Definition: lnet_xo.c:625
static void nlx_xo_buf_del(struct m0_net_buffer *nb)
Definition: lnet_xo.c:379
static int nlx_xo_bev_deliver_sync(struct m0_net_transfer_mc *tm)
Definition: lnet_xo.c:567
static m0_bcount_t nlx_xo_get_max_buffer_segment_size(const struct m0_net_domain *dom)
Definition: lnet_xo.c:148
static int nlx_xo_tm_stop(struct m0_net_transfer_mc *tm, bool cancel)
Definition: lnet_xo.c:450
static int nlx_xo_tm_start(struct m0_net_transfer_mc *tm, const char *addr)
Definition: lnet_xo.c:431
static int nlx_xo_dom_init(const struct m0_net_xprt *xprt, struct m0_net_domain *dom)
Definition: lnet_xo.c:103
static void nlx_xo_bev_notify(struct m0_net_transfer_mc *tm, struct m0_chan *chan)
Definition: lnet_xo.c:585
static void nlx_xo_tm_fini(struct m0_net_transfer_mc *tm)
Definition: lnet_xo.c:413

Definition at line 642 of file lnet_xo.c.