pc_sysfw: Pass PCMachineState to pc_system_firmware_init()
pc_system_firmware_init() parameter @isapc_ram_fw is PCMachineState member pci_enabled negated. The next commit will need more of PCMachineState. To prepare for that, pass a PCMachineState *, and drop the now redundant parameter @isapc_ram_fw. Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Message-Id: <20190308131445.17502-11-armbru@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
d6edbe91b9
commit
5e640a9e78
@ -1809,7 +1809,7 @@ void pc_memory_init(PCMachineState *pcms,
|
||||
}
|
||||
|
||||
/* Initialize PC system firmware */
|
||||
pc_system_firmware_init(rom_memory, !pcmc->pci_enabled);
|
||||
pc_system_firmware_init(pcms, rom_memory);
|
||||
|
||||
option_rom_mr = g_malloc(sizeof(*option_rom_mr));
|
||||
memory_region_init_ram(option_rom_mr, NULL, "pc.rom", PC_ROM_SIZE,
|
||||
|
@ -231,8 +231,11 @@ static void old_pc_system_rom_init(MemoryRegion *rom_memory, bool isapc_ram_fw)
|
||||
bios);
|
||||
}
|
||||
|
||||
void pc_system_firmware_init(MemoryRegion *rom_memory, bool isapc_ram_fw)
|
||||
void pc_system_firmware_init(PCMachineState *pcms,
|
||||
MemoryRegion *rom_memory)
|
||||
{
|
||||
PCMachineClass *pcmc = PC_MACHINE_GET_CLASS(pcms);
|
||||
bool isapc_ram_fw = !pcmc->pci_enabled;
|
||||
DriveInfo *pflash_drv;
|
||||
|
||||
pflash_drv = drive_get(IF_PFLASH, 0, 0);
|
||||
|
@ -277,8 +277,7 @@ extern PCIDevice *piix4_dev;
|
||||
int piix4_init(PCIBus *bus, ISABus **isa_bus, int devfn);
|
||||
|
||||
/* pc_sysfw.c */
|
||||
void pc_system_firmware_init(MemoryRegion *rom_memory,
|
||||
bool isapc_ram_fw);
|
||||
void pc_system_firmware_init(PCMachineState *pcms, MemoryRegion *rom_memory);
|
||||
|
||||
/* acpi-build.c */
|
||||
void pc_madt_cpu_entry(AcpiDeviceIf *adev, int uid,
|
||||
|
Loading…
Reference in New Issue
Block a user