aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kernel/microcode.c4
-rw-r--r--arch/x86/kernel/microcode_amd.c6
-rw-r--r--arch/x86/kernel/microcode_intel.c4
3 files changed, 7 insertions, 7 deletions
diff --git a/arch/x86/kernel/microcode.c b/arch/x86/kernel/microcode.c
index 902dada2eb6d..0c2634f4fd7c 100644
--- a/arch/x86/kernel/microcode.c
+++ b/arch/x86/kernel/microcode.c
@@ -70,8 +70,6 @@
70 * Fix sigmatch() macro to handle old CPUs with pf == 0. 70 * Fix sigmatch() macro to handle old CPUs with pf == 0.
71 * Thanks to Stuart Swales for pointing out this bug. 71 * Thanks to Stuart Swales for pointing out this bug.
72 */ 72 */
73
74/* #define DEBUG pr_debug */
75#include <linux/capability.h> 73#include <linux/capability.h>
76#include <linux/kernel.h> 74#include <linux/kernel.h>
77#include <linux/init.h> 75#include <linux/init.h>
@@ -396,7 +394,7 @@ static int mc_sysdev_resume(struct sys_device *dev)
396 394
397 if (!cpu_online(cpu)) 395 if (!cpu_online(cpu))
398 return 0; 396 return 0;
399 pr_debug("microcode: CPU%d resumed\n", cpu); 397
400 /* only CPU 0 will apply ucode here */ 398 /* only CPU 0 will apply ucode here */
401 microcode_update_cpu(0); 399 microcode_update_cpu(0);
402 return 0; 400 return 0;
diff --git a/arch/x86/kernel/microcode_amd.c b/arch/x86/kernel/microcode_amd.c
index 6815837a7753..48aec9f48e4f 100644
--- a/arch/x86/kernel/microcode_amd.c
+++ b/arch/x86/kernel/microcode_amd.c
@@ -92,7 +92,7 @@ static int get_matching_microcode(int cpu, void *mc, int rev)
92 unsigned int i = 0; 92 unsigned int i = 0;
93 93
94 /* 94 /*
95 * dimm: do we need this? Why an update via /dev/... is different 95 * FIXME! dimm: do we need this? Why an update via /dev/... is different
96 * from the one via firmware? 96 * from the one via firmware?
97 * 97 *
98 * This is a tricky part. We might be called from a write operation 98 * This is a tricky part. We might be called from a write operation
@@ -246,7 +246,7 @@ static void * get_next_ucode(u8 *buf, unsigned int size,
246 return NULL; 246 return NULL;
247 } 247 }
248 248
249 /* Why not by means of get_totalsize(hdr)? */ 249 /* FIXME! dimm: Why not by means of get_totalsize(hdr)? */
250 total_size = (unsigned long) (hdr[4] + (hdr[5] << 8)); 250 total_size = (unsigned long) (hdr[4] + (hdr[5] << 8));
251 251
252 printk(KERN_INFO "microcode: size %u, total_size %u\n", 252 printk(KERN_INFO "microcode: size %u, total_size %u\n",
@@ -342,6 +342,8 @@ static int generic_load_microcode(int cpu, void *data, size_t size,
342 342
343 mc_header = (struct microcode_header_amd *)mc; 343 mc_header = (struct microcode_header_amd *)mc;
344 if (get_matching_microcode(cpu, mc, new_rev)) { 344 if (get_matching_microcode(cpu, mc, new_rev)) {
345 if (new_mc)
346 vfree(new_mc);
345 new_rev = mc_header->patch_id; 347 new_rev = mc_header->patch_id;
346 new_mc = mc; 348 new_mc = mc;
347 } else 349 } else
diff --git a/arch/x86/kernel/microcode_intel.c b/arch/x86/kernel/microcode_intel.c
index f4930b55c6a0..48ed3cef58c1 100644
--- a/arch/x86/kernel/microcode_intel.c
+++ b/arch/x86/kernel/microcode_intel.c
@@ -70,8 +70,6 @@
70 * Fix sigmatch() macro to handle old CPUs with pf == 0. 70 * Fix sigmatch() macro to handle old CPUs with pf == 0.
71 * Thanks to Stuart Swales for pointing out this bug. 71 * Thanks to Stuart Swales for pointing out this bug.
72 */ 72 */
73
74/* #define DEBUG */ /* pr_debug */
75#include <linux/capability.h> 73#include <linux/capability.h>
76#include <linux/kernel.h> 74#include <linux/kernel.h>
77#include <linux/init.h> 75#include <linux/init.h>
@@ -356,6 +354,8 @@ static int generic_load_microcode(int cpu, void *data, size_t size,
356 } 354 }
357 355
358 if (get_matching_microcode(&uci->cpu_sig, mc, new_rev)) { 356 if (get_matching_microcode(&uci->cpu_sig, mc, new_rev)) {
357 if (new_mc)
358 vfree(new_mc);
359 new_rev = mc_header.rev; 359 new_rev = mc_header.rev;
360 new_mc = mc; 360 new_mc = mc;
361 } else 361 } else