Michael S. Tsirkin [Tue, 14 Jun 2011 15:06:40 +0000 (18:06 +0300)]
alpha/translate: remve unused variables
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Richard Henderson <rth@twiddle.net>
Michael S. Tsirkin [Tue, 14 Jun 2011 17:15:41 +0000 (20:15 +0300)]
get_maintainer: update to match qemu tree
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Michael S. Tsirkin [Tue, 14 Jun 2011 17:13:42 +0000 (20:13 +0300)]
get_maintainer.pl: copy utility from Linux
Our MAINTAINERS file format matches Linux so
get the utility to parse it from there.
Updated as of linux 3.0-rc3
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Michael S. Tsirkin [Tue, 14 Jun 2011 14:15:34 +0000 (17:15 +0300)]
usb-ehci: move device/vendor/class id to qdev
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Michael S. Tsirkin [Tue, 14 Jun 2011 14:14:52 +0000 (17:14 +0300)]
ppce500: move device/vendor/class id to qdev
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Tue, 14 Jun 2011 22:37:47 +0000 (07:37 +0900)]
pci: don't call qdev pci init method
As pci id initialization is moved to common layer,
some initialization function can be empty.
So don't call init method if NULL.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Michael S. Tsirkin [Tue, 14 Jun 2011 14:51:11 +0000 (17:51 +0300)]
Merge remote-tracking branch 'origin/master' into pci
Conflicts:
hw/virtio-pci.c
Michael Tokarev [Thu, 9 Jun 2011 20:55:57 +0000 (00:55 +0400)]
print meaningful error message in case of --disable-vhost-net
When qemu gets compiled without support of vhost-net, any attempt
to use it fails with a very clear error message:
qemu-system-x86_64: -netdev ...,vhost=on: vhost-net requested but could not be initialized
there's absolutely no reason given _why_ it coult not be
initialized, and even strace'ing the process in question
does not reveal any errors. So print a message telling
what's going on.
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Michael S. Tsirkin [Sun, 12 Jun 2011 13:31:38 +0000 (16:31 +0300)]
virtio: compat event idx support
Disable event index for compat machine types.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Peter Maydell [Thu, 9 Jun 2011 21:54:29 +0000 (22:54 +0100)]
configure: Detect and don't try to use older libcurl
Older versions of libcurl don't have some of the features we try to
use, in particular curl_multi_setopt(). Check for this in the 'is
libcurl available?' configure test so we disable curl support if the
library is too old.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
Peter Maydell [Thu, 9 Jun 2011 10:43:12 +0000 (11:43 +0100)]
Changelog: Add explanatory note that this file is no longer updated
Add an explanatory note to the top of Changelog pointing at the
wiki and git history for changelogs for more recent releases.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
Michael S. Tsirkin [Sun, 12 Jun 2011 13:21:57 +0000 (16:21 +0300)]
virtio: event index support
Add support for event_idx feature, and utilize it to
reduce the number of interrupts and exits for the guest.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Jan Kiszka [Thu, 9 Jun 2011 07:39:56 +0000 (09:39 +0200)]
msix: Use replace local defines with pci_regs versions
This also cleans up an open-coded 64-bit message address readout.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Jan Kiszka [Thu, 9 Jun 2011 07:18:30 +0000 (09:18 +0200)]
pci: Update pci_regs header
Pulls in latest version from kernel 3.0-rc2.
Some changes around AER now require local defines as QEMU accesses the
error source identification register via sub-words.
CC: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Jan Kiszka [Tue, 7 Jun 2011 17:26:20 +0000 (19:26 +0200)]
msi: Fix copy&paste mistake in msi_uninit
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Jason Wang [Wed, 18 May 2011 05:57:37 +0000 (13:57 +0800)]
virtio: correctly initialize vm_running
Current vm_running was not explicitly initialized and its value was changed by
vm state notifier, this may confuse the virtio device being hotplugged such as
virtio-net with vhost backend as it may think the vm was not running. Solve this
by initialize this value explicitly in virtio_common_init().
Signed-off-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Stefan Hajnoczi [Sun, 8 May 2011 21:29:07 +0000 (22:29 +0100)]
virtio: guard against negative vq notifies
The virtio_queue_notify() function checks that the virtqueue number is
less than the maximum number of virtqueues. A signed comparison is used
but the virtqueue number could be negative if a buggy or malicious guest
is run. This results in memory accesses outside of the virtqueue array.
It is risky doing input validation in common code instead of at the
guest<->host boundary. Note that virtio_queue_set_addr(),
virtio_queue_get_addr(), virtio_queue_get_num(), and many other virtio
functions do *not* validate the virtqueue number argument.
Instead of fixing the comparison in virtio_queue_notify(), move the
comparison to the virtio bindings (just like VIRTIO_PCI_QUEUE_SEL) where
we have a uint32_t value and can avoid ever calling into common virtio
code if the virtqueue number is invalid.
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:36 +0000 (10:58 +0900)]
virtio-pci.c: convert to PCIDEviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:35 +0000 (10:58 +0900)]
hw/xio3130_upstream.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:34 +0000 (10:58 +0900)]
hw/xio3130_downstream.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:33 +0000 (10:58 +0900)]
hw/wdt_i6300esb.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:32 +0000 (10:58 +0900)]
hw/vt82c686.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:31 +0000 (10:58 +0900)]
hw/vga-pci.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:30 +0000 (10:58 +0900)]
hw/versatile_pci.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:29 +0000 (10:58 +0900)]
hw/usb-ohci.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:28 +0000 (10:58 +0900)]
hw/unin_pci.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:27 +0000 (10:58 +0900)]
hw/sun4u.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:26 +0000 (10:58 +0900)]
hw/sh_pci.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:25 +0000 (10:58 +0900)]
hw/rtl8139.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:24 +0000 (10:58 +0900)]
hw/qxl.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:23 +0000 (10:58 +0900)]
hw/piix_pci.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:22 +0000 (10:58 +0900)]
hw/piix4.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:21 +0000 (10:58 +0900)]
hw/pcnet-pci.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:20 +0000 (10:58 +0900)]
hw/ne2000.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:19 +0000 (10:58 +0900)]
hw/lsi53c895a.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:18 +0000 (10:58 +0900)]
hw/ivshmem.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:17 +0000 (10:58 +0900)]
hw/ioh3420.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:16 +0000 (10:58 +0900)]
hw/intel-hda.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:15 +0000 (10:58 +0900)]
hw/ide/via.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:14 +0000 (10:58 +0900)]
hw/ide/ich.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:13 +0000 (10:58 +0900)]
hw/ide/cmd646.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:12 +0000 (10:58 +0900)]
hw/gt64xxx.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:11 +0000 (10:58 +0900)]
hw/grackle_pci.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:10 +0000 (10:58 +0900)]
hw/es1370.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:09 +0000 (10:58 +0900)]
hw/e1000.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:08 +0000 (10:58 +0900)]
hw/cirrus_vga.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:07 +0000 (10:58 +0900)]
hw/bonito.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:06 +0000 (10:58 +0900)]
hw/acpi_piix4.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:05 +0000 (10:58 +0900)]
hw/ac97.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:04 +0000 (10:58 +0900)]
vmware_vga.c: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:03 +0000 (10:58 +0900)]
ide/piix: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:02 +0000 (10:58 +0900)]
apb_pci: convert to PCIDeviceInfo to initialize ids
Use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:01 +0000 (10:58 +0900)]
dec_pci: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:58:00 +0000 (10:58 +0900)]
eepro100: convert to PCIDeviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:57:59 +0000 (10:57 +0900)]
usb-uhci: convert to PCIDEviceInfo to initialize ids
use PCIDeviceInfo to initialize ids.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Isaku Yamahata [Wed, 25 May 2011 01:57:58 +0000 (10:57 +0900)]
pci: move ids of config space into PCIDeviceInfo
vender id/device id... in configuration space are read-only registers
which are commonly defined for all pci devices.
So move those initialization into common place.
Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Alex Williamson [Tue, 3 May 2011 18:36:58 +0000 (12:36 -0600)]
CPUPhysMemoryClient: batch addresses in catchup
When a phys memory client registers and we play catchup by walking
the page tables, we can make a huge improvement in the number of
times the set_memory callback is called by batching contiguous
pages together. With a 4G guest, this reduces the number of callbacks
at registration from 1048866 to 296.
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Brad Hards [Wed, 8 Jun 2011 21:50:43 +0000 (07:50 +1000)]
doc: Minor typo fix.
Thanks to agraf_, stefanha and Snader_LB for their IRC assistance.
Thanks to Markus Armbruster and Alexander Graf (again) for their
assistance with the second version of this patch. No patch is too
simple to test...
Signed-off-by: Brad Hards <bradh@frogmouth.net>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
Alexander Graf [Wed, 8 Jun 2011 22:55:37 +0000 (00:55 +0200)]
sigfd: use pthread_sigmask
Qemu uses signalfd to figure out, if a signal occured without the need
to actually receive the signal. Instead, it can read from the fd to receive
its news.
Now, we obviously don't always have signalfd around. Especially not on
non-Linux systems. So what we do there is that we create a new thread,
block that thread on all signals and simply call sigwait to wait for a
signal we're interested in to occur.
This all sounds great, but what we're really doing is:
sigset_t all;
sigfillset(&all);
sigprocmask(SIG_BLOCK, &all, NULL);
which - on Darwin - blocks all signals on the current _process_, not only
on the current thread. To block signals on the thread, we can use
pthread_sigmask().
This patch does that, assuming that my above analysis is correct, and thus
renders Qemu useable on Darwin again.
Reported-by: Andreas Färber <andreas.faerber@web.de>
Acked-by: Paolo Bonizni <pbonzini@redhat.com>
CC: Jan Kiszka <jan.kiszka@siemens.com>
CC: Anthony Liguori <anthony@codemonkey.ws>
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
Edgar E. Iglesias [Fri, 10 Jun 2011 20:21:14 +0000 (22:21 +0200)]
Merge remote branch 'rth/axp-next' into alpha-merge
* rth/axp-next: (26 commits)
target-alpha: Implement TLB flush primitives.
target-alpha: Use a fixed frequency for the RPCC in system mode.
target-alpha: Trap for unassigned and unaligned addresses.
target-alpha: Remap PIO space for 43-bit KSEG for EV6.
target-alpha: Implement cpu_alpha_handle_mmu_fault for system mode.
target-alpha: Implement more CALL_PAL values inline.
target-alpha: Disable interrupts properly.
target-alpha: All ISA checks to use TB->FLAGS.
target-alpha: Swap shadow registers moving to/from PALmode.
target-alpha: Implement do_interrupt for system mode.
target-alpha: Add IPRs to be used by the emulation PALcode.
target-alpha: Use kernel mmu_idx for pal_mode.
target-alpha: Add various symbolic constants.
target-alpha: Use do_restore_state for arithmetic exceptions.
target-alpha: Tidy up arithmetic exceptions.
target-alpha: Tidy exception constants.
target-alpha: Enable the alpha-softmmu target.
target-alpha: Rationalize internal processor registers.
target-alpha: Merge HW_REI and HW_RET implementations.
target-alpha: Cleanup MMU modes.
...
Edgar E. Iglesias [Fri, 10 Jun 2011 13:29:11 +0000 (15:29 +0200)]
fsdev: Fix archs that dont use fsdev
Fix provided by: "Aneesh Kumar K.V" <aneesh.kumar@linux.vnet.ibm.com>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
Anthony Liguori [Wed, 8 Jun 2011 17:16:24 +0000 (12:16 -0500)]
Merge remote-tracking branch 'qmp/for-anthony' into staging
Anthony Liguori [Wed, 8 Jun 2011 17:15:43 +0000 (12:15 -0500)]
Merge remote-tracking branch 'jvrao/for-anthony' into staging
Anthony Liguori [Wed, 8 Jun 2011 17:15:11 +0000 (12:15 -0500)]
Merge remote-tracking branch 'spice/spice.v37' into staging
Conflicts:
vl.c
Anthony Liguori [Wed, 8 Jun 2011 17:13:58 +0000 (12:13 -0500)]
Merge remote-tracking branch 'stefanha/trivial-patches' into staging
Kevin Wolf [Tue, 31 May 2011 13:01:46 +0000 (15:01 +0200)]
qemu-img create: Fix displayed default cluster size
When not specifying a cluster size on the command line, qemu-img printed
a cluster size of 0:
Formatting '/tmp/test.qcow2', fmt=qcow2 size=
67108864
encryption=off cluster_size=0
This patch adds the default cluster size to the QEMUOptionParameter list, so
that it displays the default value that is used.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Kevin Wolf [Wed, 1 Jun 2011 12:03:31 +0000 (14:03 +0200)]
bdrv_img_create: Fix segfault
Block drivers that don't support creating images don't have a size option. Fail
gracefully instead of segfaulting when trying to access the option's value.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Kevin Wolf [Wed, 1 Jun 2011 08:50:00 +0000 (10:50 +0200)]
qcow2: Fix memory leaks in error cases
This fixes memory leaks that may be caused by I/O errors during L1 table growth
(can happen during save_vm) and in qemu-img check.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Josh Durgin [Thu, 26 May 2011 23:07:34 +0000 (16:07 -0700)]
rbd: Add bdrv_truncate implementation
Reviewed-by: Christian Brunner <chb@muc.de>
Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Josh Durgin [Thu, 26 May 2011 23:07:33 +0000 (16:07 -0700)]
rbd: check return values when scheduling aio
If scheduling fails, the number of outstanding I/Os must be correct,
or there will be a hang when waiting for everything to be flushed.
Reviewed-by: Christian Brunner <chb@muc.de>
Reported-by: Stefan Hajnoczi <stefanha@gmail.com>
Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Josh Durgin [Thu, 26 May 2011 23:07:32 +0000 (16:07 -0700)]
rbd: allow configuration of rados from the rbd filename
The new format is rbd:pool/image[@snapshot][:option1=value1[:option2=value2...]]
Each option is used to configure rados, and may be any Ceph option, or "conf".
The "conf" option specifies a Ceph configuration file to read.
This allows rbd volumes from more than one Ceph cluster to be used by
specifying different monitor addresses, as well as having different
logging levels or locations for different volumes.
Reviewed-by: Christian Brunner <chb@muc.de>
Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Josh Durgin [Thu, 26 May 2011 23:07:31 +0000 (16:07 -0700)]
rbd: use the higher level librbd instead of just librados
librbd stacks on top of librados to provide access
to rbd images.
Using librbd simplifies the qemu code, and allows
qemu to use new versions of the rbd format
with few (if any) changes.
Reviewed-by: Christian Brunner <chb@muc.de>
Signed-off-by: Josh Durgin <josh.durgin@dreamhost.com>
Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Christoph Egger [Mon, 23 May 2011 12:31:17 +0000 (14:31 +0200)]
block/raw-posix: get right partition size
use the correct way to get the size of a disk device or partition
From: Adam Hamsik <haad@netbsd.org>
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Christoph Egger [Tue, 24 May 2011 09:30:29 +0000 (11:30 +0200)]
block/raw-posix: use a character device if a block device is given
On NetBSD a userland process is better with the character device
interface. In addition, a block device can't be opened twice; if a Xen
backend opens it, qemu can't and vice-versa.
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Alexander Graf [Tue, 24 May 2011 22:46:55 +0000 (00:46 +0200)]
vmdk: fix endianness bugs
The vmdk code is sloppy when handling the header descriptor during
creation of an image. Fix all header accesses in the create path to
either store native endianness or convert it when appropriate.
Reported-by: Yury Tsarev <ytsarev@novell.com>
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Christoph Hellwig [Tue, 17 May 2011 16:04:06 +0000 (18:04 +0200)]
block: clarify the meaning of BDRV_O_NOCACHE
Change BDRV_O_NOCACHE to only imply bypassing the host OS file cache,
but no writeback semantics. All existing callers are changed to also
specify BDRV_O_CACHE_WB to give them writeback semantics.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Kevin Wolf [Thu, 19 May 2011 14:42:24 +0000 (16:42 +0200)]
ide/core: Remove explicit setting of BM_STATUS_INT
BM_STATUS_INT is automatically set during ide_set_irq(), there's no reason to
set it manually in addition.
There is even one case where the interrupt status bit was set, but no IRQ was
raised. This is when the PRD table was reached but there is more data to
transfer. The correct behaviour for this case is not to set BM_STATUS_INT.
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Jan Kiszka [Tue, 26 Apr 2011 01:32:08 +0000 (01:32 +0000)]
virtio: Move virtio-pci to hw library
This module has no target dependencies (except for target_phys_addr_t
size) and can thus be built as part of libhw.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Reviewed-by: Aurelien Jarno <aurelien@aurel32.net>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Martin Simmons [Mon, 6 Jun 2011 14:49:17 +0000 (15:49 +0100)]
target-i386: Make x86 mfence and lfence illegal without SSE2
While trying to use qemu -cpu pentium3 to test for incorrect uses of certain
SSE2 instructions, I found that QEMU allowed the mfence and lfence
instructions to be executed even though Pentium 3 doesn't support them.
According to the processor specs (and experience on a real Pentium 3), these
instructions are only available with SSE2, but QEMU is checking for SSE. The
check for the related sfence instruction is correct (it works with SSE).
This trival patch fixes the test.
Signed-off-by: Martin Simmons <martin@lispworks.com>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Laurent Vivier [Fri, 25 Mar 2011 09:36:36 +0000 (09:36 +0000)]
m68k: Replace gen_im32() by tcg_const_i32()
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Reviewed-by: Andreas Färber <andreas.faerber@web.de>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Alexander Graf [Sat, 4 Jun 2011 05:25:59 +0000 (07:25 +0200)]
slirp: fix guestfwd id
When using -net user,guestfwd=... Qemu immediately complains about the id
being in invalid format. This is because we pass in an id that contains a
colon, while the id restrictions don't allow colons.
This patch changes the colon into a dot, making guestfwd work again.
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Alexandre Raymond [Fri, 3 Jun 2011 03:26:49 +0000 (23:26 -0400)]
Fix compilation warning due to missing header for sigaction (followup)
This patch removes all references to signal.h when qemu-common.h is included
as they become redundant.
Signed-off-by: Alexandre Raymond <cerbere@gmail.com>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Alexandre Raymond [Thu, 2 Jun 2011 02:21:30 +0000 (22:21 -0400)]
Fix compilation warning due to missing header for sigaction
Fix the following warning by including signal.h directly in qemu-common.h
----8<----
iohandler.c: In function ‘qemu_init_child_watch’:
iohandler.c:172: warning: implicit declaration of function ‘sigaction’
iohandler.c:172: warning: nested extern declaration of ‘sigaction’
----8<----
Signed-off-by: Alexandre Raymond <cerbere@gmail.com>
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
Glauber Costa [Mon, 16 May 2011 18:45:08 +0000 (15:45 -0300)]
Add an isa device for SGA
This patch adds a dummy legacy ISA device whose responsibility is to
deploy sgabios, an option rom for a serial graphics adapter.
The proposal is that this device is always-on when -nographics,
but can otherwise be enable in any setup when -device sga is used.
[v2: suggestions on qdev by Markus ]
[v3: cleanups and documentation, per list suggestions ]
Signed-off-by: Glauber Costa <glommer@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Michael Roth [Wed, 1 Jun 2011 17:15:00 +0000 (12:15 -0500)]
json-parser: add handling for NULL token list
Currently a NULL token list will crash the parser, instead we have it
pass back a NULL QObject.
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Michael Roth [Wed, 1 Jun 2011 17:14:59 +0000 (12:14 -0500)]
json-streamer: add handling for JSON_ERROR token/state
This allows a JSON_ERROR state to be passed to the streamer to force a
flush of the current tokens and pass a NULL token list to the parser
rather that have it churn on bad data. (Alternatively we could just not
pass it to the parser at all, but it may be useful to push there errors
up the stack. NULL token lists are not currently handled by the parser,
the next patch will address that)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Michael Roth [Wed, 1 Jun 2011 17:14:58 +0000 (12:14 -0500)]
json-lexer: make lexer error-recovery more deterministic
Currently when we reach an error state we effectively flush everything
fed to the lexer, which can put us in a state where we keep feeding
tokens into the parser at arbitrary offsets in the stream. This makes it
difficult for the lexer/tokenizer/parser to get back in sync when bad
input is made by the client.
With these changes we emit an error state/token up to the tokenizer as
soon as we reach an error state, and continue processing any data passed
in rather than bailing out. The reset token will be used to reset the
tokenizer and parser, such that they'll recover state as soon as the
lexer begins generating valid token sequences again.
We also map chr(192,193,245-255) to an error state here, since they are
invalid UTF-8 characters. QMP guest proxy/agent will use chr(255) to
force a flush/reset of previous input for reliable delivery of certain
events, so also we document that thoroughly here.
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Michael Roth [Wed, 1 Jun 2011 17:14:57 +0000 (12:14 -0500)]
json-lexer: fix flushing logic to not always go to error state
Currently we flush the lexer by passing in a NULL character. This
generally forces the lexer to go to the corresponding TERMINAL() state
for whatever token type it is currently parsing, emits the token to the
parser, then puts the lexer back into IN_START state. However, since a
NULL character causes char_consumed to be 0, we always do a second pass
after this, which puts us in the IN_ERROR state. Fix this behavior by
adding a "flush" flag that tells the lexer not to do a more than 1
iteration.
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Anthony Liguori [Wed, 1 Jun 2011 17:14:56 +0000 (12:14 -0500)]
json-lexer: reset the lexer state on an invalid token
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Anthony Liguori [Wed, 1 Jun 2011 17:14:55 +0000 (12:14 -0500)]
json-parser: detect premature EOI
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Anthony Liguori [Wed, 1 Jun 2011 17:14:54 +0000 (12:14 -0500)]
json-streamer: make sure to reset token_size after emitting a token list
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Anthony Liguori [Wed, 1 Jun 2011 17:14:53 +0000 (12:14 -0500)]
json-streamer: limit the maximum recursion depth and maximum token count
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Anthony Liguori [Wed, 1 Jun 2011 17:14:52 +0000 (12:14 -0500)]
json-lexer: limit the maximum size of a given token
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Anthony Liguori [Wed, 1 Jun 2011 17:14:51 +0000 (12:14 -0500)]
json-streamer: allow recovery after bad input
Once we detect a malformed message, make sure to reset our state.
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Anthony Liguori [Wed, 1 Jun 2011 17:14:50 +0000 (12:14 -0500)]
json-parser: propagate error from parser
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Luiz Capitulino [Wed, 1 Jun 2011 17:14:49 +0000 (12:14 -0500)]
Introduce the new error framework
New error-handling framework that allows for exception-like error
propagation.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Luiz Capitulino [Wed, 1 Jun 2011 17:14:48 +0000 (12:14 -0500)]
QError: Introduce qerror_format()
Will be used by new error propagation framework to convert Error objects
into human-readable form.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Luiz Capitulino [Wed, 1 Jun 2011 17:14:47 +0000 (12:14 -0500)]
QError: Introduce qerror_format_desc()
Refactor non-QError-specific bits out of qerror_human() into general
function that can be used by the error_get_pretty() analogue in the
new error-propagation framework.
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Markus Armbruster [Tue, 7 Jun 2011 08:34:31 +0000 (10:34 +0200)]
docs: qdev-device-use.txt has become stale, update it
Document more bus addresses.
Update for bugs fixed.
Describe where exactly the -drive options go.
Update for recent split of qdev ide-drive into ide-{cd,hd},
scsi-disk into scsi-{cd,hd}.
Document scsi-hd's removable property only for usb-storage, because
that's where it's used.
Fix description of -global isa.fdc.
Document usb-storage lossage.
Clean up misleading description of network device's split into guest
and host part.
Document -vga's machine dependence.
New qdevs: virtconsole, qxl-vga, isa-vga, intel-hda, usb-ccid
Update for changed pci-assign property iommu.
New section "Default Devices".
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Markus Armbruster [Tue, 7 Jun 2011 08:34:30 +0000 (10:34 +0200)]
isa-vga: Make available with -device, like the other VGA qdevs
Switch no_user off and make it suppress the default VGA.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>