
Hi Bin,
On 29 Apr 2015 10:26 pm, "Simon Glass" sjg@chromium.org wrote:
This series adds a new CPU uclass which is intended to be useful on any architecture. So far it has a very simple interface and a command to show CPU details.
This series also introduces multi-core init for x86. It is implemented and enabled on Minnowboard MAX, a single/dual-core Atom board. The CPU uclass
is
implemented for x86 and the Simple Firmware Interface provides these
details
to the kernel, since ACPI is not yet available.
With these changes Minnowboard MAX can boot into Linux with both cores enabled.
This series is available at u-boot-x86 branch 'cpu-working'.
Changes in v3:
- Rename CONFIG_STACK_SIZE to CONFIG_AP_STACK_SIZE
- Remove sipi_vector_location and sipi_vector_location_size variables
- Remove annoying /* 1ms */ comments
- Rename sipi.S to sipi_vector.S
- Correct 'ap_start32' to 'ap_start'
- Use macros for cr0 bit fields
- Correct style in a multi-line comment
- Use UCODE_HEADER_LEN instead of 48
- Remove unnecessary underscores in MP_FR_BLOCK_APS and MP_FR_NOBLOCK_APS
- Use 'cpu number' instead of 'coreboot cpu number'
- Remove a stray blank line in sipi.h
- Enhance comment for @microcode_lock
- Rename SMM_DEFAULT_BASE/SIZE to AP_DEFAULT_BASE/SIZE and drop smm.h
- Use data32 instead of our own 'o32'
- Move NUM_FIXED_MTRRS to mtrr.h
- Avoid using asmlinkage on ap_init()
- Add msr_clrbits_64() too
- Collect all new MSRs into msr-index.h
- Spell 'BayTrail' like so
- Make set_max_freq() static
I did not sort out the secondary CPU init in this series. I will take a look.
Changes in v2:
- Correct 'I2C uclass' typo
- Add blank line in x86_cpu_get_desc()
Simon Glass (5): x86: Add multi-processor init x86: Add functions to set and clear bits on MSRs x86: Allow CPUs to be set up after relocation x86: Add a CPU driver for baytrail x86: Enable multi-core init for Minnowboard MAX
arch/x86/Kconfig | 30 ++ arch/x86/cpu/Makefile | 2 + arch/x86/cpu/baytrail/Makefile | 1 + arch/x86/cpu/baytrail/cpu.c | 205 +++++++++ arch/x86/cpu/cpu.c | 38 ++ arch/x86/cpu/ivybridge/car.S | 1 + arch/x86/cpu/ivybridge/model_206ax.c | 4 +- arch/x86/cpu/mp_init.c | 496
++++++++++++++++++++++
arch/x86/cpu/sipi_vector.S | 216 ++++++++++ arch/x86/dts/minnowmax.dts | 20 + arch/x86/include/asm/arch-ivybridge/microcode.h | 3 - arch/x86/include/asm/arch-ivybridge/model_206ax.h | 2 - arch/x86/include/asm/cpu.h | 14 + arch/x86/include/asm/mp.h | 94 ++++ arch/x86/include/asm/msr-index.h | 22 +- arch/x86/include/asm/msr.h | 28 ++ arch/x86/include/asm/mtrr.h | 6 +- arch/x86/include/asm/processor.h | 3 + arch/x86/include/asm/sipi.h | 86 ++++ arch/x86/include/asm/turbo.h | 3 - arch/x86/include/asm/u-boot-x86.h | 2 + common/board_r.c | 2 +- configs/minnowmax_defconfig | 4 + 23 files changed, 1268 insertions(+), 14 deletions(-) create mode 100644 arch/x86/cpu/baytrail/cpu.c create mode 100644 arch/x86/cpu/mp_init.c create mode 100644 arch/x86/cpu/sipi_vector.S create mode 100644 arch/x86/include/asm/mp.h create mode 100644 arch/x86/include/asm/sipi.h
-- 2.2.0.rc0.207.ga3a616c
Regards, Simon