From 90a75dfedf3d8c620f9871051d9eeaeef3ee587c Mon Sep 17 00:00:00 2001 From: ligd Date: Tue, 16 Mar 2021 20:42:53 +0800 Subject: [PATCH] mm/tlsf: fix mm_checkcorruption failed, caused by mm_takesemaphore() param error Change-Id: Id3fc81754f623c53151ba2ae02c0271008d5f3e3 Signed-off-by: ligd --- mm/tlsf/mm_tlsf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mm/tlsf/mm_tlsf.c b/mm/tlsf/mm_tlsf.c index a366e3033b2..6bcb432d5da 100644 --- a/mm/tlsf/mm_tlsf.c +++ b/mm/tlsf/mm_tlsf.c @@ -574,7 +574,7 @@ void mm_checkcorruption(FAR struct mm_heap_s *heap) } else { - mm_takesemaphore(heap); + mm_takesemaphore(impl); } /* Check tlsf control block in the first pass */ @@ -596,7 +596,7 @@ void mm_checkcorruption(FAR struct mm_heap_s *heap) } else { - mm_givesemaphore(heap); + mm_givesemaphore(impl); } } #undef region