[U-Boot] [PATCH v4 4/6] x86: Move lapic_setup() call into init_bsp()
Bin Meng
bmeng.cn at gmail.com
Wed Jun 17 05:15:37 CEST 2015
Currently lapic_setup() is called before calling mp_init(), which
then calls init_bsp() where it calls enable_lapic(), which was
already enabled in lapic_setup(). Hence move lapic_setup() call
into init_bsp() to avoid the duplication.
Signed-off-by: Bin Meng <bmeng.cn at gmail.com>
Acked-by: Simon Glass <sjg at chromium.org>
---
Changes in v4: None
Changes in v3: None
Changes in v2: None
arch/x86/cpu/cpu.c | 2 --
arch/x86/cpu/mp_init.c | 2 +-
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/arch/x86/cpu/cpu.c b/arch/x86/cpu/cpu.c
index a6e88cf..d108ee5 100644
--- a/arch/x86/cpu/cpu.c
+++ b/arch/x86/cpu/cpu.c
@@ -640,8 +640,6 @@ static int x86_mp_init(void)
{
struct mp_params mp_params;
- lapic_setup();
-
mp_params.parallel_microcode_load = 0,
mp_params.flight_plan = &mp_steps[0];
mp_params.num_records = ARRAY_SIZE(mp_steps);
diff --git a/arch/x86/cpu/mp_init.c b/arch/x86/cpu/mp_init.c
index 5564d84..e8bc9b6 100644
--- a/arch/x86/cpu/mp_init.c
+++ b/arch/x86/cpu/mp_init.c
@@ -418,7 +418,7 @@ static int init_bsp(struct udevice **devp)
cpu_get_name(processor_name);
debug("CPU: %s.\n", processor_name);
- enable_lapic();
+ lapic_setup();
apic_id = lapicid();
ret = find_cpu_by_apid_id(apic_id, devp);
--
1.8.2.1
More information about the U-Boot
mailing list