Skip to content

Commit e5cd038

Browse files
committed
mm: replace enter_critical_section with spin_irqsave in free_delaylist
Signed-off-by: TaiJuWu <[email protected]>
1 parent 8bdb78b commit e5cd038

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

mm/mm_heap/mm_malloc.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@ static void free_delaylist(FAR struct mm_heap_s *heap)
4747

4848
/* Move the delay list to local */
4949

50-
flags = enter_critical_section();
50+
flags = spin_lock_irqsave(NULL);
5151

5252
tmp = heap->mm_delaylist[up_cpu_index()];
5353
heap->mm_delaylist[up_cpu_index()] = NULL;
5454

55-
leave_critical_section(flags);
55+
spin_unlock_irqrestore(NULL, flags);
5656

5757
/* Test if the delayed is empty */
5858

0 commit comments

Comments
 (0)