lkml.org 
[lkml]   [2017]   [Dec]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v2] x86/microcode/intel: Blacklist the specific BDW-EP for late loading
From
Date


在 2017/12/25 下午9:34, Borislav Petkov 写道:
> + Tony.
>
> On Mon, Dec 25, 2017 at 03:49:29PM +0800, Jia Zhang wrote:
>> Instead of blacklisting all Broadwell processorsi for running a late
>> loading, only BDW-EP (signature 406f1) with the microcode version
>> less than 0x0b000021 needs to be blacklisted.
>>
>> This is documented in the the public documentation #334165 (See the
>> item BDF90 for details).
>>
>> Signed-off-by: Jia Zhang <qianyue.zj@alibaba-inc.com>
>> ---
>> arch/x86/kernel/cpu/microcode/intel.c | 11 +++++++++--
>> 1 file changed, 9 insertions(+), 2 deletions(-)
>>
>> diff --git a/arch/x86/kernel/cpu/microcode/intel.c b/arch/x86/kernel/cpu/microcode/intel.c
>> index 8ccdca6..f80b2dd 100644
>> --- a/arch/x86/kernel/cpu/microcode/intel.c
>> +++ b/arch/x86/kernel/cpu/microcode/intel.c
>> @@ -910,8 +910,15 @@ static bool is_blacklisted(unsigned int cpu)
>> {
>> struct cpuinfo_x86 *c = &cpu_data(cpu);
>>
>> - if (c->x86 == 6 && c->x86_model == INTEL_FAM6_BROADWELL_X) {
>> - pr_err_once("late loading on model 79 is disabled.\n");
>> + /*
>> + * The Broadwell-EP processor with the microcode version less
>> + * then 0x0b000021 may reault in system hang when running a late
>> + * loading. This behavior is documented in item BDF90, #334165
>> + * (Intel Xeon Processor E7-8800/4800 v4 Product Family).
>> + */
>> + if (c->x86 == 6 && c->x86_model == INTEL_FAM6_BROADWELL_X &&
>> + c->x86_mask == 0x01 && intel_get_microcode_revision() < 0x0b000021U) {
>
> Actually, you shouldn't need to call intel_get_microcode_revision() here
> as collect_cpu_info() has done that already and the revision is in
>
> c->microcode
>
> unless you're using the old method through do_microcode_update() and
> for that you'll need to call collect_cpu_info() over all CPUs in
> microcode_open().
>
> So how do you update your microcode?

I used the interface /sys/devices/system/cpu/microcode/reload, not
/dev/cpu/microcode.

Sound like using c->microcode is already enough. So I'm not sure why
calling collect_cpu_info() is necessary for the old method. c->microcode
can reflect the correct version as long as it always syncs up with the
recent loaded microcode update.

Thanks,
Jia

>

\
 
 \ /
  Last update: 2017-12-25 15:32    [W:0.206 / U:0.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site