u-boot-brain/arch/x86/cpu
Bin Meng 002610f620 x86: fsp: Load GDT before calling FspInitEntry
Currently the FSP execution environment GDT is setup by U-Boot in
arch/x86/cpu/start16.S, which works pretty well. But if we try to
move the FspInitEntry call a little bit later to better fit into
U-Boot's initialization sequence, FSP will fail to bring up the AP
due to #GP fault as AP's GDT is duplicated from BSP whose GDT is
now moved into CAR, and unfortunately FSP calls AP initialization
after it disables the CAR. So basically the BSP's GDT still refers
to the one in the CAR, whose content is no longer available, so
when AP starts up and loads its segment register, it blows up.

To resolve this, we load GDT before calling into FspInitEntry.
The GDT is the same one used in arch/x86/cpu/start16.S, which is
in the ROM and exists forever.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Tested-by: Andrew Bradford <andrew.bradford@kodakalaris.com>
Tested-by: Simon Glass <sjg@chromium.org>
Acked-by: Simon Glass <sjg@chromium.org>
2015-07-14 18:03:15 -06:00
..
baytrail x86: baytrail: pci region 3 is not always mapped to end of ram 2015-06-04 03:03:18 -06:00
coreboot x86: qemu: Implement PIRQ routing 2015-06-04 03:03:18 -06:00
ivybridge x86: Add multi-processor init 2015-04-30 16:13:38 -06:00
qemu x86: qemu: Implement PIRQ routing 2015-06-04 03:03:18 -06:00
quark x86: quark: Implement PIRQ routing 2015-06-04 02:39:39 -06:00
queensbay x86: Refactor PIRQ routing support 2015-06-04 02:39:39 -06:00
call64.S x86: Add support for starting 64-bit kernel 2014-10-28 20:43:47 -06:00
config.mk x86: Add Kconfig options to be used by arch/x86/cpu/config.mk 2015-07-14 18:03:15 -06:00
cpu.c x86: fsp: Load GDT before calling FspInitEntry 2015-07-14 18:03:15 -06:00
interrupts.c x86: Provide access to the IDT 2015-04-29 21:02:34 -06:00
irq.c x86: Do sanity test on pirq table before writing 2015-06-04 02:39:39 -06:00
lapic.c x86: Add LAPIC setup code 2014-11-25 06:34:11 -07:00
Makefile x86: Refactor PIRQ routing support 2015-06-04 02:39:39 -06:00
mp_init.c x86: Add multi-processor init 2015-04-30 16:13:38 -06:00
mtrr.c x86: Test mtrr support flag before accessing mtrr msr 2015-01-23 17:24:55 -07:00
pci.c x86: Add a function to assign IRQ numbers to PCI device 2015-04-29 18:51:49 -06:00
resetvec.S Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
sipi_vector.S x86: Add multi-processor init 2015-04-30 16:13:38 -06:00
start16.S x86: fsp: Load GDT before calling FspInitEntry 2015-07-14 18:03:15 -06:00
start.S remove unnecessary version.h includes 2015-03-24 10:50:50 -04:00
turbo.c x86: Add Intel speedstep and turbo mode code 2014-11-25 06:34:02 -07:00
u-boot.lds x86: Factor out common values in the link script 2014-11-25 06:33:59 -07:00