You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2020/04/10 05:06:20 UTC

[GitHub] [incubator-nuttx] GUIDINGLI opened a new pull request #762: mm/mm_heap: fix mm_heap not support BUILD_FLAT

GUIDINGLI opened a new pull request #762: mm/mm_heap: fix mm_heap not support BUILD_FLAT
URL: https://github.com/apache/incubator-nuttx/pull/762
 
 
   1. change ifdef __KERNEL__ to:
      if defined(CONFIG_BUILD_FLAT) || defined(__KERNEL__)
   
   2. change mm_delaylist to *mm_delaylist
   
   3. change FAR struct mm_delaynode_s *new to:
      FAR struct mm_delaynode_s *tmp
   
   4. should check mm_trysemaphore() return values
   
   Change-Id: I57ba991f13c3eaf56dc2d71ac946c11669e32dfa
   Signed-off-by: ligd <li...@fishsemi.com>

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [incubator-nuttx] xiaoxiang781216 commented on a change in pull request #762: mm/mm_heap: fix mm_heap not support BUILD_FLAT

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 commented on a change in pull request #762: mm/mm_heap: fix mm_heap not support BUILD_FLAT
URL: https://github.com/apache/incubator-nuttx/pull/762#discussion_r406612501
 
 

 ##########
 File path: mm/mm_heap/mm_free.c
 ##########
 @@ -105,11 +107,11 @@ void mm_free(FAR struct mm_heap_s *heap, FAR void *mem)
       mm_add_delaylist(heap, mem);
       return;
     }
-  else if (mm_trysemaphore(heap) == 0)
+  else if ((ret = mm_trysemaphore(heap)) == 0)
     {
       /* Got the sem, do free immediately */
     }
-  else if (sched_idletask())
+  else if (ret == -ESRCH || sched_idletask())
     {
       /* We are in IDLE task & can't get sem, add to mm_delaylist */
 
 Review comment:
   Add some comment about ret == -ESRCH case?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [incubator-nuttx] patacongo merged pull request #762: mm/mm_heap: fix mm_heap not support BUILD_FLAT

Posted by GitBox <gi...@apache.org>.
patacongo merged pull request #762: mm/mm_heap: fix mm_heap not support BUILD_FLAT
URL: https://github.com/apache/incubator-nuttx/pull/762
 
 
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [incubator-nuttx] xiaoxiang781216 commented on issue #762: mm/mm_heap: fix mm_heap not support BUILD_FLAT

Posted by GitBox <gi...@apache.org>.
xiaoxiang781216 commented on issue #762: mm/mm_heap: fix mm_heap not support BUILD_FLAT
URL: https://github.com/apache/incubator-nuttx/pull/762#issuecomment-611903306
 
 
   LGTM.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services