summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2009-12-12qdev: make compat stuff more genericGerd Hoffmann6-16/+24
This patch renames the compat properties into global properties and makes them more generic. The compatibility stuff is only one of multiple possible users now. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12kvm: x86: Save/restore exception_indexJan Kiszka2-1/+2
As KVM now makes use of exception_index to keep pending exceptions, we have to save&restore this field as well. NOTE: We have to nail the arch-independent exception_index down to a certain bit width for proper vmstate processing, namely to 32 bit. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12Fix recently added QERR_ definitionsMarkus Armbruster1-4/+4
Commits c7c338c4, 41471a23, 7a046f5f and a488be27 used lower_case_with_underscores for class values. Existing usage CamelCase. ChangeToThatForConsistency. Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12qdev: Replace device names containing whitespaceMarkus Armbruster19-63/+56
Device names with whitespace require quoting in the shell and in the monitor. Some of the offenders are also overly long. Some have a more convenient alias, some don't. The place for verbose device names is DeviceInfo member desc. The name should be short & sweet. Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12qdev: Separate USB product description from qdev nameMarkus Armbruster11-1/+15
Using the qdev name for the product description makes for inconvenient qdev names. Put the product description in new USBDeviceInfo member product_desc. Make usb_qdev_init() use it. No user or guest visible change, since the value is still the same. Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12qdev: Rename USBDevice member devname to product_descMarkus Armbruster6-12/+13
It's not a device name, it's the USB product description string. Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12fix rtc-td-hack on host without high-res timersGleb Natapov1-0/+17
On hosts without high-res timers it is impossible to inject rtc interrupt faster then 1kHz. Windows sometimes configures RTC to generate 1kHz interrupts, so we can't inject missed interrupts when running on such hosts. Always injecting an interrupt on REG_C read is also not an option since Windows wait for REG_C to become zero with interrupt disabled during boot. This patch uses mixed approach: accelerate timer + inject up to 1000 interrupts on REG_C read. Signed-off-by: Gleb Natapov <gleb@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12virtio: verify features on loadMichael S. Tsirkin4-6/+37
migrating between hosts which have different features might break silently, if the migration destination does not support some features supported by source. Prevent this from happening by comparing acked feature bits with the mask supported by the device. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12vmware_vga: add rom file so that it boots.Dave Airlie1-0/+2
This just adds the rom file to the vmware SVGA chipset so it boots. Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-12Do not abort on qemu_malloc(0) in production buildsAnthony Liguori2-7/+30
qemu_malloc() does not allow size=0 to be passed in and aborts on this behavior. Unfortunately, there is good reason to believe that within qemu, there are a number of, so far, undetected places that assume size=0 can be safely passed. Since we do not want to abort unnecessarily in production builds, return qemu_malloc(1) whenever the version file indicates that this is a production build. Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-11Fix ARM userspace strex implementation.Paul Brook1-0/+1
Signed-off-by: Paul Brook <paul@codesourcery.com>
2009-12-10microblaze: Make boot_info static.Edgar E. Iglesias1-1/+1
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2009-12-10microblaze: Add missing cpu_reset.Edgar E. Iglesias1-0/+2
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2009-12-10microblaze: Boot and reset fixes.Edgar E. Iglesias1-13/+16
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2009-12-10microblaze: Update disasm to latest GPLv2 version.Edgar E. Iglesias1-96/+354
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
2009-12-07qemu: delete rule target on errorMichael S. Tsirkin1-0/+3
Instruct make to remove any rule target on error. This prevetns situation where there was an error during build but generated file still stays behind. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QMP: add human-readable description to error responseMarkus Armbruster4-6/+23
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07monitor: convert do_getfd() to QErrorMarkus Armbruster1-4/+6
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: New QERR_TOO_MANY_FILESMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07New QERR_INVALID_PARAMETERMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: New QERR_FD_NOT_SUPPLIEDMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07monitor: convert do_closefd() to QErrorMarkus Armbruster1-2/+1
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: New QERR_FD_NOT_FOUNDMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07monitor: convert do_change() to QObject, QErrorMarkus Armbruster2-9/+13
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: New QERR_VNC_SERVER_FAILEDMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: New QERR_SET_PASSWD_FAILEDMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: New QERR_INVALID_BLOCK_FORMATMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07monitor: convert do_eject() to QErrorMarkus Armbruster1-3/+4
Also affects do_change(), because the two share eject_device(). Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: New QERR_DEVICE_NOT_REMOVABLEMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: New QERR_DEVICE_LOCKEDMarkus Armbruster2-0/+7
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: Put error definitions in alphabetical orderMarkus Armbruster2-29/+29
Also fix the odd typoe and clean up whitespace. Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07monitor: Fix double-prompt after "change vnc passwd BLA"Markus Armbruster1-3/+8
Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07monitor: do_cont(): Don't ask for passwordsLuiz Capitulino1-1/+9
The do_cont() function will ask the user to enter a password if a device is encrypted. This is invalid under QMP, so we raise a QERR_DEVICE_ENCRYPTED error. Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: new class for device encrypted errorsLuiz Capitulino2-0/+7
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07Merge commit 'mst/pci' into stagingAnthony Liguori3-43/+179
2009-12-07monitor: Introduce 'block_passwd' commandLuiz Capitulino2-0/+30
When using encrypted disk images, QEMU will prompt the user for passwords when started. This makes sense for the user protocol, but doesn't for QMP. The solution is to have Monitor command which allows the user or a Client to set passwords in advance, so that we avoid the prompt completely. This is what block_passwd does, for example: (QEMU) block_passwd ide0-hd0 foobar Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07QError: Add class for invalid passwordsLuiz Capitulino2-0/+7
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07pci: interrupt disable bit supportMichael S. Tsirkin2-2/+28
Interrupt disable bit is mandatory in PCI spec. Implement it to make devices spec compliant. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Acked-by: Isaku Yamahata <yamahata@valinux.co.jp>
2009-12-07pci: interrupt status bit implementationMichael S. Tsirkin2-1/+26
interrupt status is a mandatory feature in PCI spec, so devices must implement it to be spec compliant. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Acked-by: Isaku Yamahata <yamahata@valinux.co.jp>
2009-12-07pci: prepare irq code for interrupt stateMichael S. Tsirkin2-17/+74
This rearranges code in preparation for interrupt state implementation. Changes: - split up bus walk away from interrupt handling into a subroutine - change irq_state from an array to bitmask - verify that irq_state values are 0 or 1 on load There are no functional changes. Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Acked-by: Isaku Yamahata <yamahata@valinux.co.jp>
2009-12-07msix: function mask supportMichael S. Tsirkin1-18/+46
Function mask is a mandatory feature in MSIX spec so not implementing it is a spec violation. Implement. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2009-12-07msix: macro rename for function mask supportMichael S. Tsirkin1-7/+7
rename ENABLE_OFFSET -> CONTROL_OFFSET, since same byte includes function mask. This is in preparation for function mask support. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
2009-12-07cpuid: Fix multicore setup on IntelAndre Przywara1-15/+31
The multicore CPUID code detects whether the guest is an Intel or an AMD CPU, because the Linux kernel is picky about the CmpLegacy bit. KVM by default passes through the host's vendor, which was not catched by the code. So fork out the vendor determining bits into a separate function to be used from both places and always get the real vendor. This fixes KVM's multicore setup on Intel CPUs. Signed-off-by: Andre Przywara <andre.przywara@amd.com> Reported-by: Dietmar Maurer <dietmar@proxmox.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-07kvm: x86: Fix initial kvm_has_msr_starJan Kiszka1-2/+2
KVM_GET_MSR_INDEX_LIST returns -E2BIG when the provided space is too small for all MSRs. But this is precisely the error we trigger with the initial request in order to obtain that size. Do not fail in that case. This caused a subtle corruption of the guest state as MSR_STAR was not properly saved/restored. The corruption became visible with latest kvm optimizing the MSR updates. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2009-12-06TCG: Mac OS X support for ppc64 targetAndreas Faerber1-14/+41
Darwin/ppc64 does not use function descriptors, adapt prologue and tcg_out_call accordingly. GPR2 is available for general use, so let's use it. http://developer.apple.com/mac/library/documentation/DeveloperTools/Conceptual/LowLevelABI/110-64-bit_PowerPC_Function_Calling_Conventions/64bitPowerPC.html v2: - Don't mark reserved GPR13 as callee-save. - Move tcg_out_b up. - Fix unused variable warning in prologue. Signed-off-by: Andreas Faerber <andreas.faerber@web.de> Cc: malc <av1474@comtv.ru> Signed-off-by: malc <av1474@comtv.ru>
2009-12-06Update OpenBIOS images to r640Blue Swirl4-1/+1
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
2009-12-05Add S390 maintainer informationv0.12.0-rc0Alexander Graf1-0/+3
This patch adds information about who handles what when it comes to S390. I'll gladly support anything that's related to the device emulation model and S390 KVM parts. Since this patchset doesn't implement S390 CPU emulation, I left that part with a question mark. As soon as Uli's patchset gets committed I'd recommend setting him there. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-12-05Set default console to virtio on S390xAlexander Graf1-0/+26
All "normal" system emulation targets in qemu I'm aware of display output on either VGA or serial output. Our S390x virtio machine doesn't have such kind of legacy hardware. So instead we need to default to a virtio console. I'm not particularly proud of this patch. It would be a lot better to have something in the machine description that tells us about the default terminal. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-12-05S390 GDB stubAlexander Graf1-0/+52
In order to debug funny kernel breakages it's always good to have a working gdb stub around. While Uli's patches don't include one one, I needed one that's at least good enough for 'bt' and some variable examinations during early bootup. So here it is - the absolute basics to get the qemu gdb stub running with s390x targets. Sgined-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
2009-12-05Add S390x virtio machine descriptionAlexander Graf2-1/+256
In order to use the new S390x virtio bus we just introduced, we also need a machine description that sets up the machine according to our PV specification. Let's add that machine description and be happy! Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>