[coreboot] Disabling hyper-threading on Ivy Bridge

Davíð Steinn Geirsson david at dsg.is
Sat Jan 13 17:42:26 CET 2018


Thanks Nico, this info is very helpful. I now know where to start reading.

Best regards,
Davíð

On Sat, Jan 13, 2018 at 05:13:01PM +0100, Nico Huber wrote:
> Hi Davíð,
> 
> On 13.01.2018 15:34, Davíð Steinn Geirsson wrote:
> > I am hoping to build coreboot with hyper-threading (SMT) disabled. I
> > guess this can be done by skipping over the right processor IDs in
> > the for loop in intel_cores_init in
> > src/cpu/intel/model_206ax/model_206ax_init.c:470 ?
> 
> no, you can't just ignore (logical) cores there. I suppose they would
> still be visible to the OS but not functional.
> 
> It seems the PCH is supposed to tell the CPU package after reset how
> many (logical) cores should be enabled. There is a register to override
> the settings: SOFT_RESET_DATA. Setting bit 0 in that register + a reset
> should disable hyper-threading.
> 
> Though, this register is already used in set_flex_ratio_to_tdp_nominal()
> in `src/cpu/intel/model_206ax/bootblock.c`.
> 
> You can check if hyper-threading is enabled by looking at MSR 0x35
> (CORE_THREAD_COUNT) or CPUID (eax 0x0b, ecx 0x00 / 0x01). Both should
> be documented in Intel's SDM [1].
> 
> You should combine the decision to disable HT with the already present
> code for the flex ratio. If any of the two settings need to change,
> program SOFT_RESET_DATA accordingly and perform a reset.
> 
> Hope that helps,
> Nico
> 
> -- 
> coreboot mailing list: coreboot at coreboot.org
> https://mail.coreboot.org/mailman/listinfo/coreboot



More information about the coreboot mailing list