@@ -429,7 +429,7 @@ __attribute__((section(".rodata"))) =
429
429
0U ,
430
430
#endif
431
431
{ & os_isr_queue [0 ], (uint16_t )(sizeof (os_isr_queue )/sizeof (void * )), 0U },
432
- {
432
+ {
433
433
// Memory Pools (Variable Block Size)
434
434
#if ((OS_THREAD_OBJ_MEM != 0 ) && (OS_THREAD_USER_STACK_SIZE != 0 ))
435
435
& os_thread_stack [0 ], sizeof (os_thread_stack ),
@@ -462,7 +462,7 @@ __attribute__((section(".rodata"))) =
462
462
#endif
463
463
& os_mpi_thread ,
464
464
#else
465
- NULL ,
465
+ NULL ,
466
466
NULL ,
467
467
#endif
468
468
#if (OS_TIMER_OBJ_MEM != 0 )
@@ -545,7 +545,7 @@ __asm void os_cb_sections_wrapper (void) {
545
545
EXTERN || .bss .os .mempool .cb$$Limit || [WEAK ]
546
546
EXTERN || .bss .os .msgqueue .cb$$Base || [WEAK ]
547
547
EXTERN || .bss .os .msgqueue .cb$$Limit || [WEAK ]
548
-
548
+
549
549
AREA || .rodata || , DATA , READONLY
550
550
EXPORT os_cb_sections
551
551
os_cb_sections
@@ -745,11 +745,12 @@ typedef void *mutex;
745
745
//lint -e818 "Pointer 'm' could be declared as pointing to const"
746
746
747
747
// Initialize mutex
748
+ #if !defined(__ARMCC_VERSION ) || __ARMCC_VERSION < 6010050
748
749
__USED
750
+ #endif
749
751
int _mutex_initialize (mutex * m );
750
- int _mutex_initialize (mutex * m ) {
752
+ __WEAK int _mutex_initialize (mutex * m ) {
751
753
int result ;
752
-
753
754
* m = osMutexNew (NULL );
754
755
if (* m != NULL ) {
755
756
result = 1 ;
@@ -761,26 +762,32 @@ int _mutex_initialize(mutex *m) {
761
762
}
762
763
763
764
// Acquire mutex
765
+ #if !defined(__ARMCC_VERSION ) || __ARMCC_VERSION < 6010050
764
766
__USED
765
- void _mutex_acquire (mutex * m );
767
+ #endif
768
+ __WEAK void _mutex_acquire (mutex * m );
766
769
void _mutex_acquire (mutex * m ) {
767
770
if (os_kernel_is_active () != 0U ) {
768
771
(void )osMutexAcquire (* m , osWaitForever );
769
772
}
770
773
}
771
774
772
775
// Release mutex
776
+ #if !defined(__ARMCC_VERSION ) || __ARMCC_VERSION < 6010050
773
777
__USED
774
- void _mutex_release (mutex * m );
778
+ #endif
779
+ __WEAK void _mutex_release (mutex * m );
775
780
void _mutex_release (mutex * m ) {
776
781
if (os_kernel_is_active () != 0U ) {
777
782
(void )osMutexRelease (* m );
778
783
}
779
784
}
780
785
781
786
// Free mutex
787
+ #if !defined(__ARMCC_VERSION ) || __ARMCC_VERSION < 6010050
782
788
__USED
783
- void _mutex_free (mutex * m );
789
+ #endif
790
+ __WEAK void _mutex_free (mutex * m );
784
791
void _mutex_free (mutex * m ) {
785
792
(void )osMutexDelete (* m );
786
793
}
0 commit comments