Skip to content

Commit eab7196

Browse files
committed
Reflect the change size of the structure of the Mutex to ethernet module.
We reflected the change size of the structure of the Mutex associated with NEON of CMSIS-RTOS RTX for Cortex-A9support to ethernet module.
1 parent 18f341c commit eab7196

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

libraries/net/lwip/lwip-sys/arch/sys_arch.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,11 @@ void sys_sem_free(sys_sem_t *sem) {}
285285
* @return a new mutex */
286286
err_t sys_mutex_new(sys_mutex_t *mutex) {
287287
#ifdef CMSIS_OS_RTX
288+
#ifdef __MBED_CMSIS_RTOS_CA9
289+
memset(mutex->data, 0, sizeof(int32_t)*4);
290+
#else
288291
memset(mutex->data, 0, sizeof(int32_t)*3);
292+
#endif
289293
mutex->def.mutex = mutex->data;
290294
#endif
291295
mutex->id = osMutexCreate(&mutex->def);

libraries/net/lwip/lwip-sys/arch/sys_arch.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,12 @@ typedef struct {
4040
osMutexId id;
4141
osMutexDef_t def;
4242
#ifdef CMSIS_OS_RTX
43+
#ifdef __MBED_CMSIS_RTOS_CA9
44+
int32_t data[4];
45+
#else
4346
int32_t data[3];
4447
#endif
48+
#endif
4549
} sys_mutex_t;
4650

4751
// === MAIL BOX ===

0 commit comments

Comments
 (0)