static void __noreturn pxa2xx_poweroff(struct poweroff_handler *handler) { shutdown_barebox(); /* Clear last reset source */ pxa_clear_reset_source(); pxa_suspend(PWRMODE_DEEPSLEEP); unreachable(); }
void reset_cpu(ulong addr) { /* Clear last reset source */ pxa_clear_reset_source(); /* Initialize the watchdog and let it fire */ writel(OWER_WME, OWER); writel(OSSR_M3, OSSR); writel(readl(OSCR) + 368640, OSMR3); /* ... in 100 ms */ while (1); }
static void __noreturn pxa_restart_soc(struct restart_handler *rst) { /* Clear last reset source */ pxa_clear_reset_source(); /* Initialize the watchdog and let it fire */ writel(OWER_WME, OWER); writel(OSSR_M3, OSSR); writel(readl(OSCR) + 368640, OSMR3); /* ... in 100 ms */ hang(); }