OpenSDN source code
|
#include <ksync_memory.h>
Classes | |
struct | AuditEntry |
Public Member Functions | |
KSyncMemory (KSync *ksync, uint32_t minor_id) | |
virtual | ~KSyncMemory () |
virtual void | Init () |
void | InitMem (void *hpmem) |
virtual void | InitTest () |
virtual void | Shutdown () |
bool | AuditProcess () |
void | MapSharedMemory () |
void | GetTableSize () |
int | GetKernelTableSize () |
void | UnmapMemTest () |
virtual int | EncodeReq (nl_client *nl, uint32_t attr_len)=0 |
virtual int | get_entry_size ()=0 |
virtual void | SetTableSize () |
virtual bool | IsInactiveEntry (uint32_t idx, uint8_t &gen_id)=0 |
virtual void | CreateProtoAuditEntry (uint32_t index, uint8_t gen_id)=0 |
virtual void | DecrementHoldFlowCounter () |
virtual void | IncrementHoldFlowCounter () |
virtual void | UpdateAgentHoldFlowCounter () |
KSync * | ksync () const |
void | set_major_devid (int id) |
void | set_table_size (int count) |
void | set_table_path (const std::string &path) |
uint32_t | audit_timeout () const |
void | Mmap (bool unlink, void *khpmem, bool kernel_mode) |
uint32_t | table_entries_count () |
Static Public Attributes | |
static const uint32_t | kAuditSweepTime = 180 |
static const uint32_t | kAuditYieldTimer = 100 |
static const uint32_t | kAuditTimeout = (5 * 1000 * 1000) |
static const uint32_t | kAuditYieldMax = (1024) |
static const uint32_t | kAuditYieldMin = (100) |
Protected Attributes | |
KSync * | ksync_ |
void * | table_ |
std::string | table_path_ |
int | major_devid_ |
int | minor_devid_ |
int | table_size_ |
uint32_t | table_entries_count_ |
Timer * | audit_timer_ |
uint32_t | audit_timeout_ |
uint32_t | audit_yield_ |
uint32_t | audit_interval_ |
uint32_t | audit_idx_ |
std::list< AuditEntry > | audit_list_ |
Definition at line 15 of file ksync_memory.h.
KSyncMemory::KSyncMemory | ( | KSync * | ksync, |
uint32_t | minor_id | ||
) |
Definition at line 46 of file ksync_memory.cc.
|
virtual |
|
inline |
Definition at line 55 of file ksync_memory.h.
bool KSyncMemory::AuditProcess | ( | ) |
|
pure virtual |
Implemented in KSyncFlowMemory, and KSyncBridgeMemory.
|
inlinevirtual |
Reimplemented in KSyncFlowMemory.
Definition at line 46 of file ksync_memory.h.
|
pure virtual |
Implemented in KSyncFlowMemory, and KSyncBridgeMemory.
|
pure virtual |
Implemented in KSyncFlowMemory, and KSyncBridgeMemory.
int KSyncMemory::GetKernelTableSize | ( | ) |
void KSyncMemory::GetTableSize | ( | ) |
|
inlinevirtual |
Reimplemented in KSyncFlowMemory.
Definition at line 47 of file ksync_memory.h.
|
virtual |
Reimplemented in KSyncFlowMemory.
Definition at line 69 of file ksync_memory.cc.
void KSyncMemory::InitMem | ( | void * | hpmem | ) |
|
virtual |
Reimplemented in KSyncFlowMemory, and KSyncBridgeMemory.
Definition at line 171 of file ksync_memory.cc.
|
pure virtual |
Implemented in KSyncFlowMemory, and KSyncBridgeMemory.
|
inline |
Definition at line 49 of file ksync_memory.h.
void KSyncMemory::MapSharedMemory | ( | ) |
void KSyncMemory::Mmap | ( | bool | unlink, |
void * | khpmem, | ||
bool | kernel_mode | ||
) |
|
inline |
Definition at line 50 of file ksync_memory.h.
|
inline |
Definition at line 52 of file ksync_memory.h.
|
inline |
Definition at line 51 of file ksync_memory.h.
|
inlinevirtual |
Reimplemented in KSyncFlowMemory, and KSyncBridgeMemory.
Definition at line 43 of file ksync_memory.h.
|
virtual |
Reimplemented in KSyncFlowMemory, and KSyncBridgeMemory.
Definition at line 175 of file ksync_memory.cc.
|
inline |
Definition at line 57 of file ksync_memory.h.
void KSyncMemory::UnmapMemTest | ( | ) |
|
inlinevirtual |
Reimplemented in KSyncFlowMemory.
Definition at line 48 of file ksync_memory.h.
|
protected |
Definition at line 87 of file ksync_memory.h.
|
protected |
Definition at line 86 of file ksync_memory.h.
|
protected |
Definition at line 88 of file ksync_memory.h.
|
protected |
Definition at line 84 of file ksync_memory.h.
|
protected |
Definition at line 82 of file ksync_memory.h.
|
protected |
Definition at line 85 of file ksync_memory.h.
|
static |
Definition at line 18 of file ksync_memory.h.
|
static |
Definition at line 22 of file ksync_memory.h.
|
static |
Definition at line 24 of file ksync_memory.h.
|
static |
Definition at line 26 of file ksync_memory.h.
|
static |
Definition at line 20 of file ksync_memory.h.
|
protected |
Definition at line 70 of file ksync_memory.h.
|
protected |
Definition at line 75 of file ksync_memory.h.
|
protected |
Definition at line 76 of file ksync_memory.h.
|
protected |
Definition at line 71 of file ksync_memory.h.
|
protected |
Definition at line 80 of file ksync_memory.h.
|
protected |
Definition at line 73 of file ksync_memory.h.
|
protected |
Definition at line 78 of file ksync_memory.h.