Commit 41acc109 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'x86_microcode_for_v5.13' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull x86 microcode update from Borislav Petkov:
 "A single fix to the late microcode loading machinery which corrects
  the ordering of when new microcode is loaded from the fs, vs checking
  whether all CPUs are online"

* tag 'x86_microcode_for_v5.13' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86/microcode: Check for offline CPUs before requesting new microcode
parents a4a78bc8 7189b3c1
...@@ -629,16 +629,16 @@ static ssize_t reload_store(struct device *dev, ...@@ -629,16 +629,16 @@ static ssize_t reload_store(struct device *dev,
if (val != 1) if (val != 1)
return size; return size;
tmp_ret = microcode_ops->request_microcode_fw(bsp, &microcode_pdev->dev, true);
if (tmp_ret != UCODE_NEW)
return size;
get_online_cpus(); get_online_cpus();
ret = check_online_cpus(); ret = check_online_cpus();
if (ret) if (ret)
goto put; goto put;
tmp_ret = microcode_ops->request_microcode_fw(bsp, &microcode_pdev->dev, true);
if (tmp_ret != UCODE_NEW)
goto put;
mutex_lock(&microcode_mutex); mutex_lock(&microcode_mutex);
ret = microcode_reload_late(); ret = microcode_reload_late();
mutex_unlock(&microcode_mutex); mutex_unlock(&microcode_mutex);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment