hw/loongarch/virt: Remove global variables about memmap tables

Global variables memmap_table and memmap_entries stores UEFI memory
map table informations. It can be moved into structure
LoongArchVirtMachineState.

Signed-off-by: Bibo Mao <maobibo@loongson.cn>
Reviewed-by: Song Gao <gaosong@loongson.cn>
Message-Id: <20250430094738.1556670-3-maobibo@loongson.cn>
Signed-off-by: Song Gao <gaosong@loongson.cn>
This commit is contained in:
Bibo Mao 2025-04-30 17:47:38 +08:00 committed by Song Gao
parent 4332a641e2
commit ffe89c1762
4 changed files with 37 additions and 22 deletions

View file

@ -106,9 +106,6 @@ struct loongarch_boot_info {
uint64_t initrd_size;
};
extern struct memmap_entry *memmap_table;
extern unsigned memmap_entries;
struct memmap_entry {
uint64_t address;
uint64_t length;

View file

@ -63,6 +63,8 @@ struct LoongArchVirtMachineState {
struct loongarch_boot_info bootinfo;
DeviceState *ipi;
DeviceState *extioi;
struct memmap_entry *memmap_table;
unsigned int memmap_entries;
};
#define TYPE_LOONGARCH_VIRT_MACHINE MACHINE_TYPE_NAME("virt")