diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2013-01-17 00:30:12 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2013-01-17 00:30:12 +0000 |
commit | 4f0e8b1249c1550bac83f9db61c67094bc6afc2d (patch) | |
tree | 039d43ce0b08169a020076ccc59ee70b2e80c771 /nuttx/binfmt/binfmt_exec.c | |
parent | a0d71b94386f014bdeff6be77b7444438f867bbd (diff) | |
download | px4-nuttx-4f0e8b1249c1550bac83f9db61c67094bc6afc2d.tar.gz px4-nuttx-4f0e8b1249c1550bac83f9db61c67094bc6afc2d.tar.bz2 px4-nuttx-4f0e8b1249c1550bac83f9db61c67094bc6afc2d.zip |
Change the way thread priority is handled in binfmt/ to better match the way that priority is set up for the builtin tasks
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5527 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/binfmt/binfmt_exec.c')
-rw-r--r-- | nuttx/binfmt/binfmt_exec.c | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/nuttx/binfmt/binfmt_exec.c b/nuttx/binfmt/binfmt_exec.c index d5e274710..d878c8cc5 100644 --- a/nuttx/binfmt/binfmt_exec.c +++ b/nuttx/binfmt/binfmt_exec.c @@ -40,7 +40,6 @@ #include <nuttx/config.h> #include <string.h> -#include <sched.h> #include <debug.h> #include <errno.h> @@ -75,8 +74,7 @@ * * Description: * This is a convenience function that wraps load_ and exec_module into - * one call. The priority of the executed program is set to be the - * same as the priority of the calling thread. + * one call. * * Input Parameter: * filename - Fulll path to the binary to be loaded @@ -95,18 +93,8 @@ int exec(FAR const char *filename, FAR const char **argv, FAR const struct symtab_s *exports, int nexports) { struct binary_s bin; - struct sched_param param; int ret; - /* Get the priority of this thread */ - - ret = sched_getparam(0, ¶m); - if (ret < 0) - { - bdbg("ERROR: sched_getparam failed: %d\n", errno); - return ERROR; - } - /* Load the module into memory */ memset(&bin, 0, sizeof(struct binary_s)); @@ -121,9 +109,9 @@ int exec(FAR const char *filename, FAR const char **argv, return ERROR; } - /* Then start the module at the priority of this thread */ + /* Then start the module */ - ret = exec_module(&bin, param.sched_priority); + ret = exec_module(&bin); if (ret < 0) { bdbg("ERROR: Failed to execute program '%s'\n", filename); |