x86/microcode/intel: Add hdr_type to intel_microcode_sanity_check()
authorJithu Joseph <jithu.joseph@intel.com>
Thu, 17 Nov 2022 03:59:27 +0000 (19:59 -0800)
committerBorislav Petkov <bp@suse.de>
Fri, 18 Nov 2022 21:08:19 +0000 (22:08 +0100)
commite0788c3281a72386e75b53a010de4bfbac7e80db
tree12928b47588bc1e9d2b53aa75b37a51030e06903
parent514ee839c6d0750c1c4456502e6fa08599e57931
x86/microcode/intel: Add hdr_type to intel_microcode_sanity_check()

IFS test images and microcode blobs use the same header format.
Microcode blobs use header type of 1, whereas IFS test images
will use header type of 2.

In preparation for IFS reusing intel_microcode_sanity_check(),
add header type as a parameter for sanity check.

  [ bp: Touchups. ]

Signed-off-by: Jithu Joseph <jithu.joseph@intel.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Reviewed-by: Tony Luck <tony.luck@intel.com>
Reviewed-by: Ashok Raj <ashok.raj@intel.com>
Link: https://lore.kernel.org/r/20221117035935.4136738-9-jithu.joseph@intel.com
arch/x86/include/asm/cpu.h
arch/x86/include/asm/microcode_intel.h
arch/x86/kernel/cpu/intel.c
arch/x86/kernel/cpu/microcode/intel.c