INOS
CINOSBusHooks Class Reference

Public Types

enum  EState { eStaIdle = 0 , eStaSetup = 1 , eStaReady = 2 , eStaShutdown = 3 }
 
enum  { eCnsGroupIdBits = 2 }
 
enum  { eOptNone = 0x00000000 , eOptCategoryDc = 0x000000001 , eOptException = 0x000000002 , eOptExceptionEx = eOptNone }
 
enum  { eFlgNone = 0x00000000 , eFlgDelete = 0x000000001 , eFlgNegative = 0x000000002 , eFlgPositive = 0x000000004 }
 
enum  {
  eDcOrder = 20 , eDcCategory = 0xff , eDcCycletime = 0xffffffff , eDcCyclenumber = 0xff ,
  eDcCoreId = 0x3f
}
 

Public Member Functions

 CINOSBusHooks (uint8 auGroupId=0)
 Create bus hooks handler.
 
 ~CINOSBusHooks ()
 Destroy bus hooks handler.
 
EState GetState ()
 Get hooks handler state.
 
uint32 Setup (uint8 auCores=1, uint8 auCoreId=0, uint32 auOptions=eOptNone)
 Setup hooks handler with the given number of cores.
 
uint32 SetupCore (uint8 auCoreId, uint8 auCategories)
 Setup hook core handler.
 
uint32 SetupCategory (uint8 auCoreId, uint8 auCategory, uint32 auCycletimeNs, uint32 auFlags=CINOSBusHookCategory::eFlgEnabled)
 Setup hook category of given core handler.
 
uint32 SetupDone (uint16 auHooks)
 Finalysing hooks handler setup with given max. number of hooks.
 
uint32 Shutdown ()
 Shutdown hooks handler.
 
uint32 EnableCategory (uint8 auCategory)
 Enable given category of all cores.
 
uint32 EnableCategory (uint8 auCoreId, uint8 auCategory)
 Enable given category of given core.
 
uint32 DisableCategory (uint8 auCategory)
 Disable given category of all cores.
 
uint32 DisableCategory (uint8 auCoreId, uint8 auCategory)
 Disable given category of given core.
 
uint32 RegisterHook (uintid &aoHookId, void *apHandler, CINOSBusHook::EFlags auFlags=CINOSBusHook::eFlgEnabled)
 Register a hook with the given parameters.
 
uint32 RegisterHook (uintid &aoHookId, void *apHandler, void *apObject, CINOSBusHook::EFlags auFlags=CINOSBusHook::eFlgEnabled)
 Register a hook with the given parameters.
 
uint32 RegisterHook (uintid &aoHookId, void *apHandler, void *apObject, int32 aiOrder, CINOSBusHook::EFlags auFlags=CINOSBusHook::eFlgEnabled)
 Register a hook with the given parameters.
 
uint32 RegisterHook (uintid &aoHookId, void *apHandler, void *apObject, int32 aiOrder, uint8 auCategory, CINOSBusHook::EFlags auFlags=CINOSBusHook::eFlgEnabled)
 Register a hook with the given parameters.
 
uint32 RegisterHook (uintid &aoHookId, void *apHandler, void *apObject, int32 aiOrder, uint8 auCategory, uint32 auCycletime, CINOSBusHook::EFlags auFlags=CINOSBusHook::eFlgEnabled)
 Register a hook with the given parameters.
 
uint32 RegisterHook (uintid &aoHookId, void *apHandler, void *apObject, int32 aiOrder, uint8 auCategory, uint32 auCycletime, uint8 auCyclenumber, CINOSBusHook::EFlags auFlags=CINOSBusHook::eFlgEnabled)
 Register a hook with the given parameters.
 
uint32 RegisterHook (uintid &aoHookId, void *apHandler, void *apObject, int32 aiOrder, uint8 auCategory, uint32 auCycletime, uint8 auCyclenumber, uint8 auCoreId, CINOSBusHook::EFlags auFlags=CINOSBusHook::eFlgEnabled)
 Register a hook with the given parameters.
 
uint32 RegisterHook (CINOSBusHook *apHook)
 Register given hook.
 
uint32 UnregisterHook (uintid auHookId)
 Unregister given hook.
 
uint32 UnregisterHook (CINOSBusHook *apHook, uint32 auFlags=eFlgNone)
 Unregister given hook.
 
uint32 EnableHook (uintid auHookId)
 Enable given hook.
 
uint32 DisableHook (uintid auHookId)
 Disable given hook.
 
voidGetHookHandler (uintid auHookId)
 Get hook handler.
 
uint32 SetHookHandler (uintid auHookId, void *apHandler)
 Set hook handler.
 
uint8 GetHookCyclenumber (uintid auHookId)
 Get hook cycle number.
 
uint32 GetHookCycleTime (uintid auHookId)
 Get hook cycle time.
 
uint32 GetHookCycleTime (uintid auHookId, uint32 &auCycletime)
 Get hook cycle time.
 
uint32 GetHookCategory (uintid auHookId, uint8 &auCategory)
 Get hook category.
 
uint32 MoveHooks (uint8 auCoreId, uint8 auSrc, uint8 auDst)
 Move all hooks of given core from one category to an other.
 
uint32 HandleHooks (uint8 auCategory=0, uint8 auCycle=0, uint32 auFlags=eFlgNone)
 Call all hook handlers of the given category and cycle assigned to the actual core id.
 

Static Public Member Functions

static uint32 GetGroupId (uintid auHookId)
 Get group id from hook id.
 

Protected Member Functions

uint32 RequestId (uintid &aoHookId)
 Request a hook id.
 
uint32 ReleaseId (uintid auHookId)
 Release given hook id.
 
uint32 GetIndex (uintid auHookId)
 Return hook index from given hook id.
 
bool HasHooks (uint32 auNumber)
 Check whether the given number of hooks are still available.
 
uint32 iHookCheck (void *apHandler, void *apObject, int32 &aiOrder, uint8 &auCategory, uint32 &auCycletime, uint8 &auCyclenumber, uint8 &auCoreId)
 Check if the given hook parameters are valid.
 
uint32 iHookIdCheck (uintid auHookId, CINOSBusHook *&apHook)
 Check if the given hook id is valid.
 
uint32 iHookRegister (CINOSBusHook *apHook)
 Internal register given hook.
 
SINOSBusHookNodeAllocNode ()
 Allocate a hook node.
 
void FreeNode (SINOSBusHookNode *apNode)
 Free given hook node.
 
void FreeNodes (SINOSBusHookNode *apNode)
 Free list of hook nodes.
 
SINOSBusHookNodeListGet (SINOSBusHookNode **apHead)
 Atomically detach list from given head and set head = nullptr.
 
bool ListSet (SINOSBusHookNode **apHead, SINOSBusHookNode *apList)
 Atomically try to set head of list.
 
void ListInsert (SINOSBusHookNode *&apHead, SINOSBusHookNode *apNode)
 Insert node into list in ascending order.
 
void ListDestroy (SINOSBusHookNode **apHead)
 Destroy given nodes list.
 
 DECLARE_DYNAMIC (CINOSBusHooks)
 

Protected Attributes

EState m_eState = eStaIdle
 
uint32 m_uOptions = eOptNone
 
uint8 m_uGroupId {}
 
uint32 m_uHookIndexMask {}
 
uint32 m_uHookIdShift {}
 
std::atomic< uint32 > m_uHookIdCnt = {1}
 
uint32 m_uHooksActive {}
 
uint32 * m_pHooksActive {}
 
uint32 m_uHooksMax {}
 
std::atomic< int32 > m_uHooksAct = {0}
 
CINOSBusHook ** m_pHooks {}
 
uint8 m_uCoreIdBase {}
 
uint8 m_uCores {}
 
CINOSBusHookCorem_pCores {}
 
uint32 m_uCycletimeSlowest {1000000}
 
std::atomic< uint32 > m_uNodesMax = {0}
 
std::atomic< int32 > m_iNodesAct = {0}
 
SINOSBusHookNodem_pNodes {}
 
CINCOObject * m_pRegister {}
 
class CINCOBusHooksMain * m_pInco {}
 

Static Protected Attributes

static class CINOSBusHooksHelperm_pInstance [DF_INOS_MAX_CORES]
 

Friends

class CINOS1ms
 
class CINOSBus
 
class CINOSBusHookCycle
 
class CINOSBusHookExTest
 
class CINCOBusHooksMain
 
class CINCOBusHooks
 
class CINOSHwTarget
 

Member Enumeration Documentation

◆ anonymous enum

Enumerator
eCnsGroupIdBits 

number of group id bits

◆ anonymous enum

Enumerator
eOptCategoryDc 

use 'don't care category' if the requested is not available

eOptException 

throw an exception in case of an error (instead of a return value)

eOptExceptionEx 

return always a value because exception handling not available

Constructor & Destructor Documentation

◆ CINOSBusHooks()

CINOSBusHooks::CINOSBusHooks ( uint8  auGroupId = 0)

Create bus hooks handler.

Parameters
[in]auGroupIdUser group id (0..3, marker for all hookid's of this instance)

Member Function Documentation

◆ AllocNode()

SINOSBusHookNode * CINOSBusHooks::AllocNode ( )
inlineprotected

Allocate a hook node.

Returns
Pointer to allocated node

◆ DisableCategory() [1/2]

uint32 CINOSBusHooks::DisableCategory ( uint8  auCategory)

Disable given category of all cores.

Parameters
[in]auHookIdId of hook to be disabled
Returns
INOS_OK or an appropriate error

◆ DisableCategory() [2/2]

uint32 CINOSBusHooks::DisableCategory ( uint8  auCoreId,
uint8  auCategory 
)

Disable given category of given core.

Parameters
[in]auCoreIdRequested core
[in]auHookIdId of hook to be disabled
Returns
INOS_OK or an appropriate error

◆ DisableHook()

uint32 CINOSBusHooks::DisableHook ( uintid  auHookId)

Disable given hook.

Parameters
[in]auHookIdId of hook to be disabled
Returns
INOS_OK or an appropriate error

◆ EnableCategory() [1/2]

uint32 CINOSBusHooks::EnableCategory ( uint8  auCategory)

Enable given category of all cores.

Parameters
[in]auCategoryCategory to be enabled
Returns
INOS_OK or an appropriate error

◆ EnableCategory() [2/2]

uint32 CINOSBusHooks::EnableCategory ( uint8  auCoreId,
uint8  auCategory 
)

Enable given category of given core.

Parameters
[in]auCoreIdRequested core
[in]auCategoryCategory to be enabled
Returns
INOS_OK or an appropriate error

◆ EnableHook()

uint32 CINOSBusHooks::EnableHook ( uintid  auHookId)

Enable given hook.

Parameters
[in]auHookIdId of hook to be enabled
Returns
INOS_OK or an appropriate error

◆ FreeNode()

void CINOSBusHooks::FreeNode ( SINOSBusHookNode apNode)
inlineprotected

Free given hook node.

Parameters
[in]apNodePointer to hook node to be freed

◆ FreeNodes()

void CINOSBusHooks::FreeNodes ( SINOSBusHookNode apNode)
inlineprotected

Free list of hook nodes.

Parameters
[in]apNodePointer to list of nodes to be freed

◆ GetGroupId()

static uint32 CINOSBusHooks::GetGroupId ( uintid  auHookId)
inlinestatic

Get group id from hook id.

Parameters
[in]auHookIdId of requested hook.
Returns
Group id

◆ GetHookCategory()

uint32 CINOSBusHooks::GetHookCategory ( uintid  auHookId,
uint8 &  auCategory 
)

Get hook category.

Parameters
[in]auHookIdId of requested hook.
[out]auCategoryCategory of hook.
Returns
INOS_OK or an appropriate error

◆ GetHookCyclenumber()

uint8 CINOSBusHooks::GetHookCyclenumber ( uintid  auHookId)

Get hook cycle number.

Parameters
[in]auHookIdId of requested hook
Returns
Cyclenumber of hook

◆ GetHookCycleTime() [1/2]

uint32 CINOSBusHooks::GetHookCycleTime ( uintid  auHookId)

Get hook cycle time.

Parameters
[in]auHookIdId of requested hook.
Returns
Cycle time of hook.

◆ GetHookCycleTime() [2/2]

uint32 CINOSBusHooks::GetHookCycleTime ( uintid  auHookId,
uint32 &  auCycletime 
)

Get hook cycle time.

Parameters
[in]auHookIdId of requested hook.
[out]auCycletimeCycletime of hook.
Returns
INOS_OK or an appropriate error

◆ GetHookHandler()

void * CINOSBusHooks::GetHookHandler ( uintid  auHookId)

Get hook handler.

Parameters
[in]auHookIdId of requested hook
Returns
Pointer to hook handler or nullptr if invalid

◆ GetIndex()

uint32 CINOSBusHooks::GetIndex ( uintid  auHookId)
inlineprotected

Return hook index from given hook id.

Parameters
[in]auHookIId of hook
Returns
Index of hook in internal hook array

◆ GetState()

EState CINOSBusHooks::GetState ( )
inline

Get hooks handler state.

Returns
Actual hooks handler state

◆ HandleHooks()

uint32 CINOSBusHooks::HandleHooks ( uint8  auCategory = 0,
uint8  auCycle = 0,
uint32  auFlags = eFlgNone 
)

Call all hook handlers of the given category and cycle assigned to the actual core id.

Parameters
[in]auCategoryRequested category
[in]auCycleRequested cycle number
[in]auFlagsAdditional flags (e.g. eFlgPositive)
Returns
INOS_OK or an appropriate error

◆ HasHooks()

bool CINOSBusHooks::HasHooks ( uint32  auNumber)
inlineprotected

Check whether the given number of hooks are still available.

Parameters
[in]auNumberMin. number of hooks available
Returns
true if available, false otherwise

◆ iHookCheck()

uint32 CINOSBusHooks::iHookCheck ( void apHandler,
void apObject,
int32 &  aiOrder,
uint8 &  auCategory,
uint32 &  auCycletime,
uint8 &  auCyclenumber,
uint8 &  auCoreId 
)
protected

Check if the given hook parameters are valid.

Parameters
[in]apHandlerPointer to function to be called
[in]apObjectPointer to object instance if apHandler is a class method
[in]aiOrderRequested order, see DF_INOS_BUS_HOOK_ORDER_DEFAULT
[in]auCategoryRequested category
[in]auCycletimeRequested cycle time
[in]auCyclenumberRequested cycle number
[in]auCoreIdRequested core id
Returns
INOS_OK or an appropriate error

◆ iHookIdCheck()

uint32 CINOSBusHooks::iHookIdCheck ( uintid  auHookId,
CINOSBusHook *&  apHook 
)
protected

Check if the given hook id is valid.

Parameters
[in]auHookIdId to be checked
[out]apHookPointer to hook or nullptr if id invalid
Returns
INOS_OK or an appropriate error

◆ iHookRegister()

uint32 CINOSBusHooks::iHookRegister ( CINOSBusHook apHook)
protected

Internal register given hook.

Parameters
[in]apHookPointer to hook to be registered
Returns
INOS_OK or an appropriate error

◆ ListDestroy()

void CINOSBusHooks::ListDestroy ( SINOSBusHookNode **  apHead)
protected

Destroy given nodes list.

Parameters
[in]apNodePointer to head of list

◆ ListGet()

SINOSBusHookNode * CINOSBusHooks::ListGet ( SINOSBusHookNode **  apHead)
protected

Atomically detach list from given head and set head = nullptr.

Parameters
[in]apNodePointer to head of list
Returns
Pointer to head of list or nullptr if not available

◆ ListInsert()

void CINOSBusHooks::ListInsert ( SINOSBusHookNode *&  apHead,
SINOSBusHookNode apNode 
)
protected

Insert node into list in ascending order.

Parameters
[in]apHeadPointer to head of list
[in]apNodePointer to node to be inserted
Returns
true in case of success, false otherwise

◆ ListSet()

bool CINOSBusHooks::ListSet ( SINOSBusHookNode **  apHead,
SINOSBusHookNode apList 
)
protected

Atomically try to set head of list.

Parameters
[in]apHeadPointer to head of list
[in]apListPointer to head of list to be set
Returns
true in case of success, false otherwise

◆ MoveHooks()

uint32 CINOSBusHooks::MoveHooks ( uint8  auCoreId,
uint8  auSrc,
uint8  auDst 
)

Move all hooks of given core from one category to an other.

IMPORTANT: The system relies on the fact, that during the move, the hooks of the given categories are not touched (neither registered nor unregistered). Doing so anyway will end up in undefined behaviour!

Parameters
[in]auCoreIdRequested core id
[in]auSrcSource category number
[in]auDstDestination category number
Returns
INOS_OK or an appropriate error

◆ RegisterHook() [1/8]

uint32 CINOSBusHooks::RegisterHook ( CINOSBusHook apHook)

Register given hook.

Parameters
[in]apHookPointer to hook to be registered
Returns
INOS_OK or an appropriate error

◆ RegisterHook() [2/8]

uint32 CINOSBusHooks::RegisterHook ( uintid &  aoHookId,
void apHandler,
CINOSBusHook::EFlags  auFlags = CINOSBusHook::eFlgEnabled 
)

Register a hook with the given parameters.

Parameters
[out]aoHookIdId of registered hook
[in]apHandlerPointer to function to be called
[in]auFlagsRequested hook flags (e.g. CINOSBusHook::eFlgEnabled, CINOSBusHook::eFlgSingle)
Returns
INOS_OK or an appropriate error

◆ RegisterHook() [3/8]

uint32 CINOSBusHooks::RegisterHook ( uintid &  aoHookId,
void apHandler,
void apObject,
CINOSBusHook::EFlags  auFlags = CINOSBusHook::eFlgEnabled 
)

Register a hook with the given parameters.

Parameters
[out]aoHookIdId of registered hook
[in]apHandlerPointer to function to be called
[in]apObjectPointer to object instance if apHandler is a class method
[in]auFlagsRequested hook flags (e.g. CINOSBusHook::eFlgEnabled, CINOSBusHook::eFlgSingle)
Returns
INOS_OK or an appropriate error

◆ RegisterHook() [4/8]

uint32 CINOSBusHooks::RegisterHook ( uintid &  aoHookId,
void apHandler,
void apObject,
int32  aiOrder,
CINOSBusHook::EFlags  auFlags = CINOSBusHook::eFlgEnabled 
)

Register a hook with the given parameters.

Parameters
[out]aoHookIdId of registered hook
[in]apHandlerPointer to function to be called
[in]apObjectPointer to object instance if apHandler is a class method
[in]aiOrderRequested order, see DF_INOS_BUS_HOOK_ORDER_DEFAULT
[in]auFlagsRequested hook flags (e.g. CINOSBusHook::eFlgEnabled, CINOSBusHook::eFlgSingle)
Returns
INOS_OK or an appropriate error

◆ RegisterHook() [5/8]

uint32 CINOSBusHooks::RegisterHook ( uintid &  aoHookId,
void apHandler,
void apObject,
int32  aiOrder,
uint8  auCategory,
CINOSBusHook::EFlags  auFlags = CINOSBusHook::eFlgEnabled 
)

Register a hook with the given parameters.

Parameters
[out]aoHookIdId of registered hook
[in]apHandlerPointer to function to be called
[in]apObjectPointer to object instance if apHandler is a class method
[in]aiOrderRequested order, see DF_INOS_BUS_HOOK_ORDER_DEFAULT
[in]auCategoryRequested category
[in]auFlagsRequested hook flags (e.g. CINOSBusHook::eFlgEnabled, CINOSBusHook::eFlgSingle)
Returns
INOS_OK or an appropriate error

◆ RegisterHook() [6/8]

uint32 CINOSBusHooks::RegisterHook ( uintid &  aoHookId,
void apHandler,
void apObject,
int32  aiOrder,
uint8  auCategory,
uint32  auCycletime,
CINOSBusHook::EFlags  auFlags = CINOSBusHook::eFlgEnabled 
)

Register a hook with the given parameters.

Parameters
[out]aoHookIdId of registered hook
[in]apHandlerPointer to function to be called
[in]apObjectPointer to object instance if apHandler is a class method
[in]aiOrderRequested order, see DF_INOS_BUS_HOOK_ORDER_DEFAULT
[in]auCategoryRequested category
[in]auCycletimeRequested cycle time
[in]auFlagsRequested hook flags (e.g. CINOSBusHook::eFlgEnabled, CINOSBusHook::eFlgSingle)
Returns
INOS_OK or an appropriate error

◆ RegisterHook() [7/8]

uint32 CINOSBusHooks::RegisterHook ( uintid &  aoHookId,
void apHandler,
void apObject,
int32  aiOrder,
uint8  auCategory,
uint32  auCycletime,
uint8  auCyclenumber,
CINOSBusHook::EFlags  auFlags = CINOSBusHook::eFlgEnabled 
)

Register a hook with the given parameters.

Parameters
[out]aoHookIdId of registered hook
[in]apHandlerPointer to function to be called
[in]apObjectPointer to object instance if apHandler is a class method
[in]aiOrderRequested order, see DF_INOS_BUS_HOOK_ORDER_DEFAULT
[in]auCategoryRequested category
[in]auCycletimeRequested cycle time
[in]auCyclenumberRequested cycle number
[in]auFlagsRequested hook flags (e.g. CINOSBusHook::eFlgEnabled, CINOSBusHook::eFlgSingle)
Returns
INOS_OK or an appropriate error

◆ RegisterHook() [8/8]

uint32 CINOSBusHooks::RegisterHook ( uintid &  aoHookId,
void apHandler,
void apObject,
int32  aiOrder,
uint8  auCategory,
uint32  auCycletime,
uint8  auCyclenumber,
uint8  auCoreId,
CINOSBusHook::EFlags  auFlags = CINOSBusHook::eFlgEnabled 
)

Register a hook with the given parameters.

Parameters
[out]aoHookIdId of registered hook
[in]apHandlerPointer to function to be called
[in]apObjectPointer to object instance if apHandler is a class method
[in]aiOrderRequested order, see DF_INOS_BUS_HOOK_ORDER_DEFAULT
[in]auCategoryRequested category
[in]auCycletimeRequested cycle time
[in]auCyclenumberRequested cycle number
[in]auCoreIdRequested core id
[in]auFlagsRequested hook flags (e.g. CINOSBusHook::eFlgEnabled, CINOSBusHook::eFlgSingle)
Returns
INOS_OK or an appropriate error

◆ ReleaseId()

uint32 CINOSBusHooks::ReleaseId ( uintid  auHookId)
protected

Release given hook id.

Parameters
[in]auHookIdId to be released
Returns
INOS_OK or an appropriate error

◆ RequestId()

uint32 CINOSBusHooks::RequestId ( uintid &  aoHookId)
protected

Request a hook id.

Parameters
[out]aoHookIdId of hook
Returns
INOS_OK or an appropriate error

◆ SetHookHandler()

uint32 CINOSBusHooks::SetHookHandler ( uintid  auHookId,
void apHandler 
)

Set hook handler.

Parameters
[in]auHookIdId of requested hook
[in]apHandlerPointer to handler to set
Returns
INOS_OK or an appropriate error

◆ Setup()

uint32 CINOSBusHooks::Setup ( uint8  auCores = 1,
uint8  auCoreId = 0,
uint32  auOptions = eOptNone 
)

Setup hooks handler with the given number of cores.

If we need e.g. a hooks handler witch handles cores 2..5 on a 8 cores system the setup looks like this

Setup(4, 2);

Parameters
[in]auCoresRequested number of cores
[in]auCoreIdBase core id (virtual core id of first core)
[in]auOptionsAdditional options
Returns
INOS_OK or an appropriate error

◆ SetupCategory()

uint32 CINOSBusHooks::SetupCategory ( uint8  auCoreId,
uint8  auCategory,
uint32  auCycletimeNs,
uint32  auFlags = CINOSBusHookCategory::eFlgEnabled 
)

Setup hook category of given core handler.

Parameters
[in]auCoreIdNumber of core to set up
[in]auCategoryNumber of category to set up
[in]auCycletimeNsRequested cycletime of this category
[in]auFlagsRequested category flags (e.g. eFlgEnabled)
Returns
INOS_OK or an appropriate error

◆ SetupCore()

uint32 CINOSBusHooks::SetupCore ( uint8  auCoreId,
uint8  auCategories 
)

Setup hook core handler.

Parameters
[in]auCoreIdNumber of core to set up
[in]auCategoriesRequested number of categories
Returns
INOS_OK or an appropriate error

◆ SetupDone()

uint32 CINOSBusHooks::SetupDone ( uint16  auHooks)

Finalysing hooks handler setup with given max. number of hooks.

Parameters
[in]auHooksMax. number of hooks the hook handler owns
Returns
INOS_OK or an appropriate error

◆ Shutdown()

uint32 CINOSBusHooks::Shutdown ( )

Shutdown hooks handler.

Returns
INOS_OK or an appropriate error

◆ UnregisterHook() [1/2]

uint32 CINOSBusHooks::UnregisterHook ( CINOSBusHook apHook,
uint32  auFlags = eFlgNone 
)

Unregister given hook.

Parameters
[in]apHookPointer to hook to be unregistered
[in]auFlagsAdditional flags (e.g. eFlgDelete)
Returns
INOS_OK or an appropriate error

◆ UnregisterHook() [2/2]

uint32 CINOSBusHooks::UnregisterHook ( uintid  auHookId)

Unregister given hook.

Parameters
[in]auHookIdId of hook to be unregistered
Returns
INOS_OK or an appropriate error

Member Data Documentation

◆ m_iNodesAct

std::atomic<int32> CINOSBusHooks::m_iNodesAct = {0}
protected

number of allocated nodes

◆ m_pCores

CINOSBusHookCore* CINOSBusHooks::m_pCores {}
protected

array of core handlers

◆ m_pHooks

CINOSBusHook** CINOSBusHooks::m_pHooks {}
protected

array of pointers to hooks

◆ m_pHooksActive

uint32* CINOSBusHooks::m_pHooksActive {}
protected

bit field of active hooks

◆ m_pInco

class CINCOBusHooksMain* CINOSBusHooks::m_pInco {}
protected

pointer to inco registration of 'hooks'

◆ m_pInstance

class CINOSBusHooksHelper* CINOSBusHooks::m_pInstance[DF_INOS_MAX_CORES]
staticprotected

array of hook helper instances

◆ m_pNodes

SINOSBusHookNode* CINOSBusHooks::m_pNodes {}
protected

pool of hook nodes

◆ m_pRegister

CINCOObject* CINOSBusHooks::m_pRegister {}
protected

pointer to inco registration

◆ m_uCoreIdBase

uint8 CINOSBusHooks::m_uCoreIdBase {}
protected

base core id

◆ m_uCores

uint8 CINOSBusHooks::m_uCores {}
protected

max. number of cores

◆ m_uCycletimeSlowest

uint32 CINOSBusHooks::m_uCycletimeSlowest {1000000}
protected

slowest cycletime

◆ m_uGroupId

uint8 CINOSBusHooks::m_uGroupId {}
protected

group id

◆ m_uHookIdCnt

std::atomic<uint32> CINOSBusHooks::m_uHookIdCnt = {1}
protected

hook id counter

◆ m_uHookIdShift

uint32 CINOSBusHooks::m_uHookIdShift {}
protected

id shift

◆ m_uHookIndexMask

uint32 CINOSBusHooks::m_uHookIndexMask {}
protected

index mask

◆ m_uHooksAct

std::atomic<int32> CINOSBusHooks::m_uHooksAct = {0}
protected

actual number of registered hooks

◆ m_uHooksActive

uint32 CINOSBusHooks::m_uHooksActive {}
protected

size of hooks active

◆ m_uHooksMax

uint32 CINOSBusHooks::m_uHooksMax {}
protected

max. number of hooks

◆ m_uNodesMax

std::atomic<uint32> CINOSBusHooks::m_uNodesMax = {0}
protected

overall number of nodes


The documentation for this class was generated from the following file: