summaryrefslogtreecommitdiff
path: root/drivers/platform
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2023-10-18 00:23:45 +0300
committerBorislav Petkov (AMD) <bp@alien8.de>2023-10-24 16:05:53 +0300
commit164aa1ca537238c46923ccacd8995b4265aee47b (patch)
tree1fb10298457f810272f21e867973b09d0480414a /drivers/platform
parent3973718cff1e3a5d88ea78ec28ecca2afa60b30b (diff)
downloadlinux-164aa1ca537238c46923ccacd8995b4265aee47b.tar.xz
x86/microcode/intel: Rework intel_cpu_collect_info()
Nothing needs struct ucode_cpu_info. Make it take struct cpu_signature, let it return a boolean and simplify the implementation. Rename it now that the silly name clash with collect_cpu_info() is gone. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de> Link: https://lore.kernel.org/r/20231017211722.851573238@linutronix.de
Diffstat (limited to 'drivers/platform')
-rw-r--r--drivers/platform/x86/intel/ifs/load.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/platform/x86/intel/ifs/load.c b/drivers/platform/x86/intel/ifs/load.c
index cefd0d886cfd..61174bd48fd5 100644
--- a/drivers/platform/x86/intel/ifs/load.c
+++ b/drivers/platform/x86/intel/ifs/load.c
@@ -227,7 +227,7 @@ out:
static int image_sanity_check(struct device *dev, const struct microcode_header_intel *data)
{
- struct ucode_cpu_info uci;
+ struct cpu_signature sig;
/* Provide a specific error message when loading an older/unsupported image */
if (data->hdrver != MC_HEADER_TYPE_IFS) {
@@ -240,11 +240,9 @@ static int image_sanity_check(struct device *dev, const struct microcode_header_
return -EINVAL;
}
- intel_cpu_collect_info(&uci);
+ intel_collect_cpu_info(&sig);
- if (!intel_find_matching_signature((void *)data,
- uci.cpu_sig.sig,
- uci.cpu_sig.pf)) {
+ if (!intel_find_matching_signature((void *)data, sig.sig, sig.pf)) {
dev_err(dev, "cpu signature, processor flags not matching\n");
return -EINVAL;
}