This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a commit to branch releases/12.7
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 803489b546ccee11ae482848a5236bb4981f0834
Author: lijianjun <[email protected]>
AuthorDate: Tue Jun 11 16:55:45 2024 +0800

    add mm_uninitialize empty implementation for sim
    
    Signed-off-by: lijianjun <[email protected]>
    Signed-off-by: Neo Xu <[email protected]>
---
 arch/sim/src/sim/sim_heap.c | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/arch/sim/src/sim/sim_heap.c b/arch/sim/src/sim/sim_heap.c
index a3ccb2bb40..a1e9b0842f 100644
--- a/arch/sim/src/sim/sim_heap.c
+++ b/arch/sim/src/sim/sim_heap.c
@@ -231,6 +231,31 @@ struct mm_heap_s *mm_initialize(const char *name,
   return heap;
 }
 
+/****************************************************************************
+ * Name: mm_uninitialize
+ *
+ * Description:
+ *   Uninitialize the selected heap data structures
+ *
+ * Input Parameters:
+ *   heap      - The selected heap
+ *
+ * Returned Value:
+ *   None
+ *
+ * Assumptions:
+ *
+ ****************************************************************************/
+
+void mm_uninitialize(struct mm_heap_s *heap)
+{
+#if defined(CONFIG_FS_PROCFS) && !defined(CONFIG_FS_PROCFS_EXCLUDE_MEMINFO)
+  procfs_unregister_meminfo(&heap->mm_procfs);
+#endif
+  mm_free_delaylist(heap);
+  host_free(heap);
+}
+
 /****************************************************************************
  * Name: mm_addregion
  *

Reply via email to