diff options
Diffstat (limited to 'nuttx/include')
-rw-r--r-- | nuttx/include/nuttx/arch.h | 9 | ||||
-rw-r--r-- | nuttx/include/nuttx/kthread.h | 17 | ||||
-rw-r--r-- | nuttx/include/nuttx/sched.h | 5 | ||||
-rw-r--r-- | nuttx/include/sched.h | 25 |
4 files changed, 2 insertions, 54 deletions
diff --git a/nuttx/include/nuttx/arch.h b/nuttx/include/nuttx/arch.h index cd4915411..724f59207 100644 --- a/nuttx/include/nuttx/arch.h +++ b/nuttx/include/nuttx/arch.h @@ -239,9 +239,7 @@ void up_initial_state(FAR struct tcb_s *tcb); * ****************************************************************************/ -#ifndef CONFIG_CUSTOM_STACK int up_create_stack(FAR struct tcb_s *tcb, size_t stack_size, uint8_t ttype); -#endif /**************************************************************************** * Name: up_use_stack @@ -272,9 +270,7 @@ int up_create_stack(FAR struct tcb_s *tcb, size_t stack_size, uint8_t ttype); * ****************************************************************************/ -#ifndef CONFIG_CUSTOM_STACK int up_use_stack(FAR struct tcb_s *tcb, FAR void *stack, size_t stack_size); -#endif /**************************************************************************** * Name: up_stack_frame @@ -308,8 +304,7 @@ int up_use_stack(FAR struct tcb_s *tcb, FAR void *stack, size_t stack_size); * ****************************************************************************/ -#if !defined(CONFIG_CUSTOM_STACK) && (defined(CONFIG_BUILD_PROTECTED) || \ - defined(CONFIG_BUILD_KERNEL)) +#if defined(CONFIG_BUILD_PROTECTED) || defined(CONFIG_BUILD_KERNEL) FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size); #endif @@ -344,9 +339,7 @@ FAR void *up_stack_frame(FAR struct tcb_s *tcb, size_t frame_size); * ****************************************************************************/ -#ifndef CONFIG_CUSTOM_STACK void up_release_stack(FAR struct tcb_s *dtcb, uint8_t ttype); -#endif /**************************************************************************** * Name: up_unblock_task diff --git a/nuttx/include/nuttx/kthread.h b/nuttx/include/nuttx/kthread.h index 7d840915c..01726f6f6 100644 --- a/nuttx/include/nuttx/kthread.h +++ b/nuttx/include/nuttx/kthread.h @@ -48,18 +48,6 @@ * Pre-Processor Definitions ****************************************************************************/ -/* One processor family supported by NuttX has a single, fixed hardware stack. - * That is the 8051 family. So for that family only, there is a variant form - * of kernel_thread() that does not take a stack size parameter. The following - * helper macro is provided to work around the ugliness of that exception. - */ - -#ifndef CONFIG_CUSTOM_STACK -# define KERNEL_THREAD(n,p,s,e,a) kernel_thread(n,p,s,e,a) -#else -# define KERNEL_THREAD(n,p,s,e,a) kernel_thread(n,p,e,a) -#endif - /**************************************************************************** * Public Data ****************************************************************************/ @@ -92,13 +80,8 @@ extern "C" * ********************************************************************************/ -#ifndef CONFIG_CUSTOM_STACK int kernel_thread(FAR const char *name, int priority, int stack_size, main_t entry, FAR char * const argv[]); -#else -int kernel_thread(FAR const char *name, int priority, main_t entry, - FAR char * const argv[]); -#endif #undef EXTERN #ifdef __cplusplus diff --git a/nuttx/include/nuttx/sched.h b/nuttx/include/nuttx/sched.h index 279abea95..40442cc87 100644 --- a/nuttx/include/nuttx/sched.h +++ b/nuttx/include/nuttx/sched.h @@ -482,7 +482,6 @@ struct tcb_s /* Stack-Related Fields *******************************************************/ -#ifndef CONFIG_CUSTOM_STACK size_t adj_stack_size; /* Stack size after adjustment */ /* for hardware, processor, etc. */ /* (for debug purposes only) */ @@ -490,7 +489,6 @@ struct tcb_s /* Need to deallocate stack */ FAR void *adj_stack_ptr; /* Adjusted stack_alloc_ptr for HW */ /* The initial stack pointer value */ -#endif /* External Module Support ****************************************************/ @@ -560,8 +558,7 @@ struct task_tcb_s uint8_t init_priority; /* Initial priority of the task */ -#if !defined(CONFIG_CUSTOM_STACK) && (defined(CONFIG_BUILD_PROTECTED) || \ - defined(CONFIG_BUILD_KERNEL)) +#if defined(CONFIG_BUILD_PROTECTED) || defined(CONFIG_BUILD_KERNEL) /* In the kernel mode build, the arguments are saved on the task's stack */ FAR char **argv; /* Name+start-up parameters */ diff --git a/nuttx/include/sched.h b/nuttx/include/sched.h index bb414b66d..96afbedb8 100644 --- a/nuttx/include/sched.h +++ b/nuttx/include/sched.h @@ -63,21 +63,6 @@ #define PTHREAD_KEYS_MAX CONFIG_NPTHREAD_KEYS -/* Non-standard Helper **********************************************************/ -/* One processor family supported by NuttX has a single, fixed hardware stack. - * That is the 8051 family. So for that family only, there is a variant form - * of task_create() that does not take a stack size parameter. The following - * helper macros are provided to work around the ugliness of that exception. - */ - -#ifndef CONFIG_CUSTOM_STACK -# define TASK_INIT(t,n,p,m,s,e,a) task_init(t,n,p,m,s,e,a) -# define TASK_CREATE(n,p,s,e,a) task_create(n,p,s,e,a) -#else -# define TASK_INIT(t,n,p,m,s,e,a) task_init(t,n,p,e,a) -# define TASK_CREATE(n,p,s,e,a) task_create(n,p,e,a) -#endif - /******************************************************************************** * Public Type Definitions ********************************************************************************/ @@ -109,22 +94,12 @@ extern "C" /* Task Control Interfaces (non-standard) */ -#ifndef CONFIG_CUSTOM_STACK int task_init(FAR struct tcb_s *tcb, const char *name, int priority, FAR uint32_t *stack, uint32_t stack_size, main_t entry, FAR char * const argv[]); -#else -int task_init(FAR struct tcb_s *tcb, const char *name, int priority, - main_t entry, FAR char * const argv[]); -#endif int task_activate(FAR struct tcb_s *tcb); -#ifndef CONFIG_CUSTOM_STACK int task_create(FAR const char *name, int priority, int stack_size, main_t entry, FAR char * const argv[]); -#else -int task_create(FAR const char *name, int priority, main_t entry, - FAR char * const argv[]); -#endif int task_delete(pid_t pid); int task_restart(pid_t pid); |