Re: [PATCH v5 4/6] x86/microcode/AMD: Check microcode container data in the late loader

From: Borislav Petkov
Date: Mon May 07 2018 - 12:35:51 EST


On Fri, May 04, 2018 at 01:26:50AM +0200, Maciej S. Szmigiero wrote:
> Here we return this variable, implicitly converting it into a
> (signed) int.
> Any value above INT_MAX will wrap around to a negative pseudo-error
> code (which might not match any actual error number).

If you want to widen the return type and do proper checking then have
the function return int which denotes success (0) or negative on
error and then return crnt_size through an u32 * arg.

All this in a separate patch with properly explained situation in the
commit message.

Thx.

--
Regards/Gruss,
Boris.

Good mailing practices for 400: avoid top-posting and trim the reply.