[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <878ra1ejo3.ffs@tglx>
Date: Wed, 23 Aug 2023 19:46:20 +0200
From: Thomas Gleixner <tglx@...utronix.de>
To: Qiuxu Zhuo <qiuxu.zhuo@...el.com>
Cc: arjan@...ux.intel.com, ashok.raj@...el.com, bp@...en8.de,
linux-kernel@...r.kernel.org, nik.borisov@...e.com, x86@...nel.org,
qiuxu.zhuo@...el.com
Subject: Re: [patch V2 03/37] x86/microcode/intel: Move microcode functions
out of cpu/intel.c
On Wed, Aug 23 2023 at 20:51, Qiuxu Zhuo wrote:
>> -#define get_totalsize(mc) \
>> - (((struct microcode_intel *)mc)->hdr.datasize ? \
>> - ((struct microcode_intel *)mc)->hdr.totalsize : \
>> - DEFAULT_UCODE_TOTALSIZE)
>> +#define DEFAULT_UCODE_DATASIZE (2000)
>>
>> ...
>> +
>> +static inline unsigned int get_totalsize(struct microcode_header_intel *hdr)
>> +{
>> + return hdr->datasize ? : DEFAULT_UCODE_TOTALSIZE;
>
> I tested this patch series and observed that the inline code above failed
> the late microcode loading with the error message:
>
> [ 117.100299] microcode: Error: bad microcode data file size.
>
> According to the original get_totalsize() macro, seems like it should be:
>
> return hdr->datasize ? hdr->totalsize : DEFAULT_UCODE_TOTALSIZE;
>
> With this minor change, the late microcode loading was successful, and the
> expected message was displayed:
Yes. I messed that up. Borislav already fixed it up when applying the
first 9 patches.
Powered by blists - more mailing lists