| 1 |
|
| 2 |
|
| 3 |
#include <arch/io.h> |
| 4 |
#include <arch/cache.h> |
| 5 |
#include <cf9_reset.h> |
| 6 |
#include <console/console.h> |
| 7 |
#include <halt.h> |
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
void do_system_reset(void) |
| 17 |
{ |
| 18 |
dcache_clean_all(); |
| 19 |
outb(SYS_RST, RST_CNT); |
| 20 |
outb(RST_CPU | SYS_RST, RST_CNT); |
| 21 |
} |
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
void do_full_reset(void) |
| 31 |
{ |
| 32 |
dcache_clean_all(); |
| 33 |
outb(FULL_RST | SYS_RST, RST_CNT); |
| 34 |
outb(FULL_RST | RST_CPU | SYS_RST, RST_CNT); |
| 35 |
} |
| 36 |
|
| 37 |
void system_reset(void) |
| 38 |
{ |
| 39 |
printk(BIOS_INFO, "%s() called!\n", __func__); |
| 40 |
cf9_reset_prepare(); |
| 41 |
do_system_reset(); |
| 42 |
halt(); |
| 43 |
} |
| 44 |
|
| 45 |
void full_reset(void) |
| 46 |
{ |
| 47 |
printk(BIOS_INFO, "%s() called!\n", __func__); |
| 48 |
cf9_reset_prepare(); |
| 49 |
do_full_reset(); |
| 50 |
halt(); |
| 51 |
} |