hv: add method to deal with ">4G MMIO" BIOS option

1. Fixed the bug that HV may crush when ">4G MMIO"
BIOS option is disabled.
2. Fixed the bug that RTVM may encounter problems
at reboot time when it makes use of pSRAM
3. HV will skip PTCM initialization when it cannot
find PTCM.
4. Some codes are refined.

Tracked-On: #5330

Signed-off-by: Qian Wang <qian1.wang@intel.com>
This commit is contained in:
Qian Wang
2020-09-21 10:28:40 +08:00
committed by wenlingz
parent 57a6d35188
commit 793b99e3f6
4 changed files with 58 additions and 40 deletions

View File

@@ -18,6 +18,8 @@ typedef int32_t MSABI (*ptcm_command_abi)(uint32_t command, void *command_struct
#define PTCM_CMD_RDMSR (int32_t)3U
#define PTCM_CMD_WRMSR (int32_t)4U
#define PTCM_MAGIC 0x5054434dU
#define PCTM_L2_CLOS_MASK_MAX_NUM 8U
#define PCTM_L3_CLOS_MASK_MAX_NUM 4U
@@ -37,4 +39,5 @@ struct ptcm_header
uint64_t command_interface_offset;
};
int32_t init_psram(bool is_bsp);
#endif /* PTCM_H */

View File

@@ -101,5 +101,4 @@ struct ptcm_mem_region
extern uint64_t psram_area_bottom;
extern uint64_t psram_area_top;
void init_psram(bool is_bsp);
#endif /* PTCT_H */