Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion portable/ThirdParty/GCC/ARM_TFM/os_wrapper_freertos.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2019-2024, Arm Limited. All rights reserved.
* Copyright 2019-2024,2026 Arm Limited and/or its affiliates <open-source-office@arm.com>
*
* SPDX-License-Identifier: MIT
*
Expand Down Expand Up @@ -28,9 +28,12 @@
* The implementation is based on FreeRTOS mutex type semaphore.
*/

#include <stdbool.h>

#include "os_wrapper/mutex.h"

#include "FreeRTOS.h"
#include "task.h"
#include "semphr.h"
#include "mpu_wrappers.h"

Expand All @@ -43,6 +46,13 @@
StaticSemaphore_t xSecureMutexBuffer;
#endif

#if ( ( INCLUDE_xTaskGetSchedulerState == 1 ) || ( configUSE_TIMERS == 1 ) )
bool os_wrapper_is_kernel_started( void )
{
return xTaskGetSchedulerState() != taskSCHEDULER_NOT_STARTED;
}
#endif

void * os_wrapper_mutex_create( void )
{
SemaphoreHandle_t xMutexHandle = NULL;
Expand Down
Loading