x86, microcode, AMD: Extend ucode size verification
commit
44d60c0f5c58c2168f31df9a481761451840eb54 upstream.
The different families have a different max size for the ucode patch,
adjust size checking to the family we're running on. Also, do not
vzalloc the max size of the ucode but only the actual size that is
passed on from the firmware loader.
[PG: baseline of
44d60c0f5~1 differs in multiple trivial ways from
the 34's; this commit makes get_next_ucode() look like
44d60c0f5's]
Signed-off-by: Borislav Petkov <borislav.petkov@amd.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>