aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/cpu/microcode/core.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2019-05-06 16:37:43 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2019-05-06 16:37:43 -0700
commitfdafe5d1ffe8021704cb389e9823aef4235c88bc (patch)
treece7086715870aa49c8420669f340e2b612f1abba /arch/x86/kernel/cpu/microcode/core.c
parentMerge branch 'x86-topology-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip (diff)
parentx86/microcode: Deprecate MICROCODE_OLD_INTERFACE (diff)
downloadlinux-dev-fdafe5d1ffe8021704cb389e9823aef4235c88bc.tar.xz
linux-dev-fdafe5d1ffe8021704cb389e9823aef4235c88bc.zip
Merge branch 'x86-microcode-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Pull x86 microcode loading update from Borislav Petkov: "A nice Intel microcode blob loading cleanup which gets rid of the ugly memcpy wrappers and switches the driver to use the iov_iter API. By Jann Horn. In addition, the /dev/cpu/microcode interface is finally deprecated as it is inadequate for the same reasons the late microcode loading is" * 'x86-microcode-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: x86/microcode: Deprecate MICROCODE_OLD_INTERFACE x86/microcode: Fix the ancient deprecated microcode loading method x86/microcode/intel: Refactor Intel microcode blob loading
Diffstat (limited to 'arch/x86/kernel/cpu/microcode/core.c')
-rw-r--r--arch/x86/kernel/cpu/microcode/core.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/x86/kernel/cpu/microcode/core.c b/arch/x86/kernel/cpu/microcode/core.c
index 5260185cbf7b..8a4a7823451a 100644
--- a/arch/x86/kernel/cpu/microcode/core.c
+++ b/arch/x86/kernel/cpu/microcode/core.c
@@ -418,8 +418,9 @@ static int do_microcode_update(const void __user *buf, size_t size)
if (ustate == UCODE_ERROR) {
error = -1;
break;
- } else if (ustate == UCODE_OK)
+ } else if (ustate == UCODE_NEW) {
apply_microcode_on_target(cpu);
+ }
}
return error;