@@ -461,7 +461,7 @@ __attribute__((section(".rodata"))) =
461
461
0U ,
462
462
#endif
463
463
{ & os_isr_queue [0 ], (uint16_t )(sizeof (os_isr_queue )/sizeof (void * )), 0U },
464
- {
464
+ {
465
465
// Memory Pools (Variable Block Size)
466
466
#if ((OS_THREAD_OBJ_MEM != 0 ) && (OS_THREAD_USER_STACK_SIZE != 0 ))
467
467
& os_thread_stack [0 ], sizeof (os_thread_stack ),
@@ -494,7 +494,7 @@ __attribute__((section(".rodata"))) =
494
494
#endif
495
495
& os_mpi_thread ,
496
496
#else
497
- NULL ,
497
+ NULL ,
498
498
NULL ,
499
499
#endif
500
500
#if (OS_TIMER_OBJ_MEM != 0 )
@@ -577,7 +577,7 @@ __asm void os_cb_sections_wrapper (void) {
577
577
EXTERN || .bss .os .mempool .cb$$Limit || [WEAK ]
578
578
EXTERN || .bss .os .msgqueue .cb$$Base || [WEAK ]
579
579
EXTERN || .bss .os .msgqueue .cb$$Limit || [WEAK ]
580
-
580
+
581
581
AREA || .rodata || , DATA , READONLY
582
582
EXPORT os_cb_sections
583
583
os_cb_sections
@@ -777,11 +777,12 @@ typedef void *mutex;
777
777
//lint -e818 "Pointer 'm' could be declared as pointing to const"
778
778
779
779
// Initialize mutex
780
+ #if !defined(__ARMCC_VERSION ) || __ARMCC_VERSION < 6010050
780
781
__USED
782
+ #endif
781
783
int _mutex_initialize (mutex * m );
782
- int _mutex_initialize (mutex * m ) {
784
+ __WEAK int _mutex_initialize (mutex * m ) {
783
785
int result ;
784
-
785
786
* m = osMutexNew (NULL );
786
787
if (* m != NULL ) {
787
788
result = 1 ;
@@ -793,26 +794,32 @@ int _mutex_initialize(mutex *m) {
793
794
}
794
795
795
796
// Acquire mutex
797
+ #if !defined(__ARMCC_VERSION ) || __ARMCC_VERSION < 6010050
796
798
__USED
797
- void _mutex_acquire (mutex * m );
799
+ #endif
800
+ __WEAK void _mutex_acquire (mutex * m );
798
801
void _mutex_acquire (mutex * m ) {
799
802
if (os_kernel_is_active () != 0U ) {
800
803
(void )osMutexAcquire (* m , osWaitForever );
801
804
}
802
805
}
803
806
804
807
// Release mutex
808
+ #if !defined(__ARMCC_VERSION ) || __ARMCC_VERSION < 6010050
805
809
__USED
806
- void _mutex_release (mutex * m );
810
+ #endif
811
+ __WEAK void _mutex_release (mutex * m );
807
812
void _mutex_release (mutex * m ) {
808
813
if (os_kernel_is_active () != 0U ) {
809
814
(void )osMutexRelease (* m );
810
815
}
811
816
}
812
817
813
818
// Free mutex
819
+ #if !defined(__ARMCC_VERSION ) || __ARMCC_VERSION < 6010050
814
820
__USED
815
- void _mutex_free (mutex * m );
821
+ #endif
822
+ __WEAK void _mutex_free (mutex * m );
816
823
void _mutex_free (mutex * m ) {
817
824
(void )osMutexDelete (* m );
818
825
}
0 commit comments