You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by gn...@apache.org on 2020/06/15 13:10:02 UTC

[incubator-nuttx] branch master updated: sched/group: Change group_kill_children's argument from task_tcb_s to tcb_s

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

gnutt pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git


The following commit(s) were added to refs/heads/master by this push:
     new 5785340  sched/group: Change group_kill_children's argument from task_tcb_s to tcb_s
5785340 is described below

commit 5785340e0455b07c26d4f93c334847aeb5755a94
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Wed Jun 3 19:33:56 2020 +0800

    sched/group: Change group_kill_children's argument from task_tcb_s to tcb_s
    
    Signed-off-by: Xiang Xiao <xi...@xiaomi.com>
    Change-Id: I8fee46e75bd192bbaa6b03db8fc4d5dd60c58b10
---
 sched/group/group.h              | 2 +-
 sched/group/group_killchildren.c | 6 +++---
 sched/signal/sig_default.c       | 2 +-
 sched/task/exit.c                | 2 +-
 sched/task/task_restart.c        | 2 +-
 5 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/sched/group/group.h b/sched/group/group.h
index a16f917..6323f07 100644
--- a/sched/group/group.h
+++ b/sched/group/group.h
@@ -101,7 +101,7 @@ FAR struct task_group_s *group_findby_grpid(grpid_t grpid);
 FAR struct task_group_s *group_findbypid(pid_t pid);
 int group_foreachchild(FAR struct task_group_s *group,
                        foreachchild_t handler, FAR void *arg);
-int group_kill_children(FAR struct task_tcb_s *tcb);
+int group_kill_children(FAR struct tcb_s *tcb);
 #ifdef CONFIG_SIG_SIGSTOP_ACTION
 int group_suspend_children(FAR struct tcb_s *tcb);
 int group_continue(FAR struct tcb_s *tcb);
diff --git a/sched/group/group_killchildren.c b/sched/group/group_killchildren.c
index 51beb9a..86a7bf9 100644
--- a/sched/group/group_killchildren.c
+++ b/sched/group/group_killchildren.c
@@ -127,7 +127,7 @@ static int group_kill_children_handler(pid_t pid, FAR void *arg)
  *
  ****************************************************************************/
 
-int group_kill_children(FAR struct task_tcb_s *tcb)
+int group_kill_children(FAR struct tcb_s *tcb)
 {
   int ret;
 
@@ -136,8 +136,8 @@ int group_kill_children(FAR struct task_tcb_s *tcb)
    */
 
   sched_lock();
-  ret = group_foreachchild(tcb->cmn.group, group_kill_children_handler,
-                           (FAR void *)((uintptr_t)tcb->cmn.pid));
+  ret = group_foreachchild(tcb->group, group_kill_children_handler,
+                           (FAR void *)((uintptr_t)tcb->pid));
   sched_unlock();
   return ret;
 }
diff --git a/sched/signal/sig_default.c b/sched/signal/sig_default.c
index d53f1db..28bad31 100644
--- a/sched/signal/sig_default.c
+++ b/sched/signal/sig_default.c
@@ -273,7 +273,7 @@ static void nxsig_abnormal_termination(int signo)
    * task group if this_task is a pthread.
    */
 
-  group_kill_children((FAR struct task_tcb_s *)rtcb);
+  group_kill_children(rtcb);
 #endif
 
 #ifndef CONFIG_DISABLE_PTHREAD
diff --git a/sched/task/exit.c b/sched/task/exit.c
index 90c6c21..3d9f5ec 100644
--- a/sched/task/exit.c
+++ b/sched/task/exit.c
@@ -83,7 +83,7 @@ void exit(int status)
    * exit through a different mechanism.
    */
 
-  group_kill_children((FAR struct task_tcb_s *)tcb);
+  group_kill_children(tcb);
 #endif
 
   /* Perform common task termination logic.  This will get called again later
diff --git a/sched/task/task_restart.c b/sched/task/task_restart.c
index 097a799..8cad71e 100644
--- a/sched/task/task_restart.c
+++ b/sched/task/task_restart.c
@@ -126,7 +126,7 @@ int task_restart(pid_t pid)
   /* Kill any children of this thread */
 
 #ifdef HAVE_GROUP_MEMBERS
-  group_kill_children(tcb);
+  group_kill_children((FAR struct tcb_s *)tcb);
 #endif
 
   /* Remove the TCB from whatever list it is in.  After this point, the TCB