Lines Matching refs:ulSecureContextIndex

94 static void vReturnSecureContext( uint32_t ulSecureContextIndex );
104 uint32_t i, ulSecureContextIndex = secureconfigMAX_SECURE_CONTEXTS; in ulGetSecureContext() local
112 ( ulSecureContextIndex == secureconfigMAX_SECURE_CONTEXTS ) ) in ulGetSecureContext()
114 ulSecureContextIndex = i; in ulGetSecureContext()
120 ulSecureContextIndex = secureconfigMAX_SECURE_CONTEXTS; in ulGetSecureContext()
125 return ulSecureContextIndex; in ulGetSecureContext()
129 static void vReturnSecureContext( uint32_t ulSecureContextIndex ) in vReturnSecureContext() argument
131 xSecureContexts[ ulSecureContextIndex ].pucCurrentStackPointer = NULL; in vReturnSecureContext()
132 xSecureContexts[ ulSecureContextIndex ].pucStackLimit = NULL; in vReturnSecureContext()
133 xSecureContexts[ ulSecureContextIndex ].pucStackStart = NULL; in vReturnSecureContext()
134 xSecureContexts[ ulSecureContextIndex ].pvTaskHandle = NULL; in vReturnSecureContext()
192 uint32_t ulIPSR, ulSecureContextIndex; in SecureContext_AllocateContext() local
211 ulSecureContextIndex = ulGetSecureContext( pvTaskHandle ); in SecureContext_AllocateContext()
214 if( ulSecureContextIndex < secureconfigMAX_SECURE_CONTEXTS ) in SecureContext_AllocateContext()
227 … xSecureContexts[ ulSecureContextIndex ].pucStackStart = pucStackMemory + ulSecureStackSize; in SecureContext_AllocateContext()
235 xSecureContexts[ ulSecureContextIndex ].pucStackLimit = pucStackMemory; in SecureContext_AllocateContext()
237 xSecureContexts[ ulSecureContextIndex ].pvTaskHandle = pvTaskHandle; in SecureContext_AllocateContext()
244 … pulCurrentStackPointer = ( uint32_t * ) xSecureContexts[ ulSecureContextIndex ].pucStackStart; in SecureContext_AllocateContext()
258 …xSecureContexts[ ulSecureContextIndex ].pucCurrentStackPointer = ( uint8_t * ) pulCurrentStackPoin… in SecureContext_AllocateContext()
264 …xSecureContexts[ ulSecureContextIndex ].pucCurrentStackPointer = xSecureContexts[ ulSecureContextI… in SecureContext_AllocateContext()
269 xSecureContextHandle = ulSecureContextIndex + 1UL; in SecureContext_AllocateContext()
281 uint32_t ulIPSR, ulSecureContextIndex; in SecureContext_FreeContext() local
293 ulSecureContextIndex = xSecureContextHandle - 1UL; in SecureContext_FreeContext()
297 if( xSecureContexts[ ulSecureContextIndex ].pvTaskHandle == pvTaskHandle ) in SecureContext_FreeContext()
300 vPortFree( xSecureContexts[ ulSecureContextIndex ].pucStackLimit ); in SecureContext_FreeContext()
303 vReturnSecureContext( ulSecureContextIndex ); in SecureContext_FreeContext()
314 uint32_t ulSecureContextIndex; in SecureContext_LoadContext() local
318 ulSecureContextIndex = xSecureContextHandle - 1UL; in SecureContext_LoadContext()
325 ( xSecureContexts[ ulSecureContextIndex ].pvTaskHandle == pvTaskHandle ) ) in SecureContext_LoadContext()
327 SecureContext_LoadContextAsm( &( xSecureContexts[ ulSecureContextIndex ] ) ); in SecureContext_LoadContext()
337 uint32_t ulSecureContextIndex; in SecureContext_SaveContext() local
341 ulSecureContextIndex = xSecureContextHandle - 1UL; in SecureContext_SaveContext()
347 if( ( xSecureContexts[ ulSecureContextIndex ].pucStackLimit == pucStackLimit ) && in SecureContext_SaveContext()
348 ( xSecureContexts[ ulSecureContextIndex ].pvTaskHandle == pvTaskHandle ) ) in SecureContext_SaveContext()
350 SecureContext_SaveContextAsm( &( xSecureContexts[ ulSecureContextIndex ] ) ); in SecureContext_SaveContext()