Re: [Qemu-devel] linux-user: enabling binfmt P flag

2014-08-25 Thread Riku Voipio
On Mon, Aug 25, 2014 at 04:30:40PM +0200, Joakim Tjernlund wrote: Riku Voipio riku.voi...@iki.fi wrote on 2014/08/25 15:55:55: Hi, On Mon, Aug 25, 2014 at 03:39:19PM +0200, Joakim Tjernlund wrote: Then consider when you run a LXC without P flag. Please remember that your

Re: [Qemu-devel] linux-user: enabling binfmt P flag

2014-08-25 Thread Joakim Tjernlund
Riku Voipio riku.voi...@iki.fi wrote on 2014/08/25 16:49:17: On Mon, Aug 25, 2014 at 04:30:40PM +0200, Joakim Tjernlund wrote: Riku Voipio riku.voi...@iki.fi wrote on 2014/08/25 15:55:55: Hi, On Mon, Aug 25, 2014 at 03:39:19PM +0200, Joakim Tjernlund wrote: Then consider

Re: [Qemu-devel] [PATCH 1/2] util: introduce bitmap_try_new

2014-08-25 Thread Eric Blake
On 08/22/2014 03:26 AM, Peter Lieven wrote: regular bitmap_new simply aborts if the memory allocation fails. bitmap_try_new returns NULL on failure and allows for proper error handling. Signed-off-by: Peter Lieven p...@kamp.de --- include/qemu/bitmap.h |6 ++ 1 file changed, 6

Re: [Qemu-devel] is there a limit on the number of in-flight I/O operations?

2014-08-25 Thread Chris Friesen
On 08/23/2014 01:56 AM, Benoît Canet wrote: The Friday 22 Aug 2014 à 18:59:38 (-0600), Chris Friesen wrote : On 07/21/2014 10:10 AM, Benoît Canet wrote: The Monday 21 Jul 2014 à 09:35:29 (-0600), Chris Friesen wrote : On 07/21/2014 09:15 AM, Benoît Canet wrote: The Monday 21 Jul 2014 à

Re: [Qemu-devel] [PATCH RESEND 1/2] rng-egd: Free old chr_name value before setting new one

2014-08-25 Thread Amos Kong
On Thu, Aug 07, 2014 at 12:18:47PM +0200, Paolo Bonzini wrote: Il 07/08/2014 04:24, Amos Kong ha scritto: Eduardo, a similar patch had been applied. commit 5e490b6a504912225dff0e520e1c6af68295d238 Author: Amos Kong ak...@redhat.com Date: Thu Nov 21 16:42:50 2013 +0800

Re: [Qemu-devel] [PATCH] Revert virtio_rng: replace custom backend API with UserCreatable.complete() callback

2014-08-25 Thread Amos Kong
On Tue, Aug 19, 2014 at 03:47:20PM +0100, Stefan Hajnoczi wrote: On Sat, Aug 16, 2014 at 12:23:52AM +0800, Amos Kong wrote: This reverts commit 57d3e1b3f52d07d215ed96df946ee01f8d9f9526. The commit introduced a regression bug, the initialization order of virtio-rng backend was changed.

Re: [Qemu-devel] [libvirt] Mentors wanted for Outreach Program for Women October 2014

2014-08-25 Thread Stefan Hajnoczi
On Mon, Aug 25, 2014 at 11:52 AM, Martin Kletzander mklet...@redhat.com wrote: On Thu, Aug 21, 2014 at 09:06:39PM +0100, Stefan Hajnoczi wrote: Regular code contributors to QEMU, KVM, and libvirt are eligible to participate as mentors. We also need project ideas that are achievable in 12

Re: [Qemu-devel] [PATCH] target-i386: Don't forbid NX bit on PAE PDEs and PTEs

2014-08-25 Thread Paolo Bonzini
Il 24/08/2014 07:13, William Grant ha scritto: Commit e8f6d00c30ed88910d0d985f4b2bf41654172ceb (target-i386: raise page fault for reserved physical address bits) added a check that the NX bit is not set on PAE PDPEs, but it also added it to rsvd_mask for the rest of the function. This caused

Re: [Qemu-devel] [PATCH] exec: save exception_index field

2014-08-25 Thread Andreas Färber
Am 25.08.2014 13:09, schrieb Pavel Dovgaluk: From: Andreas Färber [mailto:afaer...@suse.de] Am 31.07.2014 07:41, schrieb Pavel Dovgaluk: This patch adds subsection with exception_index field to the VMState for correct saving the CPU state. Without this patch simulator could miss the pending

Re: [Qemu-devel] [PATCH v3 0/3] Sync MTRRs with KVM and disable on reset

2014-08-25 Thread Paolo Bonzini
Il 14/08/2014 23:39, Alex Williamson ha scritto: v3: - Fix off-by-one identified by Laszlo in 2/3 - Add R-b in 1 3 It turns out that not only do we not follow the SDM guidelines for reseting MTRR state on vCPU reset, but we really don't even attempt to keep KVM MTRR state synchronized

[Qemu-devel] [PATCH] checkpatch.pl: adjust typedef definition to QEMU coding style

2014-08-25 Thread Paolo Bonzini
Most QEMU typedefs are camelcase, starting with one uppercase letter and containing at least one lowercase letter. There are a few all-uppercase types, add the most common too. This fixes recognition of types in lines such as static __attribute__((unused)) inline void tcg_out8(TCGContext

Re: [Qemu-devel] [PATCH v3 07/10] qcow2: Rebuild refcount structure during check

2014-08-25 Thread Benoît Canet
On Fri, Aug 22, 2014 at 06:31:41PM +0200, Max Reitz wrote: The previous commit introduced the rebuild variable to qcow2's implementation of the image consistency check. Now make use of this by adding a function which creates a completely new refcount structure based solely on the in-memory

Re: [Qemu-devel] is there a limit on the number of in-flight I/O operations?

2014-08-25 Thread Chris Friesen
On 08/25/2014 09:12 AM, Chris Friesen wrote: I set up another test, checking the inflight value every second. Running just dd if=/dev/zero of=testfile2 bs=1M count=700 oflag=nocache gave a bit over 100 inflight requests. If I simultaneously run dd if=testfile of=/dev/null bs=1M count=700

Re: [Qemu-devel] [PULL 00/11] Trivial patches for 2014-08-24

2014-08-25 Thread Peter Maydell
On 24 August 2014 14:30, Michael Tokarev m...@tls.msk.ru wrote: This time, we've a bunch of trivial stuff all over, including a series from zhanghailiang, some minor fixes from Stefan Weil and Peter Crosthwaite, and also a bugfix for a rare device - vmxnet3 - reviewed by the author. Please

[Qemu-devel] [PATCH 0/2] apb: more PCI fixes

2014-08-25 Thread Mark Cave-Ayland
This patchset contains a couple of extra apb PCI fixes for bugs found whilst trying to boot *BSDs on SPARC64. With these patches qemu-system-sparc64 can now boot OpenBSD in -nographic mode. Signed-off-by: Mark Cave-Ayland mark.cave-ayl...@ilande.co.uk Mark Cave-Ayland (2): apb: add

[Qemu-devel] [PATCH 1/2] apb: add implementation of UltraSPARC IIi PCI TAS register

2014-08-25 Thread Mark Cave-Ayland
FreeBSD SPARC64 checks the value of this register on boot in order to calculate the DVMA base address. Signed-off-by: Mark Cave-Ayland mark.cave-ayl...@ilande.co.uk --- hw/pci-host/apb.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/hw/pci-host/apb.c b/hw/pci-host/apb.c

[Qemu-devel] [PATCH 2/2] apb: implement PCI bus error interrupt map registers

2014-08-25 Thread Mark Cave-Ayland
Both OpenBSD and FreeBSD SPARC64 attempt to read the interrupt map from the hardware and will fail if the correct ino isn't present. Signed-off-by: Mark Cave-Ayland mark.cave-ayl...@ilande.co.uk --- hw/pci-host/apb.c | 15 +-- 1 file changed, 13 insertions(+), 2 deletions(-) diff

Re: [Qemu-devel] Using cache=writeback safely on qemu 1.4.0 and later

2014-08-25 Thread Andrew Martin
- Original Message - From: Stefan Hajnoczi stefa...@gmail.com To: Andrew Martin amar...@xes-inc.com Cc: qemu-devel qemu-devel@nongnu.org Sent: Thursday, August 21, 2014 7:59:50 AM Subject: Re: [Qemu-devel] Using cache=writeback safely on qemu 1.4.0 and later When the disk is set to

Re: [Qemu-devel] [PULL 00/11] pci, pc fixes, features

2014-08-25 Thread Peter Maydell
On 24 August 2014 23:18, Michael S. Tsirkin m...@redhat.com wrote: The following changes since commit 2656eb7c599e306b95bad82b1372fc49ba3088f6: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20140819' into staging (2014-08-20 09:55:42 +0100) are available in the git

[Qemu-devel] [PATCH 0/6] target-ppc: More Cleanup of FXU Instructions

2014-08-25 Thread Tom Musta
This series follows up my previous series of bug fixes to Power fixed point instructions (http://lists.nongnu.org/archive/html/qemu-ppc/2014-08/msg00068.html). Richard Henderson provided additional feedback after the patches had been taken into Aleg Graf's ppc-next tree. Tom Musta (6):

[Qemu-devel] [PATCH 1/6] target-ppc: Special Case of rlwimi Should Use Deposit

2014-08-25 Thread Tom Musta
The special case of rlwimi where MB = ME and SH = 31-ME can be implemented with a single TCG deposit operation. This replaces the less general case of SH = MB = 0 and ME = 31. Signed-off-by: Tom Musta tommu...@gmail.com Suggested-by: Richard Henderson r...@twiddle.net --- target-ppc/translate.c

[Qemu-devel] [PATCH 2/6] target-ppc: Optimize rlwinm MB=0 ME=31

2014-08-25 Thread Tom Musta
Optimize the special case of rlwinm where MB=0 and ME=31. This can be implemented as a 32-bit ROTL. Signed-off-by: Tom Musta tommu...@gmail.com Suggested-by: Richard Henderson r...@twiddle.net --- target-ppc/translate.c |6 ++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git

[Qemu-devel] [PATCH 6/6] target-ppc: Implement mulldo with TCG

2014-08-25 Thread Tom Musta
Optimize mulldo by using the muls2_i64 operation rather than a helper. Eliminate the obsolete helper code. Signed-off-by: Tom Musta tommu...@gmail.com Suggested-by: Richard Henderson r...@twiddle.net --- target-ppc/helper.h |1 - target-ppc/int_helper.c | 27

[Qemu-devel] [PATCH 3/6] target-ppc: Optimize rlwnm MB=0 ME=31

2014-08-25 Thread Tom Musta
Optimize the special case of rlwnm where MB=0 and ME=31. This can be implemented using a ROTL. Suggested-by: Richard Henderson r...@twiddle.net Signed-off-by: Tom Musta tommu...@gmail.com --- target-ppc/translate.c | 56 +-- 1 files changed, 34

[Qemu-devel] [PATCH 5/6] target-ppc: Clean up mullwo

2014-08-25 Thread Tom Musta
Simplify the implementation of mullwo. For 64 bit CPUs, the result is the concatenation of the upper and lower parts of the muls2_i32 operation, which may be slightly better than deposit. For 32 bit CPUs, the lower part of the muls_i32 operation is moved into the target GPR. Signed-off-by: Tom

[Qemu-devel] [PATCH 4/6] target-ppc: Clean Up mullw

2014-08-25 Thread Tom Musta
Eliminate the unecessary ext32s TCG operation and make the multiplication operation explicitly 32 bit. Signed-off-by: Tom Musta tommu...@gmail.com Suggested-by: Richard Henderson r...@twiddle.net --- target-ppc/translate.c |5 ++--- 1 files changed, 2 insertions(+), 3 deletions(-) diff

[Qemu-devel] [PULL 0/1] VFIO pull request

2014-08-25 Thread Alex Williamson
The following changes since commit 3dd359c2d34c6abf385d58da863f337b39702585: Merge remote-tracking branch 'remotes/mjt/tags/trivial-patches-2014-08-24' into staging (2014-08-25 17:34:30 +0100) are available in the git repository at: git://github.com/awilliam/qemu-vfio.git

[Qemu-devel] [PULL 1/1] vfio: Enable NVIDIA 88000 region quirk regardless of VGA

2014-08-25 Thread Alex Williamson
If we make use of OVMF for the BIOS then we can use GPUs without VGA space access, but we still need this quirk. Disassociate it from the x-vga option and enable it on all NVIDIA VGA display class devices. Signed-off-by: Alex Williamson alex.william...@redhat.com --- hw/misc/vfio.c |8

Re: [Qemu-devel] [PATCH v2 4/4] ioh3420: Enable ARI forwarding

2014-08-25 Thread Michael S. Tsirkin
On Mon, Aug 25, 2014 at 11:13:01AM +0200, Knut Omang wrote: On Mon, 2014-08-25 at 06:09 +, Gonglei (Arei) wrote: From: Michael S. Tsirkin [mailto:m...@redhat.com] Subject: Re: [PATCH v2 4/4] ioh3420: Enable ARI forwarding On Sun, Aug 24, 2014 at 03:32:20PM +0200, Knut Omang

Re: [Qemu-devel] [PATCH v2 2/2] pci: add check for pcie root ports and downstream ports

2014-08-25 Thread Michael S. Tsirkin
On Thu, Aug 21, 2014 at 05:47:46PM +0800, arei.gong...@huawei.com wrote: From: Gonglei arei.gong...@huawei.com If ARI Forwarding is disabled, according to PCIe spec section 7.3.1, only slot 0 with the device attached to logic bus representing the link from downstream ports and root ports.

[Qemu-devel] [PATCH v2 0/2] target-i386: tsc_adjust and mpx feature names

2014-08-25 Thread Eduardo Habkost
Add feature names that are missing on the x86 CPU feature name tables. Both had migration support implemented many months ago. Changes v1 - v2: * Commit message changes only. Added reference to migration support commit IDs. Note that v1 was not sent as a series, but as separate individual

[Qemu-devel] [PATCH v2 1/2] target-i386: Add mpx CPU feature name

2014-08-25 Thread Eduardo Habkost
Migration support for MPX is already implemented (commit 79e9ebebbf2a00c46fcedb6dc7dd5e12bbd30216), so we can add it to the list of known feature names. Signed-off-by: Eduardo Habkost ehabk...@redhat.com --- target-i386/cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[Qemu-devel] [PATCH v2 2/2] target-i386: Add tsc_adjust CPU feature name

2014-08-25 Thread Eduardo Habkost
tsc_adjust migration support is already implemented (commit f28558d3d37ad3bc4e35e8ac93f7bf81a0d5622c), so we can add it to the list of known feature names. Signed-off-by: Eduardo Habkost ehabk...@redhat.com --- target-i386/cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

Re: [Qemu-devel] [PATCH 0/6] target-ppc: More Cleanup of FXU Instructions

2014-08-25 Thread Richard Henderson
On 08/25/2014 12:25 PM, Tom Musta wrote: This series follows up my previous series of bug fixes to Power fixed point instructions (http://lists.nongnu.org/archive/html/qemu-ppc/2014-08/msg00068.html). Richard Henderson provided additional feedback after the patches had been taken into Aleg

[Qemu-devel] [PATCH v2 4/6] target-i386: Remove unsupported bits from all CPU models

2014-08-25 Thread Eduardo Habkost
The following CPU features were never supported by neither TCG or KVM, so they are useless on the CPU model definitions, today: * CPUID_DTS (DS) * CPUID_HT * CPUID_TM * CPUID_PBE * CPUID_EXT_DTES64 * CPUID_EXT_DSCPL * CPUID_EXT_EST * CPUID_EXT_TM2 * CPUID_EXT_XTPR * CPUID_EXT_PDCM *

[Qemu-devel] [PATCH v2 1/6] pc: Create pc_compat_2_1() functions

2014-08-25 Thread Eduardo Habkost
We will need new compat code for the 2.1 machine-types. Signed-off-by: Eduardo Habkost ehabk...@redhat.com --- hw/i386/pc_piix.c | 13 - hw/i386/pc_q35.c | 13 - 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c index

[Qemu-devel] [PATCH v2 3/6] target-i386: Disable CPUID_ACPI by default on KVM mode

2014-08-25 Thread Eduardo Habkost
KVM never supported the CPUID_ACPI flag, so it doesn't make sense to have it enabled by default when KVM is enabled. The motivation here is exactly the same we had for the MONITOR flag (disabled by commit 136a7e9a85d7047461f8153f7d12c514a3d68f69). And like on the MONITOR flag case, we don't need

[Qemu-devel] [PATCH v2 5/6] target-i386: Don't enable nested VMX by default

2014-08-25 Thread Eduardo Habkost
TCG doesn't support VMX, and nested VMX is not enabled by default on the KVM kernel module. So, there's no reason to have VMX enabled by default on the core2duo and coreduo CPU models, today. Even the newer Intel CPU model definitions don't have it enabled. In this case, we need machine-type

[Qemu-devel] [PATCH v2 0/6] target-i386: Make most CPU models work with enforce out of the box

2014-08-25 Thread Eduardo Habkost
Changes v1 - v2: * Commit message and comment changes. * Update compat code to change pc-*-2.1, not pc-*-2.0. * Added patch to disable SVM by default in KVM mode. Most of the bits that make enforce breaks were introduced in 2010 by commit 8560efed6a72a816c0115f41ddb9d79f7ce63f28. The intention

[Qemu-devel] [PATCH v2 2/6] target-i386: Rename KVM auto-feature-enable compat function

2014-08-25 Thread Eduardo Habkost
The x86_cpu_compat_disable_kvm_features() name was a bit confusing, as it won't forcibly disable the feature for all CPU models (i.e. add it to kvm_default_unset_features), but it will instead turn off the KVM auto-enabling of the feature (i.e. remove it from kvm_default_features), meaning the

[Qemu-devel] [PATCH v2 6/6] target-i386: Disable SVM by default in KVM mode

2014-08-25 Thread Eduardo Habkost
Make SVM be disabled by default on all CPU models when in KVM mode. Nested SVM is enabled by default in the KVM kernel module, but it is probably less stable than nested VMX (which is already disabled by default). Add a new compat function, x86_cpu_compat_kvm_no_autodisable(), to keep

Re: [Qemu-devel] is there a limit on the number of in-flight I/O operations?

2014-08-25 Thread Chris Friesen
On 08/23/2014 01:56 AM, Benoît Canet wrote: The Friday 22 Aug 2014 à 18:59:38 (-0600), Chris Friesen wrote : On 07/21/2014 10:10 AM, Benoît Canet wrote: The Monday 21 Jul 2014 à 09:35:29 (-0600), Chris Friesen wrote : On 07/21/2014 09:15 AM, Benoît Canet wrote: The Monday 21 Jul 2014 à

[Qemu-devel] [Bug 1354167] Re: On VM restart: Could not open 'poppy.qcow2': Could not read snapshots: File too large

2014-08-25 Thread Todd
Just putting this up here for anyone unlucky enough to hit this. This isn't a fix but it may rescue your borked qcow2 image. Download and compile the 1.7.2 version of qemu but don't install it. For example create a directory called qemutemp, download qemu-1.7.2.tar.bz2, untar it and do

[Qemu-devel] bad error message in drive-mirror

2014-08-25 Thread Eric Blake
I just noticed today that passing granularity:1 to QMP drive-mirror results in this confusing error message: Invalid parameter 'drive-virtio-disk0' because the code mistakenly did error_set(errp, QERR_INVALID_PARAMETER, device); instead of the correct error_set(errp,

[Qemu-devel] [PATCH v1 0/6] PMA phase 2 - per CPU address spaces

2014-08-25 Thread Peter Crosthwaite
Hi All, This series sets up CPUs with configurable address spaces. This follows on from Edgars original work and moves towards removal of address_space_memory and support for arbitrary memory heirachies/layouts. Fuller context in RFC:

[Qemu-devel] [PATCH v1 1/6] memory: address_space_init: do nothing if no root region given

2014-08-25 Thread Peter Crosthwaite
Just ignore this case. This is needed for bus master device realize when the machine model doesn't connect an attachment. Then machine model may decide to not set a memory region for mastering yet the device will attempt to create itself an address space come realize time. Gracefully do nothing.

[Qemu-devel] [PATCH v1 2/6] memory: AddressSpace: Implement ref counting

2014-08-25 Thread Peter Crosthwaite
To allow for sharing of AddressSpaces between multiple masters. Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- include/exec/memory.h | 1 + memory.c | 5 + 2 files changed, 6 insertions(+) diff --git a/include/exec/memory.h b/include/exec/memory.h index

Re: [Qemu-devel] [RFC PATCH 0/2] Fix MSIx lost after PE reset

2014-08-25 Thread Gavin Shan
On Wed, Aug 20, 2014 at 07:52:06PM +1000, Gavin Shan wrote: The 2 patches fix MSIx lost after PE reset. Otherwise, the MSIx entries can't be restored successfully after PE reset and the EEH recovery fails on broadcom tg3 adapter (as tested) in guest. Note: The patchset EEH support for guest isn't

[Qemu-devel] [PATCH v1 4/6] qom: Move cpu.o to obj-y.

2014-08-25 Thread Peter Crosthwaite
It's not really a common object and this is needed to give it access to CONFIG_USER_ONLY definition. Move it to regular obj-y. Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- Makefile.target | 1 + qom/Makefile.objs | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-)

[Qemu-devel] [PATCH v1 6/6] cpu: Delay address space init until realize

2014-08-25 Thread Peter Crosthwaite
To allow it to be set by the user after init. Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- exec.c| 1 - qom/cpu.c | 5 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/exec.c b/exec.c index 5f9857c..15ae6b7 100644 --- a/exec.c +++ b/exec.c @@ -492,7

[Qemu-devel] [PATCH v1 5/6] qom/cpu: Add Memory Region Property

2014-08-25 Thread Peter Crosthwaite
Which is used to construct a per-CPU address space. The Address space will be created at realize time. Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- include/qom/cpu.h | 1 + qom/cpu.c | 11 +++ 2 files changed, 12 insertions(+) diff --git

Re: [Qemu-devel] [V2 PATCH 02/12] linux-user: Dereference Pointer Argument to ipc/semctl Sys Call

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:33PM -0500, Tom Musta wrote: When the ipc system call is used to wrap a semctl system call, the ptr argument to ipc needs to be dereferenced prior to passing it to the semctl handler. This is because the fourth argument to semctl is a union and not a pointer to a

Re: [Qemu-devel] [V2 PATCH 03/12] linux-user: Properly Handle semun Structure In Cross-Endian Situations

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:34PM -0500, Tom Musta wrote: The semun union used in the semctl system call contains both an int (val) and pointers. In cross-endian situations on 64 bit targets, the value passed to semctl is an 8 byte (abi_long) value and thus does not have the 4-byte val field

Re: [Qemu-devel] [V2 PATCH 05/12] linux-user: Conditionally Pass Attribute Pointer to mq_open()

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:36PM -0500, Tom Musta wrote: The mq_open system call takes an optional struct mq_attr pointer argument in the fourth position. This pointer is used when O_CREAT is specified in the flags (second) argument. It may be NULL, in which case the queue is created with

Re: [Qemu-devel] [V2 PATCH 04/12] linux-user: Make ipc syscall's third argument an abi_long

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:35PM -0500, Tom Musta wrote: For those target ABIs that use the ipc system call (e.g. POWER), the third argument is used in the shmat path as a pointer. It therefore must be declared as an abi_long (versus int) so that the address bits are not lost in truncation.

Re: [Qemu-devel] [V2 PATCH 12/12] linux-user: writev Partial Writes

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:43PM -0500, Tom Musta wrote: Although not technically not required by POSIX, the writev system call will typically write out its buffers individually. That is, if the first buffer is written successfully, but the second buffer pointer is invalid, then the first

Re: [Qemu-devel] [V2 PATCH 11/12] linux-user: Support target-to-host translation of mlockall argument

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:42PM -0500, Tom Musta wrote: The argument to the mlockall system call is not necessarily the same on all platforms and thus may require translation prior to passing to the host. For example, PowerPC 64 bit platforms define values for MCL_CURRENT (0x2000) and

Re: [Qemu-devel] [V2 PATCH 08/12] linux-user: Detect fault in sched_rr_get_interval

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:39PM -0500, Tom Musta wrote: Properly detect a fault when attempting to store into an invalid struct timespec pointer. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by: Peter Maydell peter.mayd...@linaro.org Reviewed-by: David Gibson

Re: [Qemu-devel] [V2 PATCH 06/12] linux-user: Detect Negative Message Sizes in msgsnd System Call

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:37PM -0500, Tom Musta wrote: The msgsnd system call takes an argument that describes the message size (msgsz) and is of type size_t. The system call should set errno to EINVAL in the event that a negative message size is passed. Signed-off-by: Tom Musta

Re: [Qemu-devel] [V2 PATCH 07/12] linux-user: Handle NULL sched_param argument to sched_*

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:38PM -0500, Tom Musta wrote: The sched_getparam, sched_setparam and sched_setscheduler system calls take a pointer argument to a sched_param structure. When this pointer is null, errno should be set to EINVAL. Signed-off-by: Tom Musta tommu...@gmail.com

Re: [Qemu-devel] [V2 PATCH 10/12] linux-user: clock_nanosleep errno Handling on PPC

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:41PM -0500, Tom Musta wrote: The clock_nanosleep syscall is unusual in that it returns positive numbers in error handling situations, versus returning -1 and setting errno, or returning a negative errno value. On POWER, the kernel will set the SO bit of CR0 to

Re: [Qemu-devel] [V2 PATCH 01/12] linux-user: PPC64 semid_ds Doesnt Include _unused1 and _unused2

2014-08-25 Thread David Gibson
On Tue, Aug 12, 2014 at 01:53:32PM -0500, Tom Musta wrote: The 64 bit PowerPC platforms eliminate the _unused1 and _unused2 elements of the semid_ds structure from sys/sem.h. So eliminate these from the target_semid_ds structure. Signed-off-by: Tom Musta tommu...@gmail.com Reviewed-by:

Re: [Qemu-devel] [PATCH 0/6] add dumpdts ability to convert dtb to dts

2014-08-25 Thread Li Liu
On 2014/8/25 20:22, Peter Maydell wrote: On 25 August 2014 05:00, john.liuli john.li...@huawei.com wrote: From: Li Liu john.li...@huawei.com This patchset let qemu can convert dtb file to dts for two demands: Some archtectures may generate the dtb file dynamically through qemu device tree

Re: [Qemu-devel] [PATCH 1/1] add loopback for virtio-net

2014-08-25 Thread ????
Thanks for your suggestions. What I mean by this, is that we can test whether virtio-net can send and receive packets normally with ethtool in Guest OS, just as we test e1000 with ethtool [-t]. As we know, ethtool is an effective tool for testing net device, so we can provide this support by

Re: [Qemu-devel] [PATCH v2 2/3] qdev: add cleanup logic in device_set_realized() to avoid resource leak

2014-08-25 Thread Peter Crosthwaite
On Thu, Aug 21, 2014 at 12:11 PM, arei.gong...@huawei.com wrote: From: Gonglei arei.gong...@huawei.com At present, this function doesn't have partial cleanup implemented, which will cause resource leak in some scenarios. Example: 1. Assuming that dc-realize(dev, local_err) execute

Re: [Qemu-devel] [PATCH 0/6] add dumpdts ability to convert dtb to dts

2014-08-25 Thread Peter Crosthwaite
On Tue, Aug 26, 2014 at 12:04 PM, Li Liu john.li...@huawei.com wrote: On 2014/8/25 20:22, Peter Maydell wrote: On 25 August 2014 05:00, john.liuli john.li...@huawei.com wrote: From: Li Liu john.li...@huawei.com This patchset let qemu can convert dtb file to dts for two demands: Some

Re: [Qemu-devel] [PATCH] device_tree.c: redirect load_device_tree err message to stderr

2014-08-25 Thread Peter Crosthwaite
On Mon, Aug 25, 2014 at 6:44 PM, john.liuli john.li...@huawei.com wrote: From: Li Liu john.li...@huawei.com Signed-off-by: Li Liu john.li...@huawei.com --- device_tree.c |8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/device_tree.c b/device_tree.c index

Re: [Qemu-devel] [Xen-devel] [PATCH 2/2] xen:i386:pc_piix: create isa bridge specific to IGD passthrough

2014-08-25 Thread Chen, Tiejun
On 2014/8/25 13:18, Chen, Tiejun wrote: On 2014/8/24 19:12, Michael S. Tsirkin wrote: On Fri, Aug 22, 2014 at 09:06:20AM +0800, Chen, Tiejun wrote: On 2014/8/22 0:16, Konrad Rzeszutek Wilk wrote: On Thu, Aug 21, 2014 at 09:28:28AM +0800, Tiejun Chen wrote: Currenjly this ISA bridge should be

Re: [Qemu-devel] [PATCH] spapr-vlan: Don't touch last entry in buffer list

2014-08-25 Thread David Gibson
On Fri, Aug 22, 2014 at 11:50:57AM +1000, Anton Blanchard wrote: The last 8 bytes of the buffer list is defined to contain the number of dropped frames. At the moment we use it to store rx entries, which trips up ethtool -S: rx_no_buffer: 9223380832981355136 Fix this by skipping the last

Re: [Qemu-devel] [PATCH V5] spapr: Fix stale HTAB during live migration

2014-08-25 Thread David Gibson
On Fri, Aug 22, 2014 at 10:24:10AM +1000, Samuel Mendoza-Jonas wrote: If a guest reboots during a running migration, changes to the hash page table are not necessarily updated on the destination. Opening a new file descriptor to the HTAB forces the migration handler to resend the entire table.

[Qemu-devel] [PATCH memory v2 0/3] Memory Region Naming - take 2

2014-08-25 Thread Peter Crosthwaite
Hi, Here is an attempt at a proper fix to the memory region naming bugs as reported by Peter. The Xen compile bug and the memory leak. Regards, Peter Changed since v1: Constify xen physmap name string (Stefan W review). Change memory_region_name to caching based approach. Peter Crosthwaite

[Qemu-devel] [PATCH memory v2 1/3] xen-hvm: Constify string

2014-08-25 Thread Peter Crosthwaite
It's constant, and sourced from existing const strings. Avoid dodgy casts by converting to const. Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- xen-hvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xen-hvm.c b/xen-hvm.c index 91de2e2..d763e86

[Qemu-devel] [PATCH memory v2 2/3] xen: hvm: Abstract away memory region name ref

2014-08-25 Thread Peter Crosthwaite
The mr-name field is removed. This slipped through compile testing. Fix. Reviewed-by: Stefan Weil s...@weilnetz.de Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- changed since v1: Removed dodgy (char *) cast xen-hvm.c | 9 ++--- 1 file changed, 6 insertions(+), 3

[Qemu-devel] [PATCH memory v2 3/3] memory: Lazy init name from QOM name as needed

2014-08-25 Thread Peter Crosthwaite
To support name retrieval of MemoryRegions that were created dynamically (that is, not via memory_region_init and friends). We cache the name in MemoryRegion's state as object_get_canonical_path_component mallocs the returned value so it's not suitable for direct return to callers. Memory already

Re: [Qemu-devel] [PATCH V5] spapr: Fix stale HTAB during live migration

2014-08-25 Thread Sam Mendoza-Jonas
On 26/08/14 13:01, David Gibson wrote: On Fri, Aug 22, 2014 at 10:24:10AM +1000, Samuel Mendoza-Jonas wrote: If a guest reboots during a running migration, changes to the hash page table are not necessarily updated on the destination. Opening a new file descriptor to the HTAB forces the

[Qemu-devel] [PATCH target-arm v4 0/7] target-arm: Extend PMCCNTR for ARMv8

2014-08-25 Thread Peter Crosthwaite
This patch series continues on from Alistairs original PMCCNTR patch work. The counter is extended to 64-bit. V4: - Drop all EL awareness. V3: -Tidy up the arm_ccnt_enabled() -Fixed an old commit message refering to the CCNT_ENABLED macro -Do EL change sync in pstate_write instead of in

[Qemu-devel] [PATCH target-arm v4 2/7] arm: Implement PMCCNTR 32b read-modify-write

2014-08-25 Thread Peter Crosthwaite
The register is now 64bit, however a 32 bit write to the register should leave the higher bits unchanged. The open coded write handler does not implement this, so we need to read-modify-write accordingly. Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- target-arm/helper.c | 11

[Qemu-devel] [PATCH target-arm v4 1/7] target-arm: Make the ARM PMCCNTR register 64-bit

2014-08-25 Thread Peter Crosthwaite
From: Alistair Francis alistair.fran...@xilinx.com This makes the PMCCNTR register 64-bit to allow for the 64-bit ARMv8 version. Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com Signed-off-by: Alistair Francis alistair.fran...@xilinx.com --- changed since v2: Fixed indentation of

[Qemu-devel] [PATCH target-arm v4 3/7] target-arm: Implement PMCCNTR_EL0 and related registers

2014-08-25 Thread Peter Crosthwaite
From: Alistair Francis alistair.fran...@xilinx.com This patch adds support for the ARMv8 version of the PMCCNTR and related registers. It also starts to implement the PMCCFILTR_EL0 register. Signed-off-by: Alistair Francis alistair.fran...@xilinx.com Signed-off-by: Peter Crosthwaite

[Qemu-devel] [PATCH target-arm v4 4/7] target-arm: Add arm_ccnt_enabled function

2014-08-25 Thread Peter Crosthwaite
From: Alistair Francis alistair.fran...@xilinx.com Include a helper function to determine if the CCNT counter is enabled. Signed-off-by: Alistair Francis alistair.fran...@xilinx.com [ PC changes * Remove EL based checks ] Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com ---

[Qemu-devel] [PATCH target-arm v4 5/7] target-arm: Implement pmccntr_sync function

2014-08-25 Thread Peter Crosthwaite
From: Alistair Francis alistair.fran...@xilinx.com This is used to synchronise the PMCCNTR counter and swap its state between enabled and disabled if required. It must always be called twice, both before and after any logic that could change the state of the PMCCNTR counter. Signed-off-by:

[Qemu-devel] [PATCH target-arm v4 6/7] target-arm: Remove old code and replace with new functions

2014-08-25 Thread Peter Crosthwaite
From: Alistair Francis alistair.fran...@xilinx.com Remove the old PMCCNTR code and replace it with calls to the new pmccntr_sync() and arm_ccnt_enabled() functions. Signed-off-by: Alistair Francis alistair.fran...@xilinx.com Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com ---

[Qemu-devel] [PATCH target-arm v4 7/7] target-arm: Implement pmccfiltr_write function

2014-08-25 Thread Peter Crosthwaite
From: Alistair Francis alistair.fran...@xilinx.com This is the function that is called when writing to the PMCCFILTR_EL0 register Signed-off-by: Alistair Francis alistair.fran...@xilinx.com Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- target-arm/helper.c | 9 + 1

[Qemu-devel] [PATCH 1/3] target-ppc: Disable PReP testcases with !CONFIG_PREP

2014-08-25 Thread David Gibson
The test suites contain several tests which require the prep machine type, which will fail if that is configured out. Signed-off-by: David Gibson da...@gibson.dropbear.id.au --- tests/boot-order-test.c | 4 tests/endianness-test.c | 2 ++ 2 files changed, 6 insertions(+) diff --git

[Qemu-devel] [0/3] target-ppc Fixes for some missing config dependencies

2014-08-25 Thread David Gibson
These 3 patches fix some places where things ought to depend on an existing config variable, but don't.

[Qemu-devel] [PATCH 2/3] target-ppc: Disable ppc Mac tests when !CONFIG_MAC

2014-08-25 Thread David Gibson
The testsuites contain several tests which require the mac99 and g3beige machine types, which will fail when CONFIG_MAC is not specified. Signed-off-by: David Gibson da...@gibson.dropbear.id.au --- tests/boot-order-test.c | 6 ++ tests/endianness-test.c | 4 2 files changed, 10

[Qemu-devel] [PATCH 3/3] target-ppc: virtex-ml507 machine type should depend on CONFIG_XILINX

2014-08-25 Thread David Gibson
The virtex-ml507 is a Xilinx CPU based system, and requires several sub devices which are only included with CONFIG_XILINX. Therefore, it should only be compiled if CONFIG_XILINX is set. Signed-off-by: David Gibson da...@gibson.dropbear.id.au --- hw/ppc/Makefile.objs | 2 +- 1 file changed, 1

Re: [Qemu-devel] [PATCH V3] net: Fix dealing with packets when runstate changes

2014-08-25 Thread Jason Wang
On 08/25/2014 06:47 PM, zhanghailiang wrote: For all NICs(except virtio-net) emulated by qemu, Such as e1000, rtl8139, pcnet and ne2k_pci, Qemu can still receive packets when VM is not running. If this happened in *migration's* last PAUSE VM stage, The new dirty RAM related to the packets

Re: [Qemu-devel] [PATCH] block: Make op blockers recursive

2014-08-25 Thread Fam Zheng
On Mon, 08/25 12:12, Benoît Canet wrote: On Mon, Aug 25, 2014 at 05:37:37PM +0800, Fam Zheng wrote: On Mon, 08/25 09:06, Benoît Canet wrote: On Mon, Aug 25, 2014 at 02:04:24PM +0800, Fam Zheng wrote: On Fri, 08/22 18:11, Benoît Canet wrote: Since the block layer code is starting to

Re: [Qemu-devel] [PATCH v2 2/3] qdev: add cleanup logic in device_set_realized() to avoid resource leak

2014-08-25 Thread Gonglei (Arei)
Hi, Peter. Firstly, I appreciate your so careful and useful comments very much. -Original Message- From: peter.crosthwa...@petalogix.com [mailto:peter.crosthwa...@petalogix.com] On Behalf Of Peter Crosthwaite Sent: Tuesday, August 26, 2014 10:25 AM To: Gonglei (Arei) Cc:

Re: [Qemu-devel] [PATCH V3] net: Fix dealing with packets when runstate changes

2014-08-25 Thread zhanghailiang
On 2014/8/26 12:39, Jason Wang wrote: On 08/25/2014 06:47 PM, zhanghailiang wrote: For all NICs(except virtio-net) emulated by qemu, Such as e1000, rtl8139, pcnet and ne2k_pci, Qemu can still receive packets when VM is not running. If this happened in *migration's* last PAUSE VM stage, The new

Re: [Qemu-devel] [PATCH v12 0/6] qcow2, raw: add preallocation=full and preallocation=falloc

2014-08-25 Thread Hu Tao
On Fri, Aug 22, 2014 at 05:00:08PM +0100, Richard W.M. Jones wrote: On Fri, Aug 22, 2014 at 05:53:22PM +0200, Kevin Wolf wrote: Am 22.08.2014 um 17:34 hat Richard W.M. Jones geschrieben: On Fri, Aug 22, 2014 at 05:22:33PM +0200, Kevin Wolf wrote: It's still useful because it happens to

Re: [Qemu-devel] [PATCH memory v2 1/3] xen-hvm: Constify string

2014-08-25 Thread Stefan Weil
Am 26.08.2014 um 05:09 schrieb Peter Crosthwaite: It's constant, and sourced from existing const strings. Avoid dodgy casts by converting to const. Signed-off-by: Peter Crosthwaite peter.crosthwa...@xilinx.com --- xen-hvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)

Re: [Qemu-devel] Bug#758881: [bisected] VNC server can't get all sent chars correctly

2014-08-25 Thread Gerd Hoffmann
On Mo, 2014-08-25 at 21:11 -0700, Marc wrote: Hi, On August 25, 2014 at 3:40:01 AM, Gabriele Giacone (1o5g4...@gmail.com) wrote: IMO vncdotool should be fixed to add small delays between keyboard events, as if a real person is typing, instead of sending the key events at

Re: [Qemu-devel] Bug#758881: [bisected] VNC server can't get all sent chars correctly

2014-08-25 Thread Michael Tokarev
26.08.2014 09:40, Gerd Hoffmann wrote: There should be a delay after every character. It can be pretty small. 10ms should be enough (you should set TCP_NODELAY though to make sure the key events are not buffered in the network stack). Is this delay qemu-specific (or, rather,

<    1   2