Julius Werner | 01f9aa5 | 2017-05-18 16:03:26 -0700 | [diff] [blame] | 1 | /* |
| 2 | * This file is part of the coreboot project. |
| 3 | * |
| 4 | * Copyright 2017 Google, Inc. |
| 5 | * |
| 6 | * This program is free software; you can redistribute it and/or modify |
| 7 | * it under the terms of the GNU General Public License as published by |
| 8 | * the Free Software Foundation; version 2 of the License. |
| 9 | * |
| 10 | * This program is distributed in the hope that it will be useful, |
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | * GNU General Public License for more details. |
| 14 | */ |
| 15 | |
| 16 | #include <arch/cache.h> |
| 17 | #include <console/console.h> |
| 18 | #include <halt.h> |
| 19 | #include <reset.h> |
| 20 | |
Nico Huber | 4f32b64 | 2018-10-05 23:40:21 +0200 | [diff] [blame] | 21 | __noreturn void board_reset(void) |
| 22 | { |
| 23 | printk(BIOS_INFO, "%s() called!\n", __func__); |
| 24 | dcache_clean_all(); |
| 25 | do_board_reset(); |
| 26 | halt(); |
| 27 | } |
| 28 | |
| 29 | #if IS_ENABLED(CONFIG_MISSING_BOARD_RESET) |
| 30 | void do_board_reset(void) |
| 31 | { |
| 32 | printk(BIOS_CRIT, "No board_reset implementation, hanging...\n"); |
| 33 | } |
Nico Huber | 4f32b64 | 2018-10-05 23:40:21 +0200 | [diff] [blame] | 34 | #endif |