Author: avg
Date: Thu Apr 19 06:20:53 2018
New Revision: 332759
URL: https://svnweb.freebsd.org/changeset/base/332759

Log:
  MFC r331875: x86 cpu_reset: if failed to switch to BSP proceed to 
cpu_reset_real

Modified:
  stable/10/sys/amd64/amd64/vm_machdep.c
  stable/10/sys/i386/i386/vm_machdep.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/amd64/amd64/vm_machdep.c
==============================================================================
--- stable/10/sys/amd64/amd64/vm_machdep.c      Thu Apr 19 06:18:21 2018        
(r332758)
+++ stable/10/sys/amd64/amd64/vm_machdep.c      Thu Apr 19 06:20:53 2018        
(r332759)
@@ -613,13 +613,14 @@ cpu_reset()
                                ia32_pause();
                                cnt++;  /* Wait for BSP to announce restart */
                        }
-                       if (cpu_reset_proxy_active == 0)
+                       if (cpu_reset_proxy_active == 0) {
                                printf("cpu_reset: Failed to restart BSP\n");
-                       cpu_reset_proxy_active = 2;
-
-                       while (1)
-                               ia32_pause();
-                       /* NOTREACHED */
+                       } else {
+                               cpu_reset_proxy_active = 2;
+                               while (1)
+                                       ia32_pause();
+                               /* NOTREACHED */
+                       }
                }
 
                DELAY(1000000);

Modified: stable/10/sys/i386/i386/vm_machdep.c
==============================================================================
--- stable/10/sys/i386/i386/vm_machdep.c        Thu Apr 19 06:18:21 2018        
(r332758)
+++ stable/10/sys/i386/i386/vm_machdep.c        Thu Apr 19 06:20:53 2018        
(r332759)
@@ -695,13 +695,14 @@ cpu_reset()
                                ia32_pause();
                                cnt++;  /* Wait for BSP to announce restart */
                        }
-                       if (cpu_reset_proxy_active == 0)
+                       if (cpu_reset_proxy_active == 0) {
                                printf("cpu_reset: Failed to restart BSP\n");
-                       cpu_reset_proxy_active = 2;
-
-                       while (1)
-                               ia32_pause();
-                       /* NOTREACHED */
+                       } else {
+                               cpu_reset_proxy_active = 2;
+                               while (1)
+                                       ia32_pause();
+                               /* NOTREACHED */
+                       }
                }
 
                DELAY(1000000);
_______________________________________________
svn-src-stable-10@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-stable-10
To unsubscribe, send any mail to "svn-src-stable-10-unsubscr...@freebsd.org"

Reply via email to