summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-09-14 08:20:40 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-09-14 08:20:40 -0600
commit41832690401b99c2b3071d392ee4d8a0c915a344 (patch)
tree8212f2b55dab443a7ad2f49245c4a5c96e30625a
parentbb1d597d3bbb2f5823d7e15ce8495495d4c79a78 (diff)
downloadnuttx-41832690401b99c2b3071d392ee4d8a0c915a344.tar.gz
nuttx-41832690401b99c2b3071d392ee4d8a0c915a344.tar.bz2
nuttx-41832690401b99c2b3071d392ee4d8a0c915a344.zip
Kernel proxy thread should be a kernel thread, not a user task
-rw-r--r--nuttx/sched/task/task_posixspawn.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/nuttx/sched/task/task_posixspawn.c b/nuttx/sched/task/task_posixspawn.c
index 87d868093..a4e30f9fb 100644
--- a/nuttx/sched/task/task_posixspawn.c
+++ b/nuttx/sched/task/task_posixspawn.c
@@ -43,6 +43,7 @@
#include <spawn.h>
#include <debug.h>
+#include <nuttx/kthread.h>
#include <nuttx/binfmt/binfmt.h>
#include "sched/sched.h"
@@ -424,10 +425,10 @@ int posix_spawn(FAR pid_t *pid, FAR const char *path,
* task.
*/
- proxy = task_create("posix_spawn_proxy", param.sched_priority,
- CONFIG_POSIX_SPAWN_PROXY_STACKSIZE,
- (main_t)posix_spawn_proxy,
- (FAR char * const *)NULL);
+ proxy = kernel_thread("posix_spawn_proxy", param.sched_priority,
+ CONFIG_POSIX_SPAWN_PROXY_STACKSIZE,
+ (main_t)posix_spawn_proxy,
+ (FAR char * const *)NULL);
if (proxy < 0)
{
ret = get_errno();