You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "pussuw (via GitHub)" <gi...@apache.org> on 2023/02/02 21:08:03 UTC

[GitHub] [nuttx] pussuw commented on a diff in pull request #8355: arch/addrenv: Refactor address environment handling, by moving tg_addrenv out of the group structure

pussuw commented on code in PR #8355:
URL: https://github.com/apache/nuttx/pull/8355#discussion_r1095086783


##########
sched/sched/sched_releasetcb.c:
##########
@@ -154,7 +154,11 @@ int nxsched_release_tcb(FAR struct tcb_s *tcb, uint8_t ttype)
 #ifdef CONFIG_ARCH_ADDRENV
       /* Release this thread's reference to the address environment */
 
-      ret = up_addrenv_detach(tcb->group, tcb);
+      ret = up_addrenv_detach(tcb);
+      if (ttype == TCB_FLAG_TTYPE_TASK)

Review Comment:
   It is fixed by the reference counter in the second patch. I think the 1st patch on itself does not work properly, the reference counter is needed as well. If you think it is better to merge / squash the first 2 patches I can do that ?



-- 
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.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org