kernel: reduce scope of z_new_thread_init()

The core kernel z_setup_new_thread() calls into arch_new_thread(),
which calls back into the core kernel via z_new_thread_init().

Move everything that doesn't have to be in z_new_thread_init() to
z_setup_new_thread() and convert to an inline function.

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
Andrew Boie 2020-04-19 14:28:15 -07:00 committed by Anas Nashif
commit c0df99cc77
11 changed files with 45 additions and 62 deletions

View file

@ -22,7 +22,7 @@ void arch_new_thread(struct k_thread *thread, k_thread_stack_t *stack,
struct __esf *stack_init;
z_new_thread_init(thread, stack_memory, stack_size, priority, options);
z_new_thread_init(thread, stack_memory, stack_size);
/* Initial stack frame for thread */
stack_init = (struct __esf *)