binfmt: Move argv copy into exec_module

and remove the related fields from struct binary_s

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
Xiang Xiao
2021-05-24 15:06:29 +08:00
committed by Masayuki Ishikawa
parent a54fe4ee1e
commit cf78a5b6cf
7 changed files with 44 additions and 74 deletions
+1 -7
View File
@@ -64,12 +64,6 @@ struct binary_s
/* Information provided to the loader to load and bind a module */
FAR const char *filename; /* Full path to the binary to be loaded (See NOTE 1 above) */
#if defined(CONFIG_ARCH_ADDRENV) && defined(CONFIG_BUILD_KERNEL)
FAR char *argbuffer; /* Allocated argument list */
FAR char **argv; /* Copy of argument list */
#else
FAR char * const *argv; /* Argument list */
#endif
FAR const struct symtab_s *exports; /* Table of exported symbols */
int nexports; /* The number of symbols in exports[] */
@@ -234,7 +228,7 @@ int unload_module(FAR struct binary_s *bin);
*
****************************************************************************/
int exec_module(FAR const struct binary_s *bin);
int exec_module(FAR const struct binary_s *binp, FAR char * const *argv);
/****************************************************************************
* Name: exec