[Qemu-devel] Re: [PATCH v2 0/6] qdev reset refactoring and pci bus reset

2010-11-23 Thread Isaku Yamahata
On Wed, Nov 24, 2010 at 07:27:58AM +0200, Michael S. Tsirkin wrote: > Right. So let's add an inline helper to avoid code duplication here? > > pci: fix bus walk under secondary bus reset > > Take into account secondary bus reset bit for > bus walk: devices behind a reset bus should not > respond

[Qemu-devel] Re: [PATCH] add a command line option to specify the IP address to send multicast packets from

2010-11-23 Thread Michael S. Tsirkin
On Wed, Nov 17, 2010 at 05:16:26PM -0800, Mike Ryan wrote: > Add an option to specify the host IP to send multicast packets from when > using a multicast socket for networking. The option takes an IP address > and sets the IP_MULTICAST_IF socket option, which causes the packets to > use that IP's i

[Qemu-devel] Re: [PATCH v2 0/6] qdev reset refactoring and pci bus reset

2010-11-23 Thread Michael S. Tsirkin
On Wed, Nov 24, 2010 at 11:37:25AM +0900, Isaku Yamahata wrote: > On Tue, Nov 23, 2010 at 08:10:26PM +0200, Michael S. Tsirkin wrote: > > On Tue, Nov 23, 2010 at 12:53:12AM +0200, Michael S. Tsirkin wrote: > > > On Mon, Nov 22, 2010 at 07:43:37PM +0900, Isaku Yamahata wrote: > > > > On Mon, Nov 22,

[Qemu-devel] [Bug 680758] [NEW] balloon only resizes by 2M

2010-11-23 Thread Michael Thomas
Public bug reported: when in monitor and running balloon 512 from a 1024M VM, the vm dropped the size to 1020 (this value changes), then every subsequent request to balloon 512 will drop it by another 2M. The system was running at above 60% RAM free when these requests were made. also requesting

Re: [Qemu-devel] [Patch] Small fix for qemu APIC for Mac OS X support

2010-11-23 Thread adq
On 23 November 2010 23:41, Alexander Graf wrote: > > On 23.11.2010, at 22:25, adq wrote: > >> This patch ups the APIC version from 0x11 to 0x14. After that Mac OS X >> loads successfully (with appropriate kexts, applesmc ain't hooked up >> properly yet I see unfortunately). >) > AppleSMC emulation

[Qemu-devel] [PATCH v5] virtio-9p: fix build on !CONFIG_UTIMENSAT

2010-11-23 Thread Hidetoshi Seto
This patch introduce a fallback mechanism for old systems that do not support utimensat(). This fix build failure with following warnings: hw/virtio-9p-local.c: In function 'local_utimensat': hw/virtio-9p-local.c:479: warning: implicit declaration of function 'utimensat' hw/virtio-9p-local.c:479:

[Qemu-devel] Re: [PATCH v2 0/6] qdev reset refactoring and pci bus reset

2010-11-23 Thread Isaku Yamahata
On Tue, Nov 23, 2010 at 08:10:26PM +0200, Michael S. Tsirkin wrote: > On Tue, Nov 23, 2010 at 12:53:12AM +0200, Michael S. Tsirkin wrote: > > On Mon, Nov 22, 2010 at 07:43:37PM +0900, Isaku Yamahata wrote: > > > On Mon, Nov 22, 2010 at 09:54:02AM +0200, Michael S. Tsirkin wrote: > > > > On Fri, Nov

[Qemu-devel] Re: [PATCH 10/12] config: Add header file for device config options

2010-11-23 Thread Juan Quintela
Alexander Graf wrote: > So far we have C preprocessor defines for target and host config > options, but we're lacking any information on which devices are > available. > > We do need that information at times though, for example in the > ahci patch where we need to call a legacy init function depe

Re: [Qemu-devel] [PATCH] qemu-kvm: response to SIGUSR1 to start/stop a VCPU (v2)

2010-11-23 Thread Paolo Bonzini
On 11/24/2010 02:15 AM, Anthony Liguori wrote: Is it signal safe? Yes, at heart it is just a somewhat more expensive access to pthread_self()->some_array[key]. BTW, this is all only theoretical. This is in the KVM io thread code which is already highly unportable. True, and newer versio

[Qemu-devel] Re: [PATCH] correct migrate_set_speed's args_type

2010-11-23 Thread Wen Congyang
At 2010年11月23日 21:31, Luiz Capitulino Write: > On Tue, 23 Nov 2010 10:43:48 -0200 > Luiz Capitulino wrote: > >> On Tue, 23 Nov 2010 13:41:26 +0800 >> Wen Congyang wrote: >> >>> The args_type of migrate_set_speed in qmp-commands.hx is wrong. >>> When we set migrate speed by json, qemu will be cor

[Qemu-devel] Re: [PATCHv6 00/16] boot order specification

2010-11-23 Thread Kevin O'Connor
Hi Gleb, On Tue, Nov 23, 2010 at 05:31:41PM +0200, Gleb Natapov wrote: > Anthony, Blue > > No comments on this patch series for almost a week. Can it be applied? My apologies - I haven't had time to review. > On Wed, Nov 17, 2010 at 06:43:47PM +0200, Gleb Natapov wrote: > > I am using open firm

Re: [Qemu-devel] [PATCH] qemu-kvm: response to SIGUSR1 to start/stop a VCPU (v2)

2010-11-23 Thread Anthony Liguori
On 11/23/2010 05:43 PM, Paolo Bonzini wrote: On 11/23/2010 10:46 PM, Anthony Liguori wrote: +static __thread int sigusr1_wfd; While OpenBSD finally updated the default compiler to 4.2.1 from 3.x series, thread local storage is still not supported: Hrm, is there a portable way to do this (dist

Re: [Qemu-devel] [PATCH] add a command line option to specify the IP address to send multicast packets from

2010-11-23 Thread Mike Ryan
On Tue, Nov 23, 2010 at 03:05:49PM +0200, Michael S. Tsirkin wrote: > On Mon, Nov 22, 2010 at 10:48:45AM -0800, Mike Ryan wrote: > > Michael, this patch implements the feature with a bind address instead > > of a bind interface. It should address the cross-platform issues that > > were raised. > >

Re: [Qemu-devel] [PATCH] qemu-kvm: response to SIGUSR1 to start/stop a VCPU (v2)

2010-11-23 Thread Paolo Bonzini
On 11/23/2010 10:46 PM, Anthony Liguori wrote: +static __thread int sigusr1_wfd; While OpenBSD finally updated the default compiler to 4.2.1 from 3.x series, thread local storage is still not supported: Hrm, is there a portable way to do this (distinguish a signal on a particular thread)? Yo

Re: [Qemu-devel] [Patch] Small fix for qemu APIC for Mac OS X support

2010-11-23 Thread Alexander Graf
On 23.11.2010, at 22:25, adq wrote: > This patch ups the APIC version from 0x11 to 0x14. After that Mac OS X > loads successfully (with appropriate kexts, applesmc ain't hooked up > properly yet I see unfortunately). AppleSMC emulation is upstream, but the ACPI entries are missing. Once you add

[Qemu-devel] [PATCH 09/10] Exit loop if we have been there too long

2010-11-23 Thread Juan Quintela
From: Juan Quintela cheking each 64 pages is a random magic number as good as any other. We don't want to test too many times, but on the other hand, qemu_get_clock_ns() is not so expensive either. Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- arch_init.c | 16 ++

[Qemu-devel] [PATCH 03/10] Add printf debug to savevm

2010-11-23 Thread Juan Quintela
From: Juan Quintela Once there, print all sections that take more than 100ms to migrate. buffered file runs a timer at that 100ms interval. Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- savevm.c | 48 ++-- 1 files changed, 46 inser

[Qemu-devel] [PATCH 10/10] Maintaing number of dirty pages

2010-11-23 Thread Juan Quintela
From: Juan Quintela Calculate the number of dirty pages takes a lot on hosts with lots of memory. Just maintain how many pages are dirty. Only sync bitmaps if number is small enough. Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- arch_init.c | 15 +-- cpu-all.h

[Qemu-devel] [PATCH 05/10] KVM don't care about TLB handling

2010-11-23 Thread Juan Quintela
From: Juan Quintela TLB handling is only used in TCG mode. It is very costly for guests with lots of memory ad lots of CPU's. Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- exec.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/exec.c b/exec.c index

[Qemu-devel] [PATCH 06/10] Only calculate expected_time for stage 2

2010-11-23 Thread Juan Quintela
From: Juan Quintela Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- arch_init.c | 10 ++ 1 files changed, 6 insertions(+), 4 deletions(-) diff --git a/arch_init.c b/arch_init.c index 4486925..df3d91f 100644 --- a/arch_init.c +++ b/arch_init.c @@ -217,7 +217,6 @@ int ra

[Qemu-devel] [PATCH 08/10] Count nanoseconds with uint64_t not doubles

2010-11-23 Thread Juan Quintela
From: Juan Quintela Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- arch_init.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/arch_init.c b/arch_init.c index 9e941a0..d32aaae 100644 --- a/arch_init.c +++ b/arch_init.c @@ -216,6 +216,7 @@ int ram_s

[Qemu-devel] [PATCH 07/10] ram_save_remaining() returns an uint64_t

2010-11-23 Thread Juan Quintela
From: Juan Quintela It returns a counter of things, not a ram address. Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- arch_init.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/arch_init.c b/arch_init.c index df3d91f..9e941a0 100644 --- a/arch_init.

[Qemu-devel] [PATCH 01/10] Add spent time to migration

2010-11-23 Thread Juan Quintela
From: Juan Quintela When printing debug information for migration, print total time spent. Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- migration.c | 13 + 1 files changed, 13 insertions(+), 0 deletions(-) diff --git a/migration.c b/migration.c index 9ee8b17..4

[Qemu-devel] [PATCH 04/10] No need to iterate if we already are over the limit

2010-11-23 Thread Juan Quintela
From: Juan Quintela If buffers are full, don't iterate Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- savevm.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/savevm.c b/savevm.c index ceed6de..7c289af 100644 --- a/savevm.c +++ b/savevm.c @@ -1498,6 +

[Qemu-devel] [PATCH 02/10] Add buffered_file_internal constant

2010-11-23 Thread Juan Quintela
From: Juan Quintela This time is each time that buffered_file ticks happen Signed-off-by: Juan Quintela Signed-off-by: Juan Quintela --- buffered_file.c |6 -- buffered_file.h |2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/buffered_file.c b/buffered_file.c i

[Qemu-devel] [PATCH 00/10] Fix migration with lots of memory

2010-11-23 Thread Juan Quintela
Hi Executive Summary - This series of patches fix migration with lots of memory. With them stalls are removed, and we honored max_dowtime. I also add infrastructure to measure what is happening during migration (#define DEBUG_MIGRATION and DEBUG_SAVEVM). Migration is broken at t

Re: [Qemu-devel] [PATCH] qemu-kvm: response to SIGUSR1 to start/stop a VCPU (v2)

2010-11-23 Thread Anthony Liguori
On 11/23/2010 01:35 PM, Blue Swirl wrote: On Tue, Nov 23, 2010 at 4:49 PM, Anthony Liguori wrote: qemu-kvm vcpu threads don't response to SIGSTOP/SIGCONT. Instead of teaching them to respond to these signals (which cannot be trapped), use SIGUSR1 to approximate the behavior of SIGSTOP/SIGC

[Qemu-devel] [Patch] Small fix for qemu APIC for Mac OS X support

2010-11-23 Thread adq
This patch ups the APIC version from 0x11 to 0x14. After that Mac OS X loads successfully (with appropriate kexts, applesmc ain't hooked up properly yet I see unfortunately). According to to the Intel IA-32 Software Developers Manual Vol 3 page 290, the version should be 0x14 Pentium 4/Xeon CPUs a

[Qemu-devel] [PATCH V7 15/15] acpi-piix4: Add Xen hypercall for sleep state.

2010-11-23 Thread anthony . perard
From: Anthony PERARD Signed-off-by: Anthony PERARD --- hw/acpi_piix4.c |4 hw/xen.h|2 ++ xen-all.c |7 +++ xen-stub.c |4 4 files changed, 17 insertions(+), 0 deletions(-) diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c index 173d781..1bcd40e 10

[Qemu-devel] [PATCH V7 14/15] xen: Set running state in xenstore.

2010-11-23 Thread anthony . perard
From: Anthony PERARD This tells to the xen management tool that the machine can begin run. Signed-off-by: Anthony PERARD --- xen-all.c | 27 +++ 1 files changed, 27 insertions(+), 0 deletions(-) diff --git a/xen-all.c b/xen-all.c index 36bdf30..b94d56e 100644 --- a/x

[Qemu-devel] isp1760 (nxp usb controller) support in QEMU for linux arm realview boards?

2010-11-23 Thread t g
I see in the 2.6.33.7 linux kernel that the realview-pbx board configuration has support for the NXP isp1760 usb controller. I'm trying to find out if QEMU has support for this type of controller. I'd appreciate any pointers in the right direction. I haven't found anything so far so I tho

[Qemu-devel] [PATCH V7 09/15] xen: Introduce the Xen mapcache

2010-11-23 Thread anthony . perard
From: Jun Nakajima On IA32 host or IA32 PAE host, at present, generally, we can't create an HVM guest with more than 2G memory, because generally it's almost impossible for Qemu to find a large enough and consecutive virtual address space to map an HVM guest's whole physical address space. The at

[Qemu-devel] Re: [PATCH] megasas: LSI Megaraid SAS emulation

2010-11-23 Thread Stefan Hajnoczi
On Mon, Nov 22, 2010 at 10:15 AM, Hannes Reinecke wrote: Not a full review but two small things I noticed: > +#define megasas_frame_set_cmd_status(f,v)              \ > +    stb_phys((f) + offsetof(struct mfi_frame_header, cmd_status), v); > + > +#define megasas_frame_set_scsi_status(f,v)        

[Qemu-devel] [PATCH V7 07/15] piix_pci: Introduces Xen specific call for irq.

2010-11-23 Thread anthony . perard
From: Anthony PERARD This patch introduces Xen specific call in piix_pci. The specific part for Xen is in write_config, set_irq and get_pirq. Signed-off-by: Anthony PERARD Signed-off-by: Stefano Stabellini --- hw/piix_pci.c | 28 ++-- hw/xen.h |6 ++ xe

[Qemu-devel] Re: [PATCH] virtio: fix up VQ checks

2010-11-23 Thread Juan Quintela
"Michael S. Tsirkin" wrote: > When migration triggers before a VQ is initialized, > base pa is 0 and last_used_index must be 0 too: > we don't have a ring to compare to. > > This fixes a bug introduced in > 258dc7c96bb4b7ca71d5bee811e73933310e168c. > > Reporrted-by: Juan Quintela extra 'r' > Si

[Qemu-devel] [PATCH V7 03/15] xen: Support new libxc calls from xen unstable.

2010-11-23 Thread anthony . perard
From: Anthony PERARD Update the libxenctrl calls in Qemu to use the new interface, otherwise Qemu wouldn't be able to build against new versions of the library. We also check libxenctrl version in configure, from Xen 3.3.0 to Xen unstable. Signed-off-by: Anthony PERARD Signed-off-by: Stefano S

[Qemu-devel] [PATCH V7 04/15] xen: Add xen_machine_fv

2010-11-23 Thread anthony . perard
From: Anthony PERARD Add the Xen FV (Fully Virtualized) machine to Qemu; this is groundwork to add Xen device model support in Qemu. Signed-off-by: Anthony PERARD Signed-off-by: Stefano Stabellini --- Makefile.target |3 + hw/xen_common.h |5 ++ hw/xen_machine_fv.c | 158

[Qemu-devel] [PATCH] virtio: fix up VQ checks

2010-11-23 Thread Michael S. Tsirkin
When migration triggers before a VQ is initialized, base pa is 0 and last_used_index must be 0 too: we don't have a ring to compare to. This fixes a bug introduced in 258dc7c96bb4b7ca71d5bee811e73933310e168c. Reporrted-by: Juan Quintela Signed-off-by: Michael S. Tsirkin --- Compile-tested only

[Qemu-devel] [PATCH V7 13/15] xen: Initialize event channels and io rings

2010-11-23 Thread anthony . perard
From: Arun Sharma Open and bind event channels; map ioreq and buffered ioreq rings. Signed-off-by: Arun Sharma Signed-off-by: Anthony PERARD Signed-off-by: Stefano Stabellini --- hw/xen_common.h |3 + xen-all.c | 407 +++ 2 files

[Qemu-devel] [PATCH V7 12/15] vl.c: Introduce getter for shutdown_requested and reset_requested.

2010-11-23 Thread anthony . perard
From: Anthony PERARD Introduce two functions qemu_shutdown_requested_get and qemu_reset_requested_get to get the value of shutdown/reset_requested without reset it. Signed-off-by: Anthony PERARD Signed-off-by: Stefano Stabellini --- sysemu.h |2 ++ vl.c | 10 ++ 2 files chan

[Qemu-devel] [PATCH V7 11/15] Introduce qemu_ram_ptr_unlock.

2010-11-23 Thread anthony . perard
From: Anthony PERARD This function allows to unlock a ram_ptr give by qemu_get_ram_ptr. After a call to qemu_ram_ptr_unlock, the pointer may be unmap from QEMU when used with Xen. Signed-off-by: Anthony PERARD --- cpu-common.h |1 + exec.c | 10 ++ xen-mapcache.c | 34

[Qemu-devel] Re: [PATCHv6 00/16] boot order specification

2010-11-23 Thread Blue Swirl
On Tue, Nov 23, 2010 at 4:12 PM, Anthony Liguori wrote: > On 11/23/2010 09:31 AM, Gleb Natapov wrote: >> >> Anthony, Blue >> >> No comments on this patch series for almost a week. Can it be applied? >> > > Does that mean everyone's happy or have folks not gotten around to review > it? > > IOW, las

[Qemu-devel] [PATCH V7 08/15] xen: add a 8259 Interrupt Controller

2010-11-23 Thread anthony . perard
From: Anthony PERARD Introduce a 8259 Interrupt Controller for target-xen; every set_irq call makes a Xen hypercall. Signed-off-by: Anthony PERARD Signed-off-by: Stefano Stabellini --- hw/xen_common.h |2 ++ hw/xen_machine_fv.c |5 ++--- xen-all.c | 12 3

[Qemu-devel] [PATCH V7 05/15] xen: Add initialisation of Xen

2010-11-23 Thread anthony . perard
From: Anthony PERARD Signed-off-by: Anthony PERARD --- Makefile.target |5 + hw/xen.h| 13 + vl.c|2 ++ xen-all.c | 29 + xen-stub.c | 17 + 5 files changed, 66 insertions(+), 0 deletions(-)

[Qemu-devel] [PATCH V7 10/15] configure: Always use 64bits target physical addresses with xen enabled.

2010-11-23 Thread anthony . perard
From: Anthony PERARD With MapCache, we can handle a 64b target, even with a 32b host/qemu. So, we need to have target_phys_addr_t to 64bits. Signed-off-by: Anthony PERARD --- configure |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/configure b/configure index 762505

Re: [Qemu-devel] [PATCH 10/12] config: Add header file for device config options

2010-11-23 Thread Blue Swirl
On Tue, Nov 23, 2010 at 2:34 PM, Alexander Graf wrote: > So far we have C preprocessor defines for target and host config > options, but we're lacking any information on which devices are > available. > > We do need that information at times though, for example in the > ahci patch where we need to

[Qemu-devel] [PATCH V7 02/15] xen: Add a generic layer for xc calls

2010-11-23 Thread anthony . perard
From: Alexander Graf This patch adds a generic layer for xc calls, allowing us to choose between the xenner and xen implementations at runtime. Signed-off-by: Alexander Graf Signed-off-by: Anthony PERARD --- hw/xen_interfaces.c | 100 + hw/xen_

[Qemu-devel] [PATCH V7 01/15] xen: Replace some tab-indents with spaces (clean-up).

2010-11-23 Thread anthony . perard
From: Anthony PERARD Signed-off-by: Anthony PERARD --- hw/xen_backend.c | 308 hw/xen_disk.c| 412 +++--- hw/xen_nic.c | 222 +++--- 3 files changed, 471 insertions(+), 47

[Qemu-devel] [PATCH V7 06/15] xen: Add the Xen platform pci device

2010-11-23 Thread anthony . perard
From: Steven Smith Introduce a new emulated PCI device, specific to fully virtualized Xen guests. The device is necessary for PV on HVM drivers to work. Signed-off-by: Steven Smith Signed-off-by: Anthony PERARD Signed-off-by: Stefano Stabellini --- Makefile.target |1 + hw/hw.h

[Qemu-devel] [PATCH V7 00/15] Xen device model support

2010-11-23 Thread anthony . perard
From: Anthony PERARD Hi all, Here is the V7 of the patch series that adds Xen device model support in QEMU. The change made on it since the v6: - I introduce a patch from Alexander Graf to add a generic layer for the Xen calls. - So compatibility support have been transformed from macros t

Re: [Qemu-devel] [PATCH] qemu-kvm: response to SIGUSR1 to start/stop a VCPU (v2)

2010-11-23 Thread Blue Swirl
On Tue, Nov 23, 2010 at 4:49 PM, Anthony Liguori wrote: > qemu-kvm vcpu threads don't response to SIGSTOP/SIGCONT.  Instead of teaching > them to respond to these signals (which cannot be trapped), use SIGUSR1 to > approximate the behavior of SIGSTOP/SIGCONT. > > The purpose of this is to implemen

Re: [Qemu-devel] [PATCH 10/12] config: Add header file for device config options

2010-11-23 Thread Alexander Graf
On 23.11.2010, at 20:21, Blue Swirl wrote: > On Tue, Nov 23, 2010 at 2:34 PM, Alexander Graf wrote: >> So far we have C preprocessor defines for target and host config >> options, but we're lacking any information on which devices are >> available. >> >> We do need that information at times tho

Re: [Qemu-devel] [PATCH 08/11] ahci: add ahci emulation

2010-11-23 Thread Blue Swirl
On Tue, Nov 23, 2010 at 1:48 PM, Alexander Graf wrote: > > On 21.11.2010, at 13:54, Blue Swirl wrote: > >> On Fri, Nov 19, 2010 at 2:56 AM, Alexander Graf wrote: >>> >>> +typedef struct AHCIControlRegs { >>> +    uint32_t    cap; >>> +    uint32_t    ghc; >>> +    uint32_t    irqstatus; >>> +    

Re: [Qemu-devel] [Bug 427612] Re: kvm sends caps lock key up event twice

2010-11-23 Thread Stefan Weil
Am 23.11.2010 01:42, schrieb Benjamin Drung: Attached the patch for qemu-kvm 0.13. This patch is tested on natty with qemu-kvm 0.13.0+noroms-0ubuntu7 and the German and NEO2 keyboard layout. ** Patch added: "caps-lock-key-up-event.patch" https://bugs.launchpad.net/ubuntu/+source/qemu-kvm/+bug/42

[Qemu-devel] [PATCH 07/12] ARM: Return correct result for float-to-integer conversion of NaN

2010-11-23 Thread Peter Maydell
The ARM architecture mandates that converting a NaN value to integer gives zero (if Invalid Operation FP exceptions are not being trapped). This isn't the behaviour of the SoftFloat library, so NaNs must be special-cased. Signed-off-by: Peter Maydell --- target-arm/helper.c | 44 ++

[Qemu-devel] [PATCH 06/12] ARM: Fix sense of to_integer bit in Neon VCVT float/int conversion

2010-11-23 Thread Peter Maydell
Signed-off-by: Peter Maydell --- target-arm/translate.c |8 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/target-arm/translate.c b/target-arm/translate.c index 6c19f97..f018653 100644 --- a/target-arm/translate.c +++ b/target-arm/translate.c @@ -5664,16 +5664,16 @@ s

[Qemu-devel] [PATCH 01/12] target-arm: Add support for PKHxx in thumb2

2010-11-23 Thread Peter Maydell
From: Johan Bengtsson The PKHxx instructions were not recognized by the thumb2 decoder. The solution provided in this changeset is identical to the arm-mode implementation. Signed-off-by: Johan Bengtsson Signed-off-by: Peter Maydell --- target-arm/translate.c | 63 ++

[Qemu-devel] [PATCH 08/12] ARM: Return correct result for single<->double conversion of NaN

2010-11-23 Thread Peter Maydell
The ARM ARM defines that if the input to a single<->double conversion is a NaN then the output is always forced to be a quiet NaN by setting the most significant bit of the fraction part. Signed-off-by: Peter Maydell --- target-arm/helper.c | 18 -- 1 files changed, 16 insertio

[Qemu-devel] [PATCH 02/12] target-arm: Fix mixup in decoding of saturating add and sub

2010-11-23 Thread Peter Maydell
From: Johan Bengtsson The thumb2 decoder contained a mixup between the bit controlling doubling and the bit controlling if the operation was an add or a sub. Signed-off-by: Johan Bengtsson Signed-off-by: Peter Maydell --- target-arm/translate.c |4 ++-- 1 files changed, 2 insertions(+), 2

[Qemu-devel] [PATCH 03/12] target-arm: Handle 'smc' as an undefined instruction

2010-11-23 Thread Peter Maydell
From: Adam Lackorzynski Refine check on bkpt so that smc and undefined instruction encodings are handled as an undefined instruction and trap. Signed-off-by: Adam Lackorzynski Signed-off-by: Peter Maydell --- target-arm/translate.c |9 - 1 files changed, 8 insertions(+), 1 deletio

[Qemu-devel] [PATCH 09/12] ARM: Ignore top 16 bits when doing VCVT from 16 bit fixed point

2010-11-23 Thread Peter Maydell
VCVT of 16 bit fixed point to float should ignore the top 16 bits of the source register. Cast to int16_t and friends rather than int16 -- the former is guaranteed exactly 16 bits wide where the latter is merely at least 16 bits wide (and so is usually 32 bits). Signed-off-by: Peter Maydell ---

[Qemu-devel] [PATCH 10/12] softfloat: Add float/double to 16 bit integer conversion functions

2010-11-23 Thread Peter Maydell
The ARM architecture needs float/double to 16 bit integer conversions. (The 32 bit versions aren't sufficient because of the requirement to saturate at 16 bit MAXINT/MININT and to get the exception bits right.) Signed-off-by: Peter Maydell --- fpu/softfloat.c | 136 +

[Qemu-devel] [PATCH 11/12] ARM: Implement VCVT to 16 bit integer using new softfloat routines

2010-11-23 Thread Peter Maydell
Use the softfloat conversion routines for conversion to 16 bit integers, because just casting to a 16 bit type truncates the value rather than saturating it at 16-bit MAXINT/MININT. Signed-off-by: Peter Maydell --- target-arm/helper.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-)

[Qemu-devel] [PATCH 05/12] ARM: Fix decoding of Neon forms of VCVT between float and fixed point

2010-11-23 Thread Peter Maydell
Fix errors in the decoding of the Neon forms of fixed-point VCVT: * fixed-point VCVT is op 14 and 15, not 15 and 16 * the fbits immediate field was being misinterpreted * the sense of the to_fixed bit was inverted Signed-off-by: Peter Maydell --- target-arm/translate.c |8 ++-- 1 file

[Qemu-devel] [PATCH 12/12] ARM: fix ldrexd/strexd

2010-11-23 Thread Peter Maydell
Correct ldrexd and strexd code to always read and write the high word of the 64-bit value from addr+4. Also make ldrexd and strexd agree that for a 64 bit value the address in env->exclusive_addr is that of the low word. This fixes the issues reported in https://bugs.launchpad.net/qemu/+bug/670883

[Qemu-devel] [PATCH 00/12] [PULL] ARM fixes

2010-11-23 Thread Peter Maydell
Anthony, This is a pull request for patches which fix problems with the generated code for ARM targets. They've been sent to the list previously, and I've reviewed and tested them. Could they be merged, please? The following changes since commit 4e02d460dd4b60847a1e8b689cb676e3e1f3de95: Stefan

[Qemu-devel] [PATCH 04/12] ARM: Fix decoding of VFP forms of VCVT between float and int/fixed

2010-11-23 Thread Peter Maydell
Correct the decoding of source and destination registers for the VFP forms of the VCVT instructions which convert between floating point and integer or fixed-point. Signed-off-by: Peter Maydell --- target-arm/translate.c | 19 --- 1 files changed, 12 insertions(+), 7 deletions(

[Qemu-devel] [PATCH 3/3] QMP: Simplify monitor_json_emitter()

2010-11-23 Thread Luiz Capitulino
Use the ternary operator instead of an if (also fixes bad indentation). Signed-off-by: Luiz Capitulino --- monitor.c |6 ++ 1 files changed, 2 insertions(+), 4 deletions(-) diff --git a/monitor.c b/monitor.c index 30be273..f6f2264 100644 --- a/monitor.c +++ b/monitor.c @@ -351,10 +351,8

[Qemu-devel] [PATCH 2/3] QMP: Drop dead code

2010-11-23 Thread Luiz Capitulino
The first if/else clause in handler_audit() makes no sense for two reasons: 1. this function is now called only by QMP code, so testing if it's a QMP call makes no sense anymore 2. the else clause first asserts that there's no error in the monitor object, then it tries to free it!

[Qemu-devel] [PATCH 1/3] QMP: Fix default response regression

2010-11-23 Thread Luiz Capitulino
Commit 030db6e89d dropped do_info() usage from QMP and introduced qmp_call_query_cmd(). However, the new function doesn't emit QMP's default OK response when the handler doesn't return data. Fix that by also calling monitor_protocol_emitter() when ret_data == NULL, so that the default response is

[Qemu-devel] [PATCH 0/3] QMP: small fixes

2010-11-23 Thread Luiz Capitulino
Please, check individual patches for details.

[Qemu-devel] Re: [PATCH v2 0/6] qdev reset refactoring and pci bus reset

2010-11-23 Thread Michael S. Tsirkin
On Tue, Nov 23, 2010 at 12:53:12AM +0200, Michael S. Tsirkin wrote: > On Mon, Nov 22, 2010 at 07:43:37PM +0900, Isaku Yamahata wrote: > > On Mon, Nov 22, 2010 at 09:54:02AM +0200, Michael S. Tsirkin wrote: > > > On Fri, Nov 19, 2010 at 06:55:57PM +0900, Isaku Yamahata wrote: > > > > Here is v2. I u

[Qemu-devel] [PATCH] qemu-kvm: response to SIGUSR1 to start/stop a VCPU (v2)

2010-11-23 Thread Anthony Liguori
qemu-kvm vcpu threads don't response to SIGSTOP/SIGCONT. Instead of teaching them to respond to these signals (which cannot be trapped), use SIGUSR1 to approximate the behavior of SIGSTOP/SIGCONT. The purpose of this is to implement CPU hard limits using an external tool that watches the CPU cons

Re: [Qemu-devel] [PATCH, RFT] Speedup 'tb_find_slow' by using the same heuristic as during memory page lookup

2010-11-23 Thread Mulyadi Santosa
Dear Kirill On Tue, Nov 23, 2010 at 02:42, Kirill Batuzov wrote: > Move the last found TB to the head of the list so it will be found more > quickly next time it will be looked for. ... >  found: > +    if (*ptb1) { > +        *ptb1 = tb->phys_hash_next; > +        tb->phys_hash_next = tb_phys_ha

[Qemu-devel] Re: [PATCHv6 00/16] boot order specification

2010-11-23 Thread Anthony Liguori
On 11/23/2010 09:31 AM, Gleb Natapov wrote: Anthony, Blue No comments on this patch series for almost a week. Can it be applied? Does that mean everyone's happy or have folks not gotten around to review it? IOW, last call if you have objections :-) Regards, Anthony Liguori On Wed, N

[Qemu-devel] Re: [PATCH] scsi: Implement 'get_sense' callback

2010-11-23 Thread Hannes Reinecke
On 11/22/2010 10:56 PM, Stefan Hajnoczi wrote: > On Mon, Nov 22, 2010 at 10:15 AM, Hannes Reinecke wrote: >> +static int scsi_get_sense(SCSIRequest *req, uint8_t *outbuf, int len) >> +{ >> +SCSIGenericState *s = DO_UPCAST(SCSIGenericState, qdev, req->dev); >> +int size = SCSI_SENSE_BUF_SIZ

[Qemu-devel] KVM call minutes for Nov 23

2010-11-23 Thread Chris Wright
qcow2 performance roadmap - What can be done to achieve near-raw image format performance? - some discussion points from Kevin on list http://lists.nongnu.org/archive/html/qemu-devel/2010-11/msg02126.html - please follow up on the list - some perf numbers (latest upstream qcow2 compared wit

[Qemu-devel] [PATCH] Fix commandline handling for ARM semihosted executables, on Linux and BSD hosts

2010-11-23 Thread Schildbach, Wolfgang
When running an ARM semihosted executable on a linux machine, the command line is not delivered to the guest (see https://bugs.launchpad.net/qemu/+bug/673613). This patch fixes this, for Linux and BSD hosts. Thanks to Peter Maydell for suggesting this patch, and to Nathan Froyd for helping me with

[Qemu-devel] Re: [PATCHv6 00/16] boot order specification

2010-11-23 Thread Gleb Natapov
Anthony, Blue No comments on this patch series for almost a week. Can it be applied? On Wed, Nov 17, 2010 at 06:43:47PM +0200, Gleb Natapov wrote: > I am using open firmware naming scheme to specify device path names. > In this version: added SCSI bus support. Pass boot order list as file > to fi

[Qemu-devel] [Bug 427612] Re: kvm sends caps lock key up event twice

2010-11-23 Thread Serge Hallyn
Thanks, Benjamin. I've pushed your fix to a ppa in https://launchpad.net/~serge-hallyn/+archive/qemu-capslock for testing. I'd like someone with a standard keyboard with capslock not remapped to give this a spin, then I'll propose the fix for merge into the natty tree (after which it can be SRU'd

[Qemu-devel] usb-ccid notes for today's meeting

2010-11-23 Thread Alon Levy
Hi, I've compiled the list of objections from the previous round of talks between Anthony and {Robert and I}, with our answers, for reference in todays talk (sorry about late send). Notes for KVM meeting. Points raised by anthony: 1. How does the smart card state get migrated? 2. How do you

[Qemu-devel] [PATCH 03/12] ide: add support for ide bus ops

2010-11-23 Thread Alexander Graf
From: Roland Elek We need to hook into some of the core IDE functionality for AHCI. To do that, the easiest way is to make explicit functions calls be implicit through a function call struct. Signed-off-by: Roland Elek Signed-off-by: Alexander Graf --- v1 -> v2: - rename IDEExtender to ID

[Qemu-devel] [PATCH 12/12] ide: move pata specific parts to pata.c

2010-11-23 Thread Alexander Graf
Due to popular request, this patch moves pieces that are successfully identified as PATA only to a new file called pata.c. Signed-off-by: Alexander Graf --- Makefile.objs |2 +- hw/ide/core.c | 144 +-- hw/ide/internal.h |3 + hw/ide/pata.

[Qemu-devel] [PATCH 11/12] ahci: spawn controller on demand

2010-11-23 Thread Alexander Graf
When we add a device using -drive to the guest, we also need to create a new SATA bus to handle the device. This patch adds a function call that every machine that likes to have IF_SATA support can call to get full device creation by keeping the actual qdev code clean. Signed-off-by: Alexander Gra

Re: [Qemu-devel] [PATCH 7/7] tcg-ia64: Fix warning in qemu_ld.

2010-11-23 Thread Richard Henderson
On 11/23/2010 01:09 AM, malc wrote: > On Mon, 22 Nov 2010, Richard Henderson wrote: > >> The usermode version of qemu_ld doesn't used mem_index, > > "doesn't used"? Doesn't use perhaps? Err, yes, of course. r~

[Qemu-devel] [PATCH 08/12] ahci: add ahci emulation

2010-11-23 Thread Alexander Graf
This patch adds an emulation layer for an ICH-7M AHCI controller. For now this controller does not do IDE legacy emulation. It is a pure AHCI controller. Signed-off-by: Alexander Graf --- v1 -> v2: - rename IDEExtender to IDEBusOps and make a pointer (kraxel) - make dma hooks explicit by p

[Qemu-devel] [PATCH 01/12] ide: split ide command interpretation off

2010-11-23 Thread Alexander Graf
The ATA command interpretation code can be used for PATA and SATA interfaces alike. So let's split it out into a separate function. Signed-off-by: Alexander Graf --- hw/ide/core.c | 20 ++-- hw/ide/internal.h |2 ++ 2 files changed, 16 insertions(+), 6 deletions(-) dif

[Qemu-devel] [PATCH 00/12] AHCI emulation support v4

2010-11-23 Thread Alexander Graf
This patch adds support for AHCI emulation. I have tested and verified it works in Linux, OpenBSD, Windows Vista and Windows 7. This AHCI emulation supports NCQ, so multiple read or write requests can be outstanding at the same time. The code is however not fully optimized yet. I'm fairly sure tha

[Qemu-devel] Re: KVM call agenda for Nov 23

2010-11-23 Thread Stefan Hajnoczi
On Tue, Nov 23, 2010 at 2:37 PM, Kevin Wolf wrote: > Am 22.11.2010 14:55, schrieb Stefan Hajnoczi: >> On Mon, Nov 22, 2010 at 1:38 PM, Juan Quintela wrote: >>> >>> Please send in any agenda items you are interested in covering. >> >> QCOW2 performance roadmap: >> * What can be done to achieve nea

[Qemu-devel] Re: [Bug 427612] Re: kvm sends caps lock key up event twice

2010-11-23 Thread Serge Hallyn
Quoting Benjamin Drung (benjamin.dr...@gmail.com): > Attached the patch for qemu-kvm 0.13. This patch is tested on natty with > qemu-kvm 0.13.0+noroms-0ubuntu7 and the German and NEO2 keyboard layout. Thanks, Benjamin. I will propose this patch for merge as soon as some technical difficulties wit

[Qemu-devel] [PATCH 09/12] ahci: add -drive support

2010-11-23 Thread Alexander Graf
We need to be able to spawn new AHCI drives, so let's add AHCI support to the -drive option. Signed-off-by: Alexander Graf --- blockdev.c|6 +- blockdev.h|1 + qemu-common.h |2 +- 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/blockdev.c b/blockdev.c inde

[Qemu-devel] Re: KVM call agenda for Nov 23

2010-11-23 Thread Kevin Wolf
Am 22.11.2010 14:55, schrieb Stefan Hajnoczi: > On Mon, Nov 22, 2010 at 1:38 PM, Juan Quintela wrote: >> >> Please send in any agenda items you are interested in covering. > > QCOW2 performance roadmap: > * What can be done to achieve near-raw image format performance? > * Benchmark results from

[Qemu-devel] [PATCH 02/12] ide: fix whitespace gap in ide_exec_cmd

2010-11-23 Thread Alexander Graf
Now that we have the function split out, we have to reindent it. In order to increase the readability of the actual functional change, this is split out. Signed-off-by: Alexander Graf --- hw/ide/core.c | 734 1 files changed, 367 insertio

Re: [Qemu-devel] [PATCH] qemu-kvm: introduce cpu_start/cpu_stop commands

2010-11-23 Thread Avi Kivity
On 11/23/2010 04:24 PM, Anthony Liguori wrote: Using monitor commands is fairly heavyweight for something as high frequency as this. What control period do you see people using? Maybe we should define USR1 for vcpu start/stop. What happens if one vcpu is stopped while another is running?

[Qemu-devel] [PATCH 10/12] config: Add header file for device config options

2010-11-23 Thread Alexander Graf
So far we have C preprocessor defines for target and host config options, but we're lacking any information on which devices are available. We do need that information at times though, for example in the ahci patch where we need to call a legacy init function depending on whether we have support c

[Qemu-devel] [PATCH 04/12] ide: add DMA hooks to bus ops

2010-11-23 Thread Alexander Graf
For DMA operations, we need to hook into even more IDE functionality. This patch adds the respective hooking points, allowing us to handle SG lists ourselves in the AHCI code. Signed-off-by: Roland Elek Signed-off-by: Alexander Graf --- v1 -> v2: - make dma hooks explicit by putting them i

[Qemu-devel] [PATCH 07/12] pci: add ich7 pci id

2010-11-23 Thread Alexander Graf
We need a PCI ID for our new AHCI adapter. I just picked an ICH-7M because that's the one built into the first Macbooks. This patch adds a PCI ID define for an ICH-7M AHCI adapter. Signed-off-by: Alexander Graf --- v3 -> v4: - add ICH7 instead of ICH7M (herbszt) --- hw/pci.h |1 + 1 fi

[Qemu-devel] [PATCH 06/12] pci: add storage class for sata

2010-11-23 Thread Alexander Graf
This patch adds the storage sata class id. Signed-off-by: Alexander Graf --- hw/pci_ids.h |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/hw/pci_ids.h b/hw/pci_ids.h index 82cba7e..ea3418c 100644 --- a/hw/pci_ids.h +++ b/hw/pci_ids.h @@ -15,6 +15,7 @@ #define PCI_CLAS

[Qemu-devel] [PATCH 05/12] ide: add ncq identify data for ahci sata drives

2010-11-23 Thread Alexander Graf
From: Roland Elek I modified ide_identify() to include the zero-based queue length value in word 75, and set bit 8 in word 76 to signal NCQ support in the identify data for AHCI SATA drives. Signed-off-by: Roland Elek --- hw/ide/core.c |7 +++ hw/ide/internal.h |2 ++ 2 files c

Re: [Qemu-devel] [PATCH] qemu-kvm: introduce cpu_start/cpu_stop commands

2010-11-23 Thread Anthony Liguori
On 11/23/2010 08:00 AM, Avi Kivity wrote: If we could catch SIGSTOP, then it would be easy to unblock it only while running in guest context. It would then stop on exit to userspace. Yeah, that's not a bad idea. Except we can't. Yeah, I s:SIGSTOP:SIGUSR1:g. Using monitor commands is f

  1   2   >