File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
portable/ThirdParty/GCC/RP2040/include Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -227,7 +227,7 @@ static inline void vPortRecursiveLock( BaseType_t xCoreID,
227
227
if ( ucOwnedByCore [ xCoreID ][ ulLockNum ] )
228
228
{
229
229
configASSERT ( ucRecursionCountByLock [ ulLockNum ] != 255u );
230
- ucRecursionCountByLock [ ulLockNum ]++ ;
230
+ ucRecursionCountByLock [ ulLockNum ] = ucRecursionCountByLock [ ulLockNum ] + 1 ;
231
231
return ;
232
232
}
233
233
spin_lock_unsafe_blocking (pxSpinLock );
@@ -238,10 +238,11 @@ static inline void vPortRecursiveLock( BaseType_t xCoreID,
238
238
}
239
239
else
240
240
{
241
- configASSERT ( ( ucOwnedByCore [ xCoreID ] [ulLockNum ] ) != 0 );
241
+ configASSERT ( ( ucOwnedByCore [ xCoreID ] [ ulLockNum ] ) != 0 );
242
242
configASSERT ( ucRecursionCountByLock [ ulLockNum ] != 0 );
243
243
244
- if ( !-- ucRecursionCountByLock [ ulLockNum ] )
244
+ ucRecursionCountByLock [ ulLockNum ] = ucRecursionCountByLock [ ulLockNum ] - 1 ;
245
+ if (ucRecursionCountByLock [ ulLockNum ] == 0U )
245
246
{
246
247
ucOwnedByCore [ xCoreID ] [ ulLockNum ] = 0 ;
247
248
spin_unlock_unsafe (pxSpinLock );
You can’t perform that action at this time.
0 commit comments