^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 1) // SPDX-License-Identifier: GPL-2.0-only
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 2) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 3) * omap4-restart.c - Common to OMAP4 and OMAP5
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 4) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 5)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 6) #include <linux/types.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 7) #include <linux/reboot.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 8) #include "common.h"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 9) #include "prm.h"
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) /**
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) * omap44xx_restart - trigger a software restart of the SoC
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) * @mode: the "reboot mode", see arch/arm/kernel/{setup,process}.c
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) * @cmd: passed from the userspace program rebooting the system (if provided)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) * Resets the SoC. For @cmd, see the 'reboot' syscall in
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) * kernel/sys.c. No return value.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) void omap44xx_restart(enum reboot_mode mode, const char *cmd)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) /* XXX Should save 'cmd' into scratchpad for use after reboot */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) omap_prm_reset_system();
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) }