From 215f6cc64a65efbe0a71b8fdba72311201aca4fc Mon Sep 17 00:00:00 2001 From: cinap_lenrek Date: Thu, 29 May 2014 18:24:40 +0200 Subject: pc: initiate machine reset only from boot processors in mpshutdown() in vmware, mpshutdown() used to hang in i8042reset() when not called from the boot processor, so instead of reseting from first cpu that acquires the shutdown lock, we park all application processors and let the boot processor do the reset. --- sys/src/9/pc/mp.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/src/9/pc/mp.c b/sys/src/9/pc/mp.c index ead78ae17..a3afc885d 100644 --- a/sys/src/9/pc/mp.c +++ b/sys/src/9/pc/mp.c @@ -620,9 +620,10 @@ mpintrenable(Vctl* v) void mpshutdown(void) { - static Lock shutdownlock; - - if(active.rebooting || !canlock(&shutdownlock)){ + /* + * Park application processors. + */ + if(active.rebooting || m->machno != 0){ splhi(); arch->introff(); idle(); -- cgit v1.2.3