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

[xen master] x86/S3: don't lose previously collected CPU data (AMD extra)



commit 55719030b0bb0069fc8b57cd808dc98dc9d39add
Author:     Jan Beulich <jbeulich@xxxxxxxx>
AuthorDate: Thu Jul 17 17:55:54 2025 +0200
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Thu Jul 17 17:55:54 2025 +0200

    x86/S3: don't lose previously collected CPU data (AMD extra)
    
    smp_store_cpu_info() doesn't call identify_cpu() again during S3 resume,
    hence it is wrong to zap APs' data while bringing them down (and we're
    not just parking them there) during suspend.
    
    Fixes: 7126b7f806d5 ("x86/CPU: re-work populating of cpu_data[]")
    Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
    Reviewed-by: Juergen Gross <jgross@xxxxxxxx>
---
 xen/arch/x86/smpboot.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/xen/arch/x86/smpboot.c b/xen/arch/x86/smpboot.c
index d95d527fc1..302be4341b 100644
--- a/xen/arch/x86/smpboot.c
+++ b/xen/arch/x86/smpboot.c
@@ -982,7 +982,8 @@ static void cpu_smpboot_free(unsigned int cpu, bool remove)
 
     if ( remove )
     {
-        reset_cpuinfo(&c[cpu], false);
+        if ( system_state != SYS_STATE_suspend )
+            reset_cpuinfo(&c[cpu], false);
 
         FREE_CPUMASK_VAR(per_cpu(cpu_sibling_mask, cpu));
         FREE_CPUMASK_VAR(per_cpu(cpu_core_mask, cpu));
--
generated by git-patchbot for /home/xen/git/xen.git#master



 


Rackspace

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