]> rtime.felk.cvut.cz Git - can-eth-gw-linux.git/blobdiff - arch/arm/mach-omap2/omap4-common.c
Merge branch 'omap/cleanup-prcm-part2' into next/dt
[can-eth-gw-linux.git] / arch / arm / mach-omap2 / omap4-common.c
index 3cfcd41bf8fa144d0f30e23a3ee9c57c735ec0c7..5695885ea340b6b754b3d36d5c181c78c67731b6 100644 (file)
 
 #include "omap-wakeupgen.h"
 #include "soc.h"
+#include "iomap.h"
 #include "common.h"
 #include "mmc.h"
 #include "hsmmc.h"
+#include "prminst44xx.h"
+#include "prcm_mpu44xx.h"
 #include "omap4-sar-layout.h"
 #include "omap-secure.h"
 #include "sram.h"
@@ -279,3 +282,19 @@ int __init omap4_twl6030_hsmmc_init(struct omap2_hsmmc_info *controllers)
        return 0;
 }
 #endif
+
+/**
+ * omap44xx_restart - trigger a software restart of the SoC
+ * @mode: the "reboot mode", see arch/arm/kernel/{setup,process}.c
+ * @cmd: passed from the userspace program rebooting the system (if provided)
+ *
+ * Resets the SoC.  For @cmd, see the 'reboot' syscall in
+ * kernel/sys.c.  No return value.
+ */
+void omap44xx_restart(char mode, const char *cmd)
+{
+       /* XXX Should save 'cmd' into scratchpad for use after reboot */
+       omap4_prminst_global_warm_sw_reset(); /* never returns */
+       while (1);
+}
+