BACKPORT: x86: provide infrastructure to backup default SMM region
Certain CPUs require the default SMM region to be backed up on resume after a suspend. The reason is that in order to relocate the SMM region the default SMM region has to be used. As coreboot is unaware of how that memory is used it needs to be backed up. Therefore provide a common method for doing this. BUG=chrome-os-partner:26563 BRANCH=baytrail TEST=Confirmed SMM backup region in cbmem. Suspend and Resumed. Change-Id: I65fe1317dc0b2203cb29118564fdba995770ffea Signed-off-by: Aaron Durbin <adurbin@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/188716 Reviewed-by: Marc Jones <marc.jones@se-eng.com>
This commit is contained in:
parent
3fa832840e
commit
e236bf0750
6 changed files with 82 additions and 0 deletions
|
|
@ -74,6 +74,7 @@
|
|||
#define CBMEM_ID_REFCODE_CACHE 0x4efc0de5
|
||||
#define CBMEM_ID_POWER_STATE 0x50535454
|
||||
#define CBMEM_ID_RAM_OOPS 0x05430095
|
||||
#define CBMEM_ID_SMM_SAVE_SPACE 0x07e9acee
|
||||
#define CBMEM_ID_NONE 0x00000000
|
||||
|
||||
#ifndef __ASSEMBLER__
|
||||
|
|
|
|||
|
|
@ -571,4 +571,8 @@ int smm_load_module(void *smram, int size, struct smm_loader_params *params);
|
|||
#endif /* __SMM__ */
|
||||
#endif /* CONFIG_SMM_MODULES */
|
||||
|
||||
/* Backup and restore default SMM region. */
|
||||
void *backup_default_smm_area(void);
|
||||
void restore_default_smm_area(void *smm_save_area);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue