blob: 6623bcc7cf6924cc725e31e275d7bb3acdb7697a [file] [log] [blame]
Damien Roth07a196e2016-01-19 20:20:15 -07001/*
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 Heymansedbf5d92018-01-25 20:03:42 +010014#include <device/device.h>
15
Vladimir Serbinenkoc16e9dfa2015-05-29 16:18:01 +020016/* These helpers are for performing SMM relocation. */
17void southbridge_smm_init(void);
Nico Huber6f8b7df2016-10-08 18:42:46 +020018u32 northbridge_get_tseg_base(void);
Arthur Heymansaade90e2018-01-25 00:33:45 +010019u32 northbridge_get_tseg_size(void);
Vladimir Serbinenkoc16e9dfa2015-05-29 16:18:01 +020020void northbridge_write_smram(u8 smram);
Arthur Heymansd30894b2019-01-12 00:27:18 +010021
22bool cpu_has_alternative_smrr(void);
Arthur Heymansedbf5d92018-01-25 20:03:42 +010023
24/* parallel MP helper functions */
25void smm_info(uintptr_t *perm_smbase, size_t *perm_smsize,
26 size_t *smm_save_state_size);
27void smm_initialize(void);
28void southbridge_smm_clear_state(void);
29void smm_relocation_handler(int cpu, uintptr_t curr_smbase,
30 uintptr_t staggered_smbase);
31void smm_relocate(void);
Kyösti Mälkkid4e140d2019-07-08 23:25:05 +030032void smm_lock(void);