[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [PATCH 4/4][Xen-devel] X86 microcode: add S3 micorcode update



Christoph Egger wrote:
> On Thursday 22 January 2009 04:10:14 Liu, Jinsong wrote:
>> X86 microcode: add S3 micorcode update
>> 
>> When wakeup from S3, use per cpu microcode image to update cpu
>> microcode. 
>> 
>> Signed-off-by: Liu, Jinsong <jinsong.liu@xxxxxxxxx>
> 
> This patch doesn't compile for me w/o updating the struct
> microcode_ops in microcode_amd.c
> 
> Christoph


Sorry, I don't quite clear where block compile for amd arch.

I wrote a patch to walk around this issue, microcode-5-s3-amd.patch as attached.
How about you fill the function microcode_resume_match after my patches in?

Thanks,
Jinsong

===============

diff -r d6973a2a9839 xen/arch/x86/microcode.c
--- a/xen/arch/x86/microcode.c  Wed Jan 21 19:56:07 2009 +0800
+++ b/xen/arch/x86/microcode.c  Thu Jan 22 19:00:47 2009 +0800
@@ -64,14 +64,6 @@ static void microcode_fini_cpu(int cpu)
     spin_unlock(&microcode_mutex);
 }
 
-static int microcode_resume_match(int cpu, struct cpu_signature *nsig)
-{
-    if ( microcode_ops->microcode_resume_match )
-        return microcode_ops->microcode_resume_match(cpu, nsig);
-
-    return 0;
-}
-
 int microcode_resume_cpu(int cpu)
 {
     int err = 0;
@@ -94,7 +86,7 @@ int microcode_resume_cpu(int cpu)
         return err;
     }
 
-    if ( microcode_resume_match(cpu, &nsig) )
+    if ( microcode_ops->microcode_resume_match(cpu, &nsig) )
     {
         return microcode_ops->apply_microcode(cpu);
     }
diff -r d6973a2a9839 xen/arch/x86/microcode_amd.c
--- a/xen/arch/x86/microcode_amd.c      Wed Jan 21 19:56:07 2009 +0800
+++ b/xen/arch/x86/microcode_amd.c      Thu Jan 22 19:00:47 2009 +0800
@@ -318,7 +318,13 @@ out:
     return error;
 }
 
+static int microcode_resume_match(int cpu, struct cpu_signature *nsig)
+{
+    return 0;
+}
+
 static struct microcode_ops microcode_amd_ops = {
+    .microcode_resume_match           = microcode_resume_match,
     .cpu_request_microcode            = cpu_request_microcode,
     .collect_cpu_info                 = collect_cpu_info,
     .apply_microcode                  = apply_microcode,

===============

Attachment: microcode-5-s3-amd.patch
Description: microcode-5-s3-amd.patch

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.