blob: 56f621314fe9972c97eda159d96a25470a82d34f [file] [log] [blame]
Thomas Gleixnerd2912cb2019-06-04 10:11:33 +02001// SPDX-License-Identifier: GPL-2.0-only
Afzal Mohammedab4c2e12013-05-27 20:05:19 +05302/*
3 * omap4-restart.c - Common to OMAP4 and OMAP5
Afzal Mohammedab4c2e12013-05-27 20:05:19 +05304 */
5
6#include <linux/types.h>
Robin Holt7b6d8642013-07-08 16:01:40 -07007#include <linux/reboot.h>
Sekhar Nori9e5d46b2015-07-11 20:29:16 +05308#include "common.h"
Tero Kristo61c86212014-10-27 08:39:26 -07009#include "prm.h"
Afzal Mohammedab4c2e12013-05-27 20:05:19 +053010
11/**
12 * omap44xx_restart - trigger a software restart of the SoC
13 * @mode: the "reboot mode", see arch/arm/kernel/{setup,process}.c
14 * @cmd: passed from the userspace program rebooting the system (if provided)
15 *
16 * Resets the SoC. For @cmd, see the 'reboot' syscall in
17 * kernel/sys.c. No return value.
18 */
Robin Holt7b6d8642013-07-08 16:01:40 -070019void omap44xx_restart(enum reboot_mode mode, const char *cmd)
Afzal Mohammedab4c2e12013-05-27 20:05:19 +053020{
21 /* XXX Should save 'cmd' into scratchpad for use after reboot */
Tero Kristo61c86212014-10-27 08:39:26 -070022 omap_prm_reset_system();
Afzal Mohammedab4c2e12013-05-27 20:05:19 +053023}