arch/x86: (Intel64) use per-CPU parameter struct for CPU startup
A new 'struct x86_cpuboot' is created as well as an instance called 'x86_cpuboot[]' which contains per-CPU boot data (initial stack, entry function/arg, selectors, etc.). The locore now consults this table to set up per-CPU registers, etc. during early boot. Also, rename tss.c to cpu.c as its scope is growing. Signed-off-by: Charles E. Youse <charles.youse@intel.com>
This commit is contained in:
parent
edf5761c83
commit
f9eaee35b8
5 changed files with 46 additions and 10 deletions
|
@ -1,20 +0,0 @@
|
|||
/*
|
||||
* Copyright (c) 2019 Intel Corporation
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
|
||||
#include <kernel.h>
|
||||
#include <kernel_arch_data.h>
|
||||
#include <kernel_arch_func.h>
|
||||
#include <kernel_structs.h>
|
||||
|
||||
extern u8_t _exception_stack[];
|
||||
|
||||
Z_GENERIC_SECTION(.tss)
|
||||
struct x86_tss64 tss0 = {
|
||||
.ist1 = (u64_t) _interrupt_stack + CONFIG_ISR_STACK_SIZE,
|
||||
.ist7 = (u64_t) _exception_stack + CONFIG_EXCEPTION_STACK_SIZE,
|
||||
.iomapb = 0xFFFF, /* no I/O access bitmap */
|
||||
|
||||
.cpu = &(_kernel.cpus[0])
|
||||
};
|
Loading…
Add table
Add a link
Reference in a new issue