aboutsummaryrefslogtreecommitdiff
path: root/nuttx/sched
diff options
context:
space:
mode:
authorpatacongo <patacongo@7fd9a85b-ad96-42d3-883c-3090e2eb8679>2012-04-23 16:49:15 +0000
committerpatacongo <patacongo@7fd9a85b-ad96-42d3-883c-3090e2eb8679>2012-04-23 16:49:15 +0000
commit6d6976b06ecf8fce78aea24d9664da0533514b2e (patch)
tree8db7dff83d22e1007ac3aba5ea1b1542bff9f668 /nuttx/sched
parent09eac48792417206230798528de54a7d1c349f1d (diff)
downloadpx4-firmware-6d6976b06ecf8fce78aea24d9664da0533514b2e.tar.gz
px4-firmware-6d6976b06ecf8fce78aea24d9664da0533514b2e.tar.bz2
px4-firmware-6d6976b06ecf8fce78aea24d9664da0533514b2e.zip
Rename some USB device files
git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@4645 7fd9a85b-ad96-42d3-883c-3090e2eb8679
Diffstat (limited to 'nuttx/sched')
-rw-r--r--nuttx/sched/task_delete.c7
-rw-r--r--nuttx/sched/task_exithook.c4
2 files changed, 7 insertions, 4 deletions
diff --git a/nuttx/sched/task_delete.c b/nuttx/sched/task_delete.c
index e5244a0b8..5448260d5 100644
--- a/nuttx/sched/task_delete.c
+++ b/nuttx/sched/task_delete.c
@@ -179,6 +179,13 @@ int task_delete(pid_t pid)
sched_unlock();
+ /* Since all tasks pass through this function as the final step in their
+ * exit sequence, this is an appropriate place to inform any instrumentation
+ * layer that the task no longer exists.
+ */
+
+ sched_note_stop(tcb);
+
/* Deallocate its TCB */
sched_releasetcb(dtcb);
diff --git a/nuttx/sched/task_exithook.c b/nuttx/sched/task_exithook.c
index e160a1cb3..500129382 100644
--- a/nuttx/sched/task_exithook.c
+++ b/nuttx/sched/task_exithook.c
@@ -102,10 +102,6 @@
void task_exithook(FAR _TCB *tcb, int status)
{
- /* Inform the instrumentation layer that the task has stopped */
-
- sched_note_stop(tcb);
-
/* If an exit function was registered, call it now before we do any un-
* initialized. NOTE: In the case of task_delete(), the exit function
* will *not* be called on the thread execution of the task being deleted!