From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50143) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VQb0W-0001JS-H0 for qemu-devel@nongnu.org; Mon, 30 Sep 2013 06:47:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VQb0K-0000Wk-GQ for qemu-devel@nongnu.org; Mon, 30 Sep 2013 06:47:16 -0400 Received: from mx1.redhat.com ([209.132.183.28]:60068) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VQb0K-0000Wg-7X for qemu-devel@nongnu.org; Mon, 30 Sep 2013 06:47:04 -0400 From: Gerd Hoffmann Date: Mon, 30 Sep 2013 12:46:59 +0200 Message-Id: <1380538019-9091-3-git-send-email-kraxel@redhat.com> In-Reply-To: <1380538019-9091-1-git-send-email-kraxel@redhat.com> References: <1380538019-9091-1-git-send-email-kraxel@redhat.com> Subject: [Qemu-devel] [PATCH 2/2] machine type dependant bios List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Gerd Hoffmann , Anthony Liguori Signed-off-by: Gerd Hoffmann --- 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