Skip to contentSkip to conversation

x86/microcode for v2.6.33

GIT PULL Ingo Molnar 1 participant 1 message Dec 3, 2009 x86

lore
Share & tools
lore
#0 lore raw

Linus,

Please pull the latest x86-microcode-for-linus git tree from:

git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git x86-microcode-for-linus

Thanks,

Ingo

------------------>
Andreas Herrmann (6):
x86, amd-ucode: Remove needless log messages
x86: ucode-amd: Load ucode-patches once and not separately of each CPU
x86: ucode-amd: Don't warn when no ucode is available for a CPU revision
x86: ucode-amd: Convert printk(KERN_*...) to pr_*(...)
x86, ucode-amd: Ensure ucode update on suspend/resume after CPU off/online cycle
x86: ucode-amd: Move family check to microcde_amd.c's init function

 arch/x86/include/asm/microcode.h |    2 +
 arch/x86/kernel/microcode_amd.c  |   87 ++++++++++++++++++++------------------
 arch/x86/kernel/microcode_core.c |    8 +++-
 3 files changed, 55 insertions(+), 42 deletions(-)
arch/x86/include/asm/microcode.h +2 -0
index ef51b50..c24ca9a 100644
@@ -12,6 +12,8 @@ struct device;
 enum ucode_state { UCODE_ERROR, UCODE_OK, UCODE_NFOUND };
 
 struct microcode_ops {
+	void (*init)(struct device *device);
+	void (*fini)(void);
 	enum ucode_state (*request_microcode_user) (int cpu,
 				const void __user *buf, size_t size);
 
arch/x86/kernel/microcode_amd.c +46 -41

186 lines not on this page · raw message

arch/x86/kernel/microcode_core.c +7 -1
index 378e9a8..adf2340 100644
@@ -393,7 +393,7 @@ static enum ucode_state microcode_update_cpu(int cpu)
 	struct ucode_cpu_info *uci = ucode_cpu_info + cpu;
 	enum ucode_state ustate;
 
-	if (uci->valid)
+	if (uci->valid && uci->mc)
 		ustate = microcode_resume_cpu(cpu);
 	else
 		ustate = microcode_init_cpu(cpu);
@@ -520,6 +520,9 @@ static int __init microcode_init(void)
 		return PTR_ERR(microcode_pdev);
 	}
 
+	if (microcode_ops->init)
+		microcode_ops->init(&microcode_pdev->dev);
+
 	get_online_cpus();
 	mutex_lock(&microcode_mutex);
 
@@ -563,6 +566,9 @@ static void __exit microcode_exit(void)
 
 	platform_device_unregister(microcode_pdev);
 
+	if (microcode_ops->fini)
+		microcode_ops->fini();
+
 	microcode_ops = NULL;
 
 	pr_info("Microcode Update Driver: v" MICROCODE_VERSION " removed.\n");