OpenSDN source code
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ksync_sock.h File Reference
#include <vector>
#include <boost/asio.hpp>
#include <boost/asio/buffer.hpp>
#include <boost/asio/netlink_protocol.hpp>
#include <boost/asio/netlink_endpoint.hpp>
#include <tbb/atomic.h>
#include <tbb/mutex.h>
#include <base/queue_task.h>
#include <sandesh/common/vns_constants.h>
#include <sandesh/common/vns_types.h>
#include <io/tcp_session.h>
#include <vr_types.h>
#include <nl_util.h>
#include "ksync_entry.h"
#include "ksync_tx_queue.h"
Include dependency graph for ksync_sock.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  AgentSandeshContext
 
class  IoContext
 
class  KSyncIoContext
 
class  KSyncBulkMsgContext
 
class  KSyncBulkSandeshContext
 
class  KSyncSock
 
struct  KSyncSock::KSyncRxData
 
struct  KSyncSock::KSyncRxQueueData
 
class  KSyncSockNetlink
 
class  KSyncSockUdp
 
class  KSyncSockUds
 
class  KSyncSockTcpSessionReader
 
class  KSyncSockTcpSession
 
class  KSyncSockTcp
 

Macros

#define KSYNC_DEFAULT_MSG_SIZE   4096
 
#define KSYNC_DEFAULT_Q_ID_SEQ   0x00000001
 
#define KSYNC_ACK_WAIT_THRESHOLD   200
 
#define KSYNC_SOCK_RECV_BUFF_SIZE   (256 * 1024)
 
#define KSYNC_BMC_ARR_SIZE   1024
 
#define KSYNC_AGENT_VROUTER_SOCK_PATH   "/var/run/vrouter/dpdk_netlink"
 

Typedefs

typedef std::vector
< boost::asio::mutable_buffers_1 > 
KSyncBufferList
 
typedef
boost::intrusive::member_hook
< IoContext,
boost::intrusive::list_member_hook
<>,&IoContext::node_
KSyncSockNode
 
typedef boost::intrusive::list
< IoContext, KSyncSockNode
IoContextList
 

Functions

uint32_t GetNetlinkSeqno (char *data)
 
bool NetlinkMsgDone (char *data)
 
bool ValidateNetlink (char *data)
 
void GetNetlinkPayload (char *data, char **buf, uint32_t *buf_len)
 
void InitNetlink (nl_client *client)
 
void ResetNetlink (nl_client *client)
 
void UpdateNetlink (nl_client *client, uint32_t len, uint32_t seq_no)
 
void DecodeSandeshMessages (char *buf, uint32_t buf_len, SandeshContext *sandesh_context, uint32_t alignment)
 

Macro Definition Documentation

#define KSYNC_ACK_WAIT_THRESHOLD   200

Definition at line 29 of file ksync_sock.h.

#define KSYNC_AGENT_VROUTER_SOCK_PATH   "/var/run/vrouter/dpdk_netlink"

Definition at line 567 of file ksync_sock.h.

#define KSYNC_BMC_ARR_SIZE   1024

Definition at line 31 of file ksync_sock.h.

#define KSYNC_DEFAULT_MSG_SIZE   4096

Definition at line 27 of file ksync_sock.h.

#define KSYNC_DEFAULT_Q_ID_SEQ   0x00000001

Definition at line 28 of file ksync_sock.h.

#define KSYNC_SOCK_RECV_BUFF_SIZE   (256 * 1024)

Definition at line 30 of file ksync_sock.h.

Typedef Documentation

typedef boost::intrusive::list<IoContext, KSyncSockNode> IoContextList

Definition at line 229 of file ksync_sock.h.

typedef std::vector<boost::asio::mutable_buffers_1> KSyncBufferList

Definition at line 37 of file ksync_sock.h.

typedef boost::intrusive::member_hook<IoContext, boost::intrusive::list_member_hook<>, &IoContext::node_> KSyncSockNode

Definition at line 228 of file ksync_sock.h.

Function Documentation

void DecodeSandeshMessages ( char *  buf,
uint32_t  buf_len,
SandeshContext sandesh_context,
uint32_t  alignment 
)

Definition at line 147 of file ksync_sock.cc.

Here is the call graph for this function:

void GetNetlinkPayload ( char *  data,
char **  buf,
uint32_t *  buf_len 
)

Definition at line 113 of file ksync_sock.cc.

uint32_t GetNetlinkSeqno ( char *  data)

Definition at line 57 of file ksync_sock.cc.

void InitNetlink ( nl_client *  client)

Definition at line 126 of file ksync_sock.cc.

Here is the call graph for this function:

bool NetlinkMsgDone ( char *  data)

Definition at line 62 of file ksync_sock.cc.

void ResetNetlink ( nl_client *  client)

Definition at line 133 of file ksync_sock.cc.

void UpdateNetlink ( nl_client *  client,
uint32_t  len,
uint32_t  seq_no 
)

Definition at line 140 of file ksync_sock.cc.

Here is the call graph for this function:

bool ValidateNetlink ( char *  data)

Definition at line 68 of file ksync_sock.cc.

Here is the call graph for this function: