xref: /openbmc/u-boot/arch/arc/lib/reset.c (revision 3eceff64)
183d290c5STom Rini // SPDX-License-Identifier: GPL-2.0+
2660d5f0dSAlexey Brodkin /*
3660d5f0dSAlexey Brodkin  * Copyright (C) 2013-2014 Synopsys, Inc. All rights reserved.
4660d5f0dSAlexey Brodkin  */
5660d5f0dSAlexey Brodkin 
6660d5f0dSAlexey Brodkin #include <command.h>
7660d5f0dSAlexey Brodkin #include <common.h>
8660d5f0dSAlexey Brodkin 
reset_cpu(ulong addr)9*eb5c8539SAlexey Brodkin __weak void reset_cpu(ulong addr)
10660d5f0dSAlexey Brodkin {
11660d5f0dSAlexey Brodkin 	/* Stop debug session here */
128f187142SAlexey Brodkin 	__builtin_arc_brk();
13*eb5c8539SAlexey Brodkin }
14*eb5c8539SAlexey Brodkin 
do_reset(cmd_tbl_t * cmdtp,int flag,int argc,char * const argv[])15*eb5c8539SAlexey Brodkin int do_reset(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])
16*eb5c8539SAlexey Brodkin {
17*eb5c8539SAlexey Brodkin 	printf("Resetting the board...\n");
18*eb5c8539SAlexey Brodkin 
19*eb5c8539SAlexey Brodkin 	reset_cpu(0);
20*eb5c8539SAlexey Brodkin 
21660d5f0dSAlexey Brodkin 	return 0;
22660d5f0dSAlexey Brodkin }
23