mm: both use spin_lock_irqxx() when operated delaylist

align with free_delaylist()

Signed-off-by: ligd <liguiding1@xiaomi.com>
This commit is contained in:
ligd 2023-10-27 16:21:35 +08:00 committed by Xiang Xiao
parent f3fabc5d32
commit fe03ce5fbe

View File

@ -45,12 +45,12 @@ static void add_delaylist(FAR struct mm_heap_s *heap, FAR void *mem)
/* Delay the deallocation until a more appropriate time. */
flags = enter_critical_section();
flags = spin_lock_irqsave(NULL);
tmp->flink = heap->mm_delaylist[up_cpu_index()];
heap->mm_delaylist[up_cpu_index()] = tmp;
leave_critical_section(flags);
spin_unlock_irqrestore(NULL, flags);
#endif
}