[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL v2 42/60] i386/pc_q35: don't insist on board FDC if t
From: |
Michael S. Tsirkin |
Subject: |
[Qemu-devel] [PULL v2 42/60] i386/pc_q35: don't insist on board FDC if there's no default floppy |
Date: |
Mon, 1 Jun 2015 14:24:50 +0200 |
From: Laszlo Ersek <address@hidden>
The "no_floppy = 1" machine class setting causes "default_floppy" in
main() to become zero. Consequently, default_drive() will not call
drive_add() and drive_new() for IF_FLOPPY, index=0, meaning that no
default floppy drive will be created for the virtual machine. In that
case, board code should also not insist on the creation of the
board-default FDC.
The board-default FDC will still be created if the user requests a floppy
drive with "-drive if=floppy".
Additionally, separate FDCs can be specified manually with "-device
isa-fdc". They allow the
-device isa-fdc,driveA=...
syntax that is more flexible than the one required by the board-default
FDC:
-global isa-fdc.driveA=...
This patch doesn't change the behavior observably, as all Q35 machine
types have "no_floppy = 0".
Cc: Markus Armbruster <address@hidden>
Cc: Paolo Bonzini <address@hidden>
Cc: Gerd Hoffmann <address@hidden>
Cc: John Snow <address@hidden>
Cc: "Gabriel L. Somlo" <address@hidden>
Cc: "Michael S. Tsirkin" <address@hidden>
Cc: Kevin Wolf <address@hidden>
Cc: address@hidden
Signed-off-by: Laszlo Ersek <address@hidden>
Reviewed-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
Reviewed-by: Markus Armbruster <address@hidden>
---
hw/i386/pc_q35.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
index 9ca317c..9f036c8 100644
--- a/hw/i386/pc_q35.c
+++ b/hw/i386/pc_q35.c
@@ -89,6 +89,7 @@ static void pc_q35_init(MachineState *machine)
PcGuestInfo *guest_info;
ram_addr_t lowmem;
DriveInfo *hd[MAX_SATA_PORTS];
+ MachineClass *mc = MACHINE_GET_CLASS(machine);
/* Check whether RAM fits below 4G (leaving 1/2 GByte for IO memory
* and 256 Mbytes for PCI Express Enhanced Configuration Access Mapping
@@ -163,7 +164,6 @@ static void pc_q35_init(MachineState *machine)
guest_info->legacy_acpi_table_size = 0;
if (smbios_defaults) {
- MachineClass *mc = MACHINE_GET_CLASS(machine);
/* These values are guest ABI, do not change */
smbios_set_defaults("QEMU", "Standard PC (Q35 + ICH9, 2009)",
mc->name, smbios_legacy_mode, smbios_uuid_encoded);
@@ -250,7 +250,7 @@ static void pc_q35_init(MachineState *machine)
}
/* init basic PC hardware */
- pc_basic_device_init(isa_bus, gsi, &rtc_state, true, &floppy,
+ pc_basic_device_init(isa_bus, gsi, &rtc_state, !mc->no_floppy, &floppy,
(pc_machine->vmport != ON_OFF_AUTO_ON), 0xff0104);
/* connect pm stuff to lpc */
--
MST
- [Qemu-devel] [PULL v2 36/60] virtio-s390: introduce virito s390 queue limit, (continued)
- [Qemu-devel] [PULL v2 36/60] virtio-s390: introduce virito s390 queue limit, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 37/60] virtio-s390: introduce virtio_s390_device_plugged(), Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 38/60] virtio: rename VIRTIO_PCI_QUEUE_MAX to VIRTIO_QUEUE_MAX, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 39/60] virtio: increase the queue limit to 1024, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 40/60] i386/pc: pc_basic_device_init(): delegate FDC creation request, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 41/60] i386/pc: '-drive if=floppy' should imply a board-default FDC, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 43/60] i386: drop FDC in pc-q35-2.4+ if neither it nor floppy drives are wanted, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 42/60] i386/pc_q35: don't insist on board FDC if there's no default floppy,
Michael S. Tsirkin <=
- [Qemu-devel] [PULL v2 44/60] acpi: Simplify printing to dynamic string, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 45/60] Add stream ID to MSI write, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 46/60] Extend TPM TIS interface to support TPM 2, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 47/60] tpm: Probe for connected TPM 1.2 or TPM 2, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 48/60] TPM2 ACPI table support, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 49/60] acpi: add aml_add() term, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 50/60] acpi: add aml_lless() term, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 51/60] acpi: add aml_index() term, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 53/60] acpi: add aml_shiftright() term, Michael S. Tsirkin, 2015/06/01
- [Qemu-devel] [PULL v2 52/60] acpi: add aml_shiftleft() term, Michael S. Tsirkin, 2015/06/01