mirror of
https://github.com/acidanthera/audk.git
synced 2025-08-29 13:38:13 +02:00
After the loongarch flash block size is changed from 128K to 256K, qemu requires that the UEFI firmware size be aligned with the flash block size(256K). Otherwise, the firmware cannot be loaded, Use the following code to resolve the old firmware loading problem: mv QEMU_EFI.fd QEMU_EFI.fd-bak cat QEMU_EFI.fd-bak /dev/zero | head -c 16m > ./QEMU_EFI.fd mv QEMU_VARS.fd QEMU_VARS.fd-bak cat QEMU_VARS.fd-bak /dev/zero | head -c 16m > ./QEMU_VARS.fd For the new firmware, we refer to other architecture UEFI and set the UEFI firmware size to align with the flash block size(256K). So for this patch, we set the UEFI firmware size to 256K alignment. Cc: Bibo Mao <maobibo@loongson.cn> Cc: Chao Li <lichao@loongson.cn> Signed-off-by: Xianglai Li <lixianglai@loongson.cn>
25 lines
740 B
PHP
25 lines
740 B
PHP
## @file
|
|
#
|
|
# Copyright (c) 2024 Loongson Technology Corporation Limited. All rights reserved.<BR>
|
|
#
|
|
# SPDX-License-Identifier: BSD-2-Clause-Patent
|
|
#
|
|
##
|
|
|
|
DEFINE BLOCK_SIZE = 0x1000
|
|
|
|
############################################################################
|
|
# FW total
|
|
DEFINE FW_BASE_ADDRESS = 0x1c000000
|
|
DEFINE FW_BLOCKS = 0x400
|
|
DEFINE FW_SIZE = 0x400000
|
|
|
|
############################################################################
|
|
#Set FVMAIN size
|
|
DEFINE FVMAIN_SIZE = $(FW_SIZE)
|
|
|
|
#Set Memory layout
|
|
DEFINE SEC_PEI_TEMP_RAM_BASE = 0x10000
|
|
DEFINE SEC_PEI_TEMP_RAM_SIZE = 0x80000
|
|
DEFINE DEVICE_TREE_RAM_BASE = 0x100000
|