mirror of
https://github.com/apache/nuttx.git
synced 2026-05-26 10:46:28 +08:00
Squashed commit of the following:
task_spawn() and posix_spawn() are NuttX OS interfaces. In PROTECTED and KERNEL build modes, then can be reached from applications only via a system call. Currently, the number of parameters in a system call is limited to six; these spawn function have seven parameters. Rather than extend the maximum number of parameters across all architectures, I opted instead to marshal the seven parameters into a structure.
*
In order to support builtin in function in protected mode, a task_spawn() system call must be supported. Unfortunately this is overly complex because there is a (soft) limit of 6 parameters in a system call; task_spawn has seven paramters. This is a soft limit but still difficult to extend because it involves assembly language changes to numerous architectures. Better to get more creative.
This commit is contained in:
@@ -128,7 +128,8 @@
|
||||
|
||||
#ifndef CONFIG_BUILD_KERNEL
|
||||
# define SYS_task_create __SYS_task_create
|
||||
# define __SYS_task_delete (__SYS_task_create + 1)
|
||||
# define SYS_nx_task_spawn (__SYS_task_create + 1)
|
||||
# define __SYS_task_delete (__SYS_task_create + 2)
|
||||
|
||||
/* pgalloc() is only available with address environments with the page
|
||||
* allocator selected. MMU support from the CPU is also required.
|
||||
|
||||
Reference in New Issue
Block a user