Beispiel #1
0
/**
 * \fn     context_EnterCriticalSection / context_LeaveCriticalSection
 * \brief  Lock / Unlock context related critical sections
 *
 * The context clients should use these functions for protecting their critical sections
 *   when handling context transition to driver context.
 *
 * \note
 * \param  hContext   - The module handle
 * \return void
 * \sa
 */
void context_EnterCriticalSection (TI_HANDLE hContext)
{
	TContext *pContext = (TContext *)hContext;


	/* Start critical section protection */
	os_protectLock (pContext->hOs, pContext->hProtectionLock);
}
/** 
 * \fn     context_EnterCriticalSection / context_LeaveCriticalSection
 * \brief  Lock / Unlock context related critical sections
 * 
 * The context clients should use these functions for protecting their critical sections
 *   when handling context transition to driver context.
 * 
 * \note   
 * \param  hContext   - The module handle
 * \return void 
 * \sa     
 */ 
void context_EnterCriticalSection (TI_HANDLE hContext)
{
	TContext *pContext = (TContext *)hContext;

    TRACE0(pContext->hReport, REPORT_SEVERITY_INFORMATION , "context_EnterCriticalSection():\n");

    /* Start critical section protection */
    os_protectLock (pContext->hOs, pContext->hProtectionLock);
}