mirror of
https://github.com/u-boot/u-boot.git
synced 2025-05-03 02:03:01 +00:00

The current do_reset() is called from a command context. Add a function which can be used from anywhere, as is done on ARM. Adjust do_reset() to call it. Note that reset_cpu() is normally provided by SYSRESET so make this declaration conditional on that being disabled. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Chanho Park <chanho61.park@samsung.com> Tested-by: Chanho Park <chanho61.park@samsung.com>
14 lines
248 B
C
14 lines
248 B
C
// SPDX-License-Identifier: GPL-2.0+
|
|
/*
|
|
* Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
|
|
*/
|
|
|
|
#include <command.h>
|
|
#include <cpu_func.h>
|
|
|
|
int do_reset(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
|
|
{
|
|
reset_cpu();
|
|
|
|
return 0;
|
|
}
|