diff --git a/hw/arm/virt-acpi-build.c b/hw/arm/virt-acpi-build.c index f9c9df916cfb..a91550de6fc3 100644 --- a/hw/arm/virt-acpi-build.c +++ b/hw/arm/virt-acpi-build.c @@ -865,7 +865,8 @@ void virt_acpi_setup(VirtMachineState *vms) build_state->linker_mr = acpi_add_rom_blob(virt_acpi_build_update, build_state, - tables.linker->cmd_blob, ACPI_BUILD_LOADER_FILE, 0); + tables.linker->cmd_blob, ACPI_BUILD_LOADER_FILE, + ACPI_BUILD_LOADER_MAX_SIZE); fw_cfg_add_file(vms->fw_cfg, ACPI_BUILD_TPMLOG_FILE, tables.tcpalog->data, acpi_data_len(tables.tcpalog)); diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c index a95b42c8b33f..dc56006353cc 100644 --- a/hw/i386/acpi-build.c +++ b/hw/i386/acpi-build.c @@ -2634,7 +2634,8 @@ void acpi_setup(void) build_state->linker_mr = acpi_add_rom_blob(acpi_build_update, build_state, - tables.linker->cmd_blob, ACPI_BUILD_LOADER_FILE, 0); + tables.linker->cmd_blob, ACPI_BUILD_LOADER_FILE, + ACPI_BUILD_LOADER_MAX_SIZE); fw_cfg_add_file(x86ms->fw_cfg, ACPI_BUILD_TPMLOG_FILE, tables.tcpalog->data, acpi_data_len(tables.tcpalog)); diff --git a/hw/i386/acpi-microvm.c b/hw/i386/acpi-microvm.c index 54b3af478ae8..01f1945ac12d 100644 --- a/hw/i386/acpi-microvm.c +++ b/hw/i386/acpi-microvm.c @@ -255,7 +255,7 @@ void acpi_setup_microvm(MicrovmMachineState *mms) ACPI_BUILD_TABLE_MAX_SIZE); acpi_add_rom_blob(acpi_build_no_update, NULL, tables.linker->cmd_blob, - "etc/table-loader", 0); + "etc/table-loader", ACPI_BUILD_LOADER_MAX_SIZE); acpi_add_rom_blob(acpi_build_no_update, NULL, tables.rsdp, ACPI_BUILD_RSDP_FILE, 0); diff --git a/include/hw/acpi/aml-build.h b/include/hw/acpi/aml-build.h index e652106e26e7..ca781f3531cb 100644 --- a/include/hw/acpi/aml-build.h +++ b/include/hw/acpi/aml-build.h @@ -6,6 +6,7 @@ /* Reserve RAM space for tables: add another order of magnitude. */ #define ACPI_BUILD_TABLE_MAX_SIZE 0x200000 +#define ACPI_BUILD_LOADER_MAX_SIZE 0x10000 #define ACPI_BUILD_APPNAME6 "BOCHS " #define ACPI_BUILD_APPNAME8 "BXPC "