Damien Roth | 07a196e | 2016-01-19 20:20:15 -0700 | [diff] [blame] | 1 | /* |
| 2 | * This file is part of the coreboot project. |
| 3 | * |
| 4 | * This program is free software; you can redistribute it and/or modify |
| 5 | * it under the terms of the GNU General Public License as published by |
| 6 | * the Free Software Foundation; version 2 of the License. |
| 7 | * |
| 8 | * This program is distributed in the hope that it will be useful, |
| 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 11 | * GNU General Public License for more details. |
| 12 | */ |
| 13 | |
Arthur Heymans | edbf5d9 | 2018-01-25 20:03:42 +0100 | [diff] [blame] | 14 | #include <device/device.h> |
| 15 | |
Vladimir Serbinenko | c16e9dfa | 2015-05-29 16:18:01 +0200 | [diff] [blame] | 16 | /* These helpers are for performing SMM relocation. */ |
| 17 | void southbridge_smm_init(void); |
Nico Huber | 6f8b7df | 2016-10-08 18:42:46 +0200 | [diff] [blame] | 18 | u32 northbridge_get_tseg_base(void); |
Arthur Heymans | aade90e | 2018-01-25 00:33:45 +0100 | [diff] [blame] | 19 | u32 northbridge_get_tseg_size(void); |
Vladimir Serbinenko | c16e9dfa | 2015-05-29 16:18:01 +0200 | [diff] [blame] | 20 | void northbridge_write_smram(u8 smram); |
Arthur Heymans | d30894b | 2019-01-12 00:27:18 +0100 | [diff] [blame] | 21 | |
| 22 | bool cpu_has_alternative_smrr(void); |
Arthur Heymans | edbf5d9 | 2018-01-25 20:03:42 +0100 | [diff] [blame] | 23 | |
| 24 | /* parallel MP helper functions */ |
| 25 | void smm_info(uintptr_t *perm_smbase, size_t *perm_smsize, |
| 26 | size_t *smm_save_state_size); |
| 27 | void smm_initialize(void); |
| 28 | void southbridge_smm_clear_state(void); |
| 29 | void smm_relocation_handler(int cpu, uintptr_t curr_smbase, |
| 30 | uintptr_t staggered_smbase); |
| 31 | void smm_relocate(void); |
Kyösti Mälkki | d4e140d | 2019-07-08 23:25:05 +0300 | [diff] [blame] | 32 | void smm_lock(void); |