kernel/arch: remove unused uk_task_ptr parameter from _new_thread()

Artifact from microkernel, for handling multiple pending tasks on
nanokernel objects.

Change-Id: I3c2959ea2b87f568736384e6534ce8e275f1098f
Signed-off-by: Benjamin Walsh <benjamin.walsh@windriver.com>
This commit is contained in:
Benjamin Walsh 2016-11-19 12:31:53 -05:00 committed by Anas Nashif
commit 8fcc7f69da
7 changed files with 9 additions and 19 deletions

View file

@ -85,7 +85,7 @@ static ALWAYS_INLINE void thread_monitor_init(struct k_thread *thread)
* @return N/A
*/
void _new_thread(char *pStackMem, size_t stackSize,
void *uk_task_ptr, _thread_entry_t pEntry,
_thread_entry_t pEntry,
void *parameter1, void *parameter2, void *parameter3,
int priority, unsigned options)
{
@ -147,8 +147,6 @@ void _new_thread(char *pStackMem, size_t stackSize,
thread->entry = (struct __thread_entry *)(pInitCtx);
#endif
ARG_UNUSED(uk_task_ptr);
/*
* intlock_key is constructed based on ARCv2 ISA Programmer's
* Reference Manual CLRI instruction description:

View file

@ -81,7 +81,7 @@ static ALWAYS_INLINE void thread_monitor_init(struct tcs *tcs)
*/
void _new_thread(char *pStackMem, size_t stackSize,
void *uk_task_ptr, _thread_entry_t pEntry,
_thread_entry_t pEntry,
void *parameter1, void *parameter2, void *parameter3,
int priority, unsigned options)
{
@ -135,8 +135,6 @@ void _new_thread(char *pStackMem, size_t stackSize,
tcs->entry = (struct __thread_entry *)(pInitCtx);
#endif
ARG_UNUSED(uk_task_ptr);
tcs->callee_saved.psp = (uint32_t)pInitCtx;
tcs->arch.basepri = 0;

View file

@ -61,7 +61,7 @@ struct init_stack_frame {
void _new_thread(char *stack_memory, size_t stack_size,
void *uk_task_ptr, _thread_entry_t thread_func,
_thread_entry_t thread_func,
void *arg1, void *arg2, void *arg3,
int priority, unsigned options)
{
@ -99,8 +99,6 @@ void _new_thread(char *stack_memory, size_t stack_size,
/* Initialize custom data field (value is opaque to kernel) */
thread->custom_data = NULL;
#endif
ARG_UNUSED(uk_task_ptr);
thread->callee_saved.sp = (uint32_t)iframe;
thread->callee_saved.ra = (uint32_t)_thread_entry_wrapper;
thread->callee_saved.key = NIOS2_STATUS_PIE_MSK;

View file

@ -76,7 +76,7 @@ static ALWAYS_INLINE void thread_monitor_init(struct k_thread *thread)
* @return N/A
*/
static void _new_thread_internal(char *pStackMem, unsigned stackSize,
void *uk_task_ptr, int priority,
int priority,
unsigned options)
{
unsigned long *pInitialCtx;
@ -103,8 +103,6 @@ static void _new_thread_internal(char *pStackMem, unsigned stackSize,
thread->custom_data = NULL;
#endif
ARG_UNUSED(uk_task_ptr);
/*
* The creation of the initial stack for the task has already been done.
* Now all that is needed is to set the ESP. However, we have been passed
@ -246,7 +244,7 @@ __asm__("\t.globl _thread_entry\n"
* @return opaque pointer to initialized k_thread structure
*/
void _new_thread(char *pStackMem, size_t stackSize,
void *uk_task_ptr, _thread_entry_t pEntry,
_thread_entry_t pEntry,
void *parameter1, void *parameter2, void *parameter3,
int priority, unsigned options)
{
@ -308,5 +306,5 @@ void _new_thread(char *pStackMem, size_t stackSize,
* aside for the thread's stack.
*/
_new_thread_internal(pStackMem, stackSize, uk_task_ptr, priority, options);
_new_thread_internal(pStackMem, stackSize, priority, options);
}

View file

@ -57,7 +57,6 @@ extern void _thread_entry(void (*)(void *, void *, void *),
void *, void *, void *);
extern void _new_thread(char *pStack, size_t stackSize,
void *uk_task_ptr,
void (*pEntry)(void *, void *, void *),
void *p1, void *p2, void *p3,
int prio, unsigned options);

View file

@ -277,13 +277,13 @@ static void prepare_multithreading(struct k_thread *dummy_thread)
sys_dlist_init(&_ready_q.q[ii]);
}
_new_thread(main_stack, MAIN_STACK_SIZE, NULL,
_new_thread(main_stack, MAIN_STACK_SIZE,
_main, NULL, NULL, NULL,
CONFIG_MAIN_THREAD_PRIORITY, K_ESSENTIAL);
_mark_thread_as_started(_main_thread);
_add_thread_to_ready_q(_main_thread);
_new_thread(idle_stack, IDLE_STACK_SIZE, NULL,
_new_thread(idle_stack, IDLE_STACK_SIZE,
idle, NULL, NULL, NULL,
K_LOWEST_THREAD_PRIO, K_ESSENTIAL);
_mark_thread_as_started(_idle_thread);

View file

@ -239,7 +239,7 @@ k_tid_t k_thread_spawn(char *stack, size_t stack_size,
struct k_thread *new_thread = (struct k_thread *)stack;
_new_thread(stack, stack_size, NULL, entry, p1, p2, p3, prio, options);
_new_thread(stack, stack_size, entry, p1, p2, p3, prio, options);
schedule_new_thread(new_thread, delay);
@ -382,7 +382,6 @@ void _init_static_threads(void)
_new_thread(
thread_data->init_stack,
thread_data->init_stack_size,
NULL,
thread_data->init_entry,
thread_data->init_p1,
thread_data->init_p2,