extern void map_init(void);
extern void platform_idle(void);
extern uint8_t rtc_secs(void);
+extern void trap_reboot(void);
/* Will need a uptr_t eventually */
extern uaddr_t ramtop; /* Note: ramtop must be in common in some cases */
{
if (esuper())
return -1;
+ _sync();
/* Wants moving into machine specific files */
- if (cmd == A_SHUTDOWN || cmd == A_REBOOT || cmd == A_DUMP) {
- _sync();
+ if (cmd == A_SHUTDOWN || cmd == A_DUMP)
trap_monitor();
- }
+ if (cmd == A_REBOOT)
+ trap_reboot();
+
/* We don't do SWAPCTL yet */
udata.u_error = EINVAL;
return -1;