Wouldn't this be logical as a machine option? They way you are introducing it makes it impossible to control with -global.
Regards, Anthony Liguori On Mon, Sep 30, 2013 at 5:46 AM, Gerd Hoffmann <kra...@redhat.com> wrote: > Signed-off-by: Gerd Hoffmann <kra...@redhat.com> > --- > hw/i386/pc_piix.c | 1 + > hw/i386/pc_q35.c | 1 + > hw/i386/pc_sysfw.c | 4 ++-- > include/hw/i386/pc.h | 2 ++ > 4 files changed, 6 insertions(+), 2 deletions(-) > > diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c > index 907792b..35188a5 100644 > --- a/hw/i386/pc_piix.c > +++ b/hw/i386/pc_piix.c > @@ -238,6 +238,7 @@ static void pc_init_pci(QEMUMachineInitArgs *args) > > static void pc_compat_1_6(QEMUMachineInitArgs *args) > { > + pc_default_bios_name = "bios-128k.bin"; > has_pci_info = false; > rom_file_in_ram = false; > } > diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c > index ca84e1c..e8b0168 100644 > --- a/hw/i386/pc_q35.c > +++ b/hw/i386/pc_q35.c > @@ -222,6 +222,7 @@ static void pc_q35_init(QEMUMachineInitArgs *args) > > static void pc_compat_1_6(QEMUMachineInitArgs *args) > { > + pc_default_bios_name = "bios-128k.bin"; > has_pci_info = false; > rom_file_in_ram = false; > } > diff --git a/hw/i386/pc_sysfw.c b/hw/i386/pc_sysfw.c > index e917c83..deb8869 100644 > --- a/hw/i386/pc_sysfw.c > +++ b/hw/i386/pc_sysfw.c > @@ -34,7 +34,7 @@ > #include "hw/block/flash.h" > #include "sysemu/kvm.h" > > -#define BIOS_FILENAME "bios.bin" > +const char *pc_default_bios_name = "bios-256k.bin"; > > typedef struct PcSysFwDevice { > SysBusDevice busdev; > @@ -112,7 +112,7 @@ static void old_pc_system_rom_init(MemoryRegion > *rom_memory, bool isapc_ram_fw) > > /* BIOS load */ > if (bios_name == NULL) { > - bios_name = BIOS_FILENAME; > + bios_name = pc_default_bios_name; > } > filename = qemu_find_file(QEMU_FILE_TYPE_BIOS, bios_name); > if (filename) { > diff --git a/include/hw/i386/pc.h b/include/hw/i386/pc.h > index 9b2ddc4..cf9e47e 100644 > --- a/include/hw/i386/pc.h > +++ b/include/hw/i386/pc.h > @@ -12,6 +12,8 @@ > > /* PC-style peripherals (also used by other machines). */ > > +extern const char *pc_default_bios_name; > + > typedef struct PcPciInfo { > Range w32; > Range w64; > -- > 1.8.3.1 > >