aboutsummaryrefslogtreecommitdiff
path: root/arch/m68k/mac/misc.c
diff options
context:
space:
mode:
authorLinus Torvalds <[email protected]>2017-09-05 09:34:49 -0700
committerLinus Torvalds <[email protected]>2017-09-05 09:34:49 -0700
commitd1ce495676644fc79b3ccd58657133c5d4a414fb (patch)
tree9d3997a61497a95902f875217264b69dde3fee15 /arch/m68k/mac/misc.c
parent24e700e291d52bd200212487e2b654c0aa3f07a2 (diff)
parent558d5ad276c9b2ffbe706e78310a777f87e65c5f (diff)
Merge tag 'm68k-for-v4.14-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k
Pull m68k updates from Geert Uytterhoeven: - restore symbol versions for symbols exported from assembly - defconfig updates - Mac fixes * tag 'm68k-for-v4.14-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/linux-m68k: m68k/mac: Avoid soft-lockup warning after mach_power_off m68k/mac: Don't hang waiting for Cuda power-down command m68k: Restore symbol versions for symbols exported from assembly m68k/defconfig: Update defconfigs for v4.13-rc1
Diffstat (limited to 'arch/m68k/mac/misc.c')
-rw-r--r--arch/m68k/mac/misc.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/arch/m68k/mac/misc.c b/arch/m68k/mac/misc.c
index 8aa8792e3174..d96348a52362 100644
--- a/arch/m68k/mac/misc.c
+++ b/arch/m68k/mac/misc.c
@@ -357,6 +357,17 @@ static void cuda_shutdown(void)
struct adb_request req;
if (cuda_request(&req, NULL, 2, CUDA_PACKET, CUDA_POWERDOWN) < 0)
return;
+
+ /* Avoid infinite polling loop when PSU is not under Cuda control */
+ switch (macintosh_config->ident) {
+ case MAC_MODEL_C660:
+ case MAC_MODEL_Q605:
+ case MAC_MODEL_Q605_ACC:
+ case MAC_MODEL_P475:
+ case MAC_MODEL_P475F:
+ return;
+ }
+
while (!req.complete)
cuda_poll();
}
@@ -463,8 +474,9 @@ void mac_poweroff(void)
pmu_shutdown();
#endif
}
- local_irq_enable();
+
pr_crit("It is now safe to turn off your Macintosh.\n");
+ local_irq_disable();
while(1);
}
@@ -554,8 +566,8 @@ void mac_reset(void)
}
/* should never get here */
- local_irq_enable();
pr_crit("Restart failed. Please restart manually.\n");
+ local_irq_disable();
while(1);
}