summaryrefslogtreecommitdiff
path: root/bsps/sparc/leon3/start/bspclean.c
diff options
context:
space:
mode:
Diffstat (limited to 'bsps/sparc/leon3/start/bspclean.c')
-rw-r--r--bsps/sparc/leon3/start/bspclean.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/bsps/sparc/leon3/start/bspclean.c b/bsps/sparc/leon3/start/bspclean.c
index 7caa0440ca..9f062adf50 100644
--- a/bsps/sparc/leon3/start/bspclean.c
+++ b/bsps/sparc/leon3/start/bspclean.c
@@ -55,9 +55,9 @@ void bsp_fatal_extension(
(code == SMP_FATAL_SHUTDOWN_RESPONSE)) {
leon3_power_down_loop(); /* CPU didn't start shutdown sequence .. */
} else {
- volatile struct irqmp_regs *irqmp = LEON3_IrqCtrl_Regs;
+ irqamp *regs = LEON3_IrqCtrl_Regs;
- if (irqmp != NULL) {
+ if (regs != NULL) {
/*
* Value was chosen to get something in the magnitude of 1ms on a 200MHz
* processor.
@@ -76,7 +76,10 @@ void bsp_fatal_extension(
/* Wait some time for secondary processors to halt */
i = 0;
- while ((irqmp->mpstat & halt_mask) != halt_mask && i < max_wait) {
+ while (
+ (grlib_load_32(&regs->mpstat) & halt_mask) != halt_mask &&
+ i < max_wait
+ ) {
++i;
}
}