blob: fa931503a0e7d6fe5ca6d3006258fad59baf47a8 [file] [log] [blame]
wdenk074cff02004-02-24 00:16:43 +00001/*
2 * (C) Copyright 2004
3 * DAVE Srl
4 * http://www.dave-tech.it
5 * http://www.wawnet.biz
6 * mailto:info@wawnet.biz
7 *
Wolfgang Denk1a459662013-07-08 09:37:19 +02008 * SPDX-License-Identifier: GPL-2.0+
wdenk074cff02004-02-24 00:16:43 +00009 */
10
11/*
12 * S3C44B0 CPU specific code
13 */
14
15#include <common.h>
16#include <command.h>
17#include <asm/hardware.h>
18
Jean-Christophe PLAGNIOL-VILLARDad7e8aac2009-05-09 13:21:19 +020019int arch_cpu_init (void)
wdenk074cff02004-02-24 00:16:43 +000020{
21 icache_enable();
22
23 return 0;
24}
25
26int cleanup_before_linux (void)
27{
28 /*
29 cache memory should be enabled before calling
30 Linux to make the kernel uncompression faster
31 */
32 icache_enable();
33
34 disable_interrupts ();
35
36 return 0;
37}
38
39void reset_cpu (ulong addr)
40{
41 /*
42 reset the cpu using watchdog
43 */
44
45 /* Disable the watchdog.*/
46 WTCON&=~(1<<5);
47
48 /* set the timeout value to a short time... */
49 WTCNT = 0x1;
50
51 /* Enable the watchdog. */
52 WTCON|=1;
53 WTCON|=(1<<5);
54
55 while(1) {
56 /*NOP*/
57 }
58}