[Qemu-devel] [PATCH] Include setjmp.h in qemu/osdep.h (bug fix for w64)

2016-03-11 Thread Stefan Weil
setjmp must be declared before sysemu/os-win32.h because it is redefined there for 64 bit Windows. Signed-off-by: Stefan Weil --- This patch superseeds my previous patch "Use special code for sigsetjmp only in cpu-exec.c". It is needed for QEMU on 64 bit Windows to get the correct definition of

Re: [Qemu-devel] [PATCH v4 4/4] hw/input/adb.c: implement QKeyCode support

2016-03-11 Thread Programmingkid
On Mar 11, 2016, at 10:30 PM, Peter Maydell wrote: > >> +} >> +keycode = s->data[s->rptr]; >> +if (++s->rptr == sizeof(s->data)) { >> +s->rptr = 0; >> } >> +s->count--; >> + >> +obuf[0] = keycode; > > You are still trying to put a two byte keycode (ADB_KEY_POWER)

Re: [Qemu-devel] [PATCH v4 4/4] hw/input/adb.c: implement QKeyCode support

2016-03-11 Thread Programmingkid
On Mar 11, 2016, at 10:30 PM, Peter Maydell wrote: > On 11 March 2016 at 09:32, Programmingkid wrote: >> Remove the old pc_to_adb_keycode array and replace it with QKeyCode support. >> >> Signed-off-by: John Arbuckle >> --- >> Some of the keys do not translate as logically as we would think th

[Qemu-devel] [Patch 1/1] net/socket: Allocating Large sized arrays to heap

2016-03-11 Thread Pooja Dhannawat
Signed-off-by: Pooja Dhannawat --- net/socket.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/net/socket.c b/net/socket.c index e32e3cb..483dcac 100644 --- a/net/socket.c +++ b/net/socket.c @@ -147,10 +147,10 @@ static void net_socket_send(void *opaque) NetSocketS

Re: [Qemu-devel] [PATCH v4 4/4] hw/input/adb.c: implement QKeyCode support

2016-03-11 Thread Peter Maydell
On 11 March 2016 at 09:32, Programmingkid wrote: > Remove the old pc_to_adb_keycode array and replace it with QKeyCode support. > > Signed-off-by: John Arbuckle > --- > Some of the keys do not translate as logically as we would think they would. > For > example the Q_KEY_CODE_CTRL_R does not wor

Re: [Qemu-devel] [PATCH v3 2/3] hw/intc: Add (new) ASPEED VIC device model

2016-03-11 Thread Andrew Jeffery
On Fri, 2016-03-11 at 16:03 +0700, Peter Maydell wrote: > On 5 March 2016 at 11:29, Andrew Jeffery wrote: > > Implement a basic ASPEED VIC device model, enough to boot a Linux kernel > > configured with aspeed_defconfig. The model implements the 'new' > > (revised) register set and while the hardw

[Qemu-devel] [PATCH] target-xtensa: use global registers for the register window

2016-03-11 Thread Max Filippov
Signed-off-by: Max Filippov --- target-xtensa/cpu.c | 1 + target-xtensa/cpu.h | 5 +++-- target-xtensa/op_helper.c | 48 --- target-xtensa/translate.c | 7 +-- 4 files changed, 21 insertions(+), 40 deletions(-) diff --git a/target-x

Re: [Qemu-devel] [PATCH v3 1/3] hw/timer: Add ASPEED timer device model

2016-03-11 Thread Andrew Jeffery
On Fri, 2016-03-11 at 15:56 +0700, Peter Maydell wrote: > On 5 March 2016 at 11:29, Andrew Jeffery wrote: > > Implement basic AST2400 timer functionality: Up to 8 timers can > > independently be configured, enabled, reset and disabled. A couple of > > hardware features are not implemented, namely

Re: [Qemu-devel] [PATCH 0/5] Add ACPI and SMBIOS table entries for IPMI

2016-03-11 Thread Corey Minyard
I haven't seen any comments on this. Is it ok? I'd like to get this in before the next release so it works automatically. On 02/25/2016 01:59 AM, miny...@acm.org wrote: Now that Igor has reworked things to remove the SSDT, I've updated IPMI code to work with the new format. This is functionall

Re: [Qemu-devel] [PATCH v4 3/4] adb-keys.h: initial commit

2016-03-11 Thread Peter Maydell
On 11 March 2016 at 09:29, Programmingkid wrote: > This commit implements the adb-keys.h file. It holds information on adb > keycode > values. > > Signed-off-by: John Arbuckle > --- Reviewed-by: Peter Maydell thanks -- PMM

Re: [Qemu-devel] [PATCH v4 1/4] ui/cocoa.m: switch to QKeyCode

2016-03-11 Thread Peter Maydell
On 11 March 2016 at 09:25, Programmingkid wrote: > This patch removes the pc/xt keycode map and replaces it with the QKeyCode > keymap. > > Signed-off-by: John Arbuckle > --- Reviewed-by: Peter Maydell thanks -- PMM

Re: [Qemu-devel] [PATCH v4 0/4] Implement some QKeyCode support

2016-03-11 Thread Peter Maydell
On 12 March 2016 at 00:19, Programmingkid wrote: > My git send-email is broken. I spend hours googling fixes that > didn't work. Unfortunately this makes it awkward for me to actually test your patches, because the tooling for handling patch mails assumes they're formatted correctly: $ patches a

Re: [Qemu-devel] [PATCH] target-arm: Fix descriptor address masking in ARM address translation

2016-03-11 Thread Peter Maydell
On 12 March 2016 at 06:44, Sergey Sorokin wrote: > 11.03.2016, 11:41, "Peter Maydell" : >>On 4 March 2016 at 23:04, Sergey Sorokin wrote: >>> There is a bug in ARM address translation regime with a long-descriptor >>> format. On the descriptor reading its address is formed from an index >>> which

Re: [Qemu-devel] [PATCH v2 00/18] Multiple fixes & improvements to QIOChannel & Win32

2016-03-11 Thread Andrew Baumann
Hi folks, > From: Paolo Bonzini [mailto:pbonz...@redhat.com] > Sent: Thursday, 10 March 2016 9:37 AM > > On 10/03/2016 18:26, Daniel P. Berrange wrote: > > This series started out as an attempt to fix the Win32 problems > > identified by Andrew Baumann > > > >https://lists.gnu.org/archive/htm

Re: [Qemu-devel] [PATCH] target-arm: Fix descriptor address masking in ARM address translation

2016-03-11 Thread Sergey Sorokin
11.03.2016, 11:41, "Peter Maydell" : >On 4 March 2016 at 23:04, Sergey Sorokin wrote: >> There is a bug in ARM address translation regime with a long-descriptor >> format. On the descriptor reading its address is formed from an index >> which is a part of the input address. And on the first iterat

[Qemu-devel] [Bug 1556306] Re: vhost-user: qemu stops processing packets under high load of traffic

2016-03-11 Thread Vincent JARDIN
for tracking, http://git.qemu.org/?p=qemu.git;a=patch;h=5669655aafdb88a8797c74a989dd0c0ebb1349fa -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1556306 Title: vhost-user: qemu stops processing p

[Qemu-devel] [RFC PATCH v4 2/3] vfio: Enable sparse mmap capability

2016-03-11 Thread Alex Williamson
The sparse mmap capability in a vfio region info allows vfio to tell us which sub-areas of a region may be mmap'd. Thus rather than assuming a single mmap covers the entire region and later frobbing it ourselves for things like the PCI MSI-X vector table, we can read that directly from vfio. Sign

[Qemu-devel] [RFC PATCH v4 3/3] vfio/pci: Intel IGD support

2016-03-11 Thread Alex Williamson
Two modes are available for IGD assignment, Universal Passthrough (UPT) and legacy. UPT mode attempts to handle the IGD device as if it were just a PCI device, requiring no collateral changes to the VM chipset. For the most part this works without these changes. The one feature found here for UP

[Qemu-devel] [RFC PATCH v4 1/3] linux-headers/vfio: Update matching current linux-next

2016-03-11 Thread Alex Williamson
These changes should appear in kernel v4.6. Signed-off-by: Alex Williamson --- linux-headers/linux/vfio.h | 92 +++- 1 file changed, 90 insertions(+), 2 deletions(-) diff --git a/linux-headers/linux/vfio.h b/linux-headers/linux/vfio.h index 15e096c..759

[Qemu-devel] [RFC PATCH v4 0/3] vfio IGD assignment

2016-03-11 Thread Alex Williamson
This series applies on top of my latest vfio pull request[1] or directly to the tag mentioned there[2]. It also requires kernel support that's currently in linux-next for v4.6, thus the RFC here. IGD assignment also requires SeaBIOS support as noted in the commit log of the 3rd patch here. Patch

Re: [Qemu-devel] [PATCH v4 17/26] tests: refactor python I/O tests helper main method

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > The iotests.py helper provides a main() method for running > tests via the python unit test framework. Not all tests > will want to use this, so refactor it to split the testing > of compatible formats and platforms into separate helper > methods

Re: [Qemu-devel] [PATCH v4 16/26] tests: redirect stderr to stdout for iotests

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > The python I/O tests helper for running qemu-img/qemu-io > setup stdout to be captured to a pipe, but left stderr > untouched. As a result, if something failed in qemu-img/ > qemu-io, data written to stderr would get output directly > and not line

[Qemu-devel] [Bug 1556306] [NEW] vhost-user: qemu stops processing packets under high load of traffic

2016-03-11 Thread Vincent JARDIN
Public bug reported: Description of problem: - qemu socket becomes full, causing qemu to send incomplete SET_VRING_CALL messages to vhost-user backend (without proper fd set in ancillary data). - after some time, some interrupts are lost, causing the VM to stop transmitting packets. How reproduci

Re: [Qemu-devel] Memory on stellaris board

2016-03-11 Thread Peter Maydell
On 11 March 2016 at 21:12, Aurelio Remonda wrote: > I don't quite understand what you mean with non-round-number, are you > suggesting > we only accept for example: > 64K-128K-256K-512K-1024k(or 1M)-2048K(or 2M) > 4096K(or 4M)-8192K(or 8M)-16384K(or 16M) > If that's the case we will never have, f

Re: [Qemu-devel] [PATCH v4 13/26] crypto: implement the LUKS block encryption format

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > Provide a block encryption implementation that follows the > LUKS/dm-crypt specification. > > This supports all combinations of hash, cipher algorithm, > cipher mode and iv generator that are implemented by the > current crypto layer. > > The no

[Qemu-devel] [PATCH 1/1] Allocating Large sized arrays to heap

2016-03-11 Thread Jaya Tiwari
As per the list of functions in http://wiki.qemu.org/BiteSizedTasks#Large_frames, qemu_get_virtqueue_element and qemu_put_virtqueue_element have large arrays on stack Hence, moving them to heap. This reduced their stack size from something 49248 to fit into less than 200 Signed-off-by: Jaya Ti

[Qemu-devel] [PATCH] BiteSizedTasks-LargeFrames

2016-03-11 Thread Siddharth Gupta
From 032be62f56a207833ae12cc9474e3e8be5ed8eb4 Mon Sep 17 00:00:00 2001 From: Siddharth Gupta Date: Fri, 11 Mar 2016 20:10:41 +0530 Subject: [PATCH] bitesizedtasks-large_frames-hw_dma_xilinx-hw_net_virtio --- hw/dma/xilinx_axidma.c | 5 - hw/net/virtio-net.c| 11 ++- 2 files cha

[Qemu-devel] [Patch] BiteSizedTasks LargeFrames

2016-03-11 Thread Siddharth Gupta
>From 032be62f56a207833ae12cc9474e3e8be5ed8eb4 Mon Sep 17 00:00:00 2001 From: Siddharth Gupta Date: Fri, 11 Mar 2016 20:10:41 +0530 Subject: [PATCH] bitesizedtasks-large_frames-hw_dma_xilinx-hw_net_virtio --- hw/dma/xilinx_axidma.c | 5 - hw/net/virtio-net.c| 11 ++- 2 files cha

Re: [Qemu-devel] [PATCH v4 12/26] crypto: add block encryption framework

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > Add a generic framework for support different block encryption s/support/supporting/ > formats. Upon instantiating a QCryptoBlock object, it will read > the encryption header and extract the encryption keys. It is > then possible to call methods

Re: [Qemu-devel] [PATCH v4 11/26] crypto: wire up XTS mode for cipher APIs

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > Introduce 'XTS' as a permitted mode for the cipher APIs. > With XTS the key provided must be twice the size of the > key normally required for any given algorithm. This is > because the key will be split into two pieces for use > in XTS mode. > >

Re: [Qemu-devel] [PATCH v4 10/26] crypto: refactor code for dealing with AES cipher

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > The built-in and nettle cipher backends for AES maintain > two separate AES contexts, one for encryption and one for > decryption. This is going to be inconvenient for the future > code dealing with XTS, so wrap them up in a single struct > so the

Re: [Qemu-devel] [PATCH v4 09/26] crypto: import an implementation of the XTS cipher mode

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > The XTS (XEX with tweaked-codebook and ciphertext stealing) > cipher mode is commonly used in full disk encryption. There > is unfortunately no implementation of it in either libgcrypt > or nettle, so we need to provide our own. > > The libtomcry

Re: [Qemu-devel] [PATCH v4 00/15] Dirty bitmap changes for migration/persistence work

2016-03-11 Thread John Snow
On 03/11/2016 08:57 AM, Max Reitz wrote: > On 08.03.2016 05:44, Fam Zheng wrote: >> v4: Rebase. >> Add rev-by from John in patches 1-5, 7, 8. >> Remove BdrvDirtyBitmap typedef from dirty-bitmap.h in patch 4. [Max] >> Add assertion on bm->meta in patch 9. [John] >> >> Two major feature

Re: [Qemu-devel] [PATCH v4 08/26] crypto: add support for the twofish cipher algorithm

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > New cipher algorithms 'twofish-128', 'twofish-192' and > 'twofish-256' are defined for the Twofish algorithm. > The gcrypt backend does not support 'twofish-192'. > > The nettle and gcrypt cipher backends are updated to > support the new cipher a

Re: [Qemu-devel] [PATCH v4 07/26] crypto: add support for the serpent cipher algorithm

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > New cipher algorithms 'serpent-128', 'serpent-192' and > 'serpent-256' are defined for the Serpent algorithm. > > The nettle and gcrypt cipher backends are updated to > support the new cipher and a test vector added to the > cipher test suite. Th

Re: [Qemu-devel] [PATCH v4 06/26] crypto: add support for the cast5-128 cipher algorithm

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > A new cipher algorithm 'cast-5-128' is defined for the > Cast-5 algorithm with 128 bit key size. Smaller key sizes > are supported by Cast-5, but nothing in QEMU should use > them, so only 128 bit keys are permitted. > > The nettle and gcrypt cip

Re: [Qemu-devel] [PATCH v4 05/26] crypto: skip testing of unsupported cipher algorithms

2016-03-11 Thread Eric Blake
On 02/29/2016 05:00 AM, Daniel P. Berrange wrote: > We don't guarantee that all crypto backends will support > all cipher algorithms, so we should skip tests unless > the crypto backend indicates support. > > Signed-off-by: Daniel P. Berrange > --- > tests/test-crypto-cipher.c | 4 +++- > 1 file

Re: [Qemu-devel] [PATCH v2 00/24] target-sparc improvements

2016-03-11 Thread Artyom Tarasenko
On Fri, Feb 26, 2016 at 10:44 AM, Mark Cave-Ayland wrote: > On 23/02/16 21:11, Richard Henderson wrote: > >> The primary focus of this patch set is to reduce the number of >> helpers that modify TCG globals, and thus increase the lifetime >> of those globals within each TB, and thus decrease the n

[Qemu-devel] [PATCH] spapr_rng: fix race with main loop

2016-03-11 Thread Greg Kurz
Since commit "60253ed1e6ec rng: add request queue support to rng-random", the use of a spapr_rng device may hang vCPU threads. The following path is taken without holding the lock to the main loop mutex: h_random() rng_backend_request_entropy() rng_random_request_entropy() qemu_set_fd

[Qemu-devel] [PULL 2/2] kvm: Remove x2apic feature from CPU model when kernel_irqchip is off

2016-03-11 Thread Eduardo Habkost
From: Lan Tianyu x2apic feature is in the kvm_default_props and automatically added to all CPU models when KVM is enabled. But userspace devices don't support x2apic which can't be enabled without the in-kernel irqchip. It will trigger warning of "host doesn't support requested feature: CPUID.01H

[Qemu-devel] [PULL 1/2] hyperv: cpu hotplug fix with HyperV enabled

2016-03-11 Thread Eduardo Habkost
From: "Denis V. Lunev" With Hyper-V enabled CPU hotplug stops working. The CPU appears in device manager on Windows but does not appear in peformance monitor and control panel. The root of the problem is the following. Windows checks HV_X64_CPU_DYNAMIC_PARTITIONING_AVAILABLE bit in CPUID. The pr

[Qemu-devel] [PULL 0/2] X86 fixes

2016-03-11 Thread Eduardo Habkost
The following changes since commit a648c137383d84bc4f95696e5293978d9541a26e: Merge remote-tracking branch 'remotes/kraxel/tags/pull-ui-20160309-1' into staging (2016-03-10 02:51:14 +) are available in the git repository at: git://github.com/ehabkost/qemu.git tags/x86-pull-request for y

Re: [Qemu-devel] [PATCH] char: translate from QIOChannel error to errno

2016-03-11 Thread Daniel P. Berrange
On Fri, Mar 11, 2016 at 06:55:24PM +0100, marcandre.lur...@redhat.com wrote: > From: Marc-André Lureau > > Caller of CharDriverState.chr* callback assume errno error conventions. > Translate QIOChannel error to errno (this fixes potential EAGAIN > regression, for ex if a vhost-user backend block,

Re: [Qemu-devel] [PATCH v2] hw/i386: fix unbounded stack for load_multiboot

2016-03-11 Thread Eduardo Habkost
On Wed, Mar 09, 2016 at 04:30:10PM +0800, Peter Xu wrote: > Use heap rather than stack for kcmdline. > > Signed-off-by: Peter Xu Reviewed-by: Eduardo Habkost I believe it can go through the PC tree. -- Eduardo

Re: [Qemu-devel] [RFC PATCH v2 3/3] VFIO: Type1 IOMMU mapping support for vGPU

2016-03-11 Thread Neo Jia
On Fri, Mar 11, 2016 at 10:56:24AM -0700, Alex Williamson wrote: > On Fri, 11 Mar 2016 08:55:44 -0800 > Neo Jia wrote: > > > > > Alex, what's your opinion on this? > > > > > > The sticky point is how vfio, which is only handling the vGPU, has a > > > reference to the physical GPU on which to c

Re: [Qemu-devel] [RFC PATCH v2 3/3] VFIO: Type1 IOMMU mapping support for vGPU

2016-03-11 Thread Alex Williamson
On Fri, 11 Mar 2016 08:55:44 -0800 Neo Jia wrote: > On Fri, Mar 11, 2016 at 09:13:15AM -0700, Alex Williamson wrote: > > On Fri, 11 Mar 2016 04:46:23 + > > "Tian, Kevin" wrote: > > > > > > From: Neo Jia [mailto:c...@nvidia.com] > > > > Sent: Friday, March 11, 2016 12:20 PM > > > > > > >

[Qemu-devel] [PATCH] char: translate from QIOChannel error to errno

2016-03-11 Thread marcandre . lureau
From: Marc-André Lureau Caller of CharDriverState.chr* callback assume errno error conventions. Translate QIOChannel error to errno (this fixes potential EAGAIN regression, for ex if a vhost-user backend block, qemu_chr_fe_read_all() could get error -2 and not wait) Signed-off-by: Marc-André Lur

[Qemu-devel] [PATCH v4 09/28] migration: add helpers for creating QEMUFile from a QIOChannel

2016-03-11 Thread Daniel P. Berrange
Currently creating a QEMUFile instance from a QIOChannel is quite simple only requiring a single call to qemu_fopen_channel_input or qemu_fopen_channel_output depending on the end of migration connection. When QEMU gains TLS support, however, there will need to be a TLS negotiation done inbetween

Re: [Qemu-devel] [PATCH] BitsSizedTasks-LargeFrames

2016-03-11 Thread Eric Blake
On 03/11/2016 08:50 AM, Bastian Koppelmann wrote: > Hi Siddharth, > > thanks for the patch. Can you resend it inlined into the e-mail instead > of an attachment? I usually use git send-email for that. > My workflow (once you have configured git send-email) would be: > > - git format-patch -1 > -

[Qemu-devel] [PATCH v4 06/28] migration: introduce set_blocking function in QEMUFileOps

2016-03-11 Thread Daniel P. Berrange
Remove the assumption that every QEMUFile implementation has a file descriptor available by introducing a new function in QEMUFileOps to change the blocking state of a QEMUFile. If not set, it will fallback to the original code using the get_fd method. Reviewed-by: Dr. David Alan Gilbert Signed-

[Qemu-devel] [PATCH v4 14/28] migration: convert tcp socket protocol to use QIOChannel

2016-03-11 Thread Daniel P. Berrange
Drop the current TCP socket migration driver and extend the new generic socket driver to cope with the TCP address format Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- migration/Makefile.objs | 2 +- migration/socket.c | 31 +++ migration/tcp.c

[Qemu-devel] [PATCH v4 19/28] migration: delete QEMUFile buffer implementation

2016-03-11 Thread Daniel P. Berrange
The qemu_bufopen() method is no longer used, so the memory buffer based QEMUFile backend can be deleted entirely. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- include/migration/qemu-file.h | 6 --- migration/qemu-file-buf.c | 96

[Qemu-devel] [PATCH V1 1/2] arm: virt: Add an abstract ARM virt machine type

2016-03-11 Thread Wei Huang
In preparation for future ARM virt machine types, this patch creates an abstract type for all ARM machines. The current machine type in QEMU (i.e. "virt") is renamed to "virt-2.6", whose naming scheme is similar to other architectures. For the purpose of backward compatibility, "virt" is converted

[Qemu-devel] [PATCH V1 0/2] Versioning ARM virt machine types

2016-03-11 Thread Wei Huang
We start to see more features been added to ARM virtual machine models. For the purpose of backward compatibility (e.g. migration), it is time to consider versioning machine types for ARM VMs. As a beginning step, this patchset defines an abstract machine type for ARM VMs. The current "virt" machin

[Qemu-devel] [PATCH V1 2/2] arm: virt: Move machine class init code to the abstract machine type

2016-03-11 Thread Wei Huang
This patch moves the common class initialization code from "virt-2.6" to the new abstract class. An empty property is added to "virt-2.6" machine. In the meanwhile, related funtions are renamed to "virt_2_6_*" for consistency. Signed-off-by: Wei Huang --- hw/arm/virt.c | 34 -

[Qemu-devel] [PATCH v4 15/28] migration: convert fd socket protocol to use QIOChannel

2016-03-11 Thread Daniel P. Berrange
Convert the fd socket migration protocol driver to use QIOChannel and QEMUFileChannel, instead of plain sockets APIs. It can be unconditionally built because the QIOChannel APIs it uses will take care to report suitable error messages if needed. Reviewed-by: Dr. David Alan Gilbert Signed-off-by:

Re: [Qemu-devel] [PATCH v5 04/14] qapi: Adjust names of implicit types

2016-03-11 Thread Eric Blake
On 03/11/2016 12:48 AM, Markus Armbruster wrote: time to change our naming convention; we can instead use the 'q_' prefix that we reserved for ourselves back in commit 9fb081e0. As long as we don't declare 'empty' or 'obj' ticklish, it shouldn't clash with c_name() prepending

Re: [Qemu-devel] [PATCH v4 0/4] Implement some QKeyCode support

2016-03-11 Thread Programmingkid
On Mar 11, 2016, at 12:14 PM, Eric Blake wrote: > On 03/10/2016 07:24 PM, Programmingkid wrote: >> This patchset adds QKeyCode support the adb and cocoa code. >> >> Note: you do not need to be on a Mac to test out the adb.c, qapi-schema.json, >> and adb-keys.h files. Only the cocoa.m file chang

Re: [Qemu-devel] [PATCH v4 2/4] qapi-schema.json: Add power and keypad equal keys

2016-03-11 Thread Programmingkid
On Mar 11, 2016, at 12:12 PM, Eric Blake wrote: > On 03/10/2016 07:28 PM, Programmingkid wrote: >> Add the power and keypad equal keys. These keys are found on a real Macintosh >> keyboard. >> >> Signed-off-by: John Arbuckle > > This looks unchanged from v3: > > https://lists.gnu.org/archive/

[Qemu-devel] [PATCH v3] hw: fix error reporting for missing option ROMs

2016-03-11 Thread Daniel P. Berrange
If QEMU fails to load any of the VGA ROMs, it prints a message to stderr and then carries on as if everything was fine, despite the VGA interface not being functional. This extends the the various rom_add_*() methods in loader.h to accept a 'Error **errp' parameter. The VGA device realizefn() impls

Re: [Qemu-devel] [PATCH v4 0/4] Implement some QKeyCode support

2016-03-11 Thread Eric Blake
On 03/10/2016 07:24 PM, Programmingkid wrote: > This patchset adds QKeyCode support the adb and cocoa code. > > Note: you do not need to be on a Mac to test out the adb.c, qapi-schema.json, > and adb-keys.h files. Only the cocoa.m file changes are Mac specific. > > If you are using Linux as a gu

Re: [Qemu-devel] [PATCH v4 2/4] qapi-schema.json: Add power and keypad equal keys

2016-03-11 Thread Eric Blake
On 03/10/2016 07:28 PM, Programmingkid wrote: > Add the power and keypad equal keys. These keys are found on a real Macintosh > keyboard. > > Signed-off-by: John Arbuckle This looks unchanged from v3: https://lists.gnu.org/archive/html/qemu-devel/2016-03/msg01244.html which means you could hav

[Qemu-devel] [PATCH v4 21/28] migration: delete QEMUFile sockets implementation

2016-03-11 Thread Daniel P. Berrange
Now that the tcp, unix and fd migration backends have converted to use the QIOChannel based QEMUFile, there is no user remaining for the sockets based QEMUFile impl and it can be deleted. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- include/migration/qemu-file.h |

[Qemu-devel] [PATCH v4 18/28] migration: convert savevm to use QIOChannel for writing to files

2016-03-11 Thread Daniel P. Berrange
Convert the exec savevm code to use QIOChannel and QEMUFileChannel, instead of the stdio APIs. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- migration/savevm.c | 8 +--- tests/Makefile | 4 ++-- tests/test-vmstate.c | 11 ++- 3 files changed, 17

[Qemu-devel] [PATCH v4 20/28] migration: delete QEMUSizedBuffer struct

2016-03-11 Thread Daniel P. Berrange
Now that we don't have have a buffer based QemuFile implementation, the QEMUSizedBuffer code is also unused and can be deleted. A simpler buffer class also exists in util/buffer.c which other code can used as needed. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- incl

[Qemu-devel] [PATCH v4 28/28] migration: remove qemu_get_fd method from QEMUFile

2016-03-11 Thread Daniel P. Berrange
Now that there is a set_blocking callback in QEMUFileOps, and all users needing non-blocking support have been converted to QIOChannel, there is no longer any codepath requiring the qemu_get_fd() method for QEMUFile. Remove it to avoid further code being introduced with an expectation of direct fil

Re: [Qemu-devel] [PATCH v2] hw: fix error reporting for missing option ROMs

2016-03-11 Thread Eric Blake
On 03/11/2016 04:18 AM, Daniel P. Berrange wrote: > If QEMU fails to load any of the VGA ROMs, it prints a message > to stderr and then carries on as if everything was fine, despite > the VGA interface not being functional. This extends the the > various rom_add_*() methods in loader.h to accept a

[Qemu-devel] [PATCH v4 24/28] migration: don't use an array for storing migrate parameters

2016-03-11 Thread Daniel P. Berrange
The MigrateState struct uses an array for storing migration parameters. This presumes that all future parameters will be integers too, which is not going to be the case. There is no functional reason why an array is used, if anything it makes the code less clear. The QAPI schema already defines a s

Re: [Qemu-devel] [RFC PATCH v2 3/3] VFIO: Type1 IOMMU mapping support for vGPU

2016-03-11 Thread Neo Jia
On Fri, Mar 11, 2016 at 09:13:15AM -0700, Alex Williamson wrote: > On Fri, 11 Mar 2016 04:46:23 + > "Tian, Kevin" wrote: > > > > From: Neo Jia [mailto:c...@nvidia.com] > > > Sent: Friday, March 11, 2016 12:20 PM > > > > > > On Thu, Mar 10, 2016 at 11:10:10AM +0800, Jike Song wrote: > > > >

Re: [Qemu-devel] [PATCH v4 04/26] crypto: add support for anti-forensic split algorithm

2016-03-11 Thread Daniel P. Berrange
On Mon, Mar 07, 2016 at 01:51:40PM +0800, Fam Zheng wrote: > On Mon, 02/29 12:00, Daniel P. Berrange wrote: > > The LUKS format specifies an anti-forensic split algorithm which > > is used to artificially expand the size of the key material on > > disk. This is an implementation of that algorithm.

[Qemu-devel] [PATCH v4 26/28] migration: add support for encrypting data with TLS

2016-03-11 Thread Daniel P. Berrange
This extends the migration_set_incoming_channel and migration_set_outgoing_channel methods so that they will automatically wrap the QIOChannel in a QIOChannelTLS instance if TLS credentials are configured in the migration parameters. This allows TLS to work for tcp, unix, fd and exec migration pro

[Qemu-devel] [PATCH v4 23/28] migration: move definition of struct QEMUFile back into qemu-file.c

2016-03-11 Thread Daniel P. Berrange
Now that the memory buffer based QEMUFile impl is gone, there is no need for any backend to be accessing internals of the QEMUFile struct, so it can be moved back into qemu-file.c Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- migration/qemu-file-internal.h | 54 -

[Qemu-devel] [PATCH v4 25/28] migration: define 'tls-creds' and 'tls-hostname' migration parameters

2016-03-11 Thread Daniel P. Berrange
Define two new migration parameters to be used with TLS encryption. The 'tls-creds' parameter provides the ID of an instance of the 'tls-creds' object type, or rather a subclass such as 'tls-creds-x509'. Providing these credentials will enable use of TLS on the migration data stream. If using x509

[Qemu-devel] [PATCH v4 27/28] migration: remove support for non-iovec based write handlers

2016-03-11 Thread Daniel P. Berrange
All the remaining QEMUFile implementations provide an iovec based write handler, so the put_buffer callback can be removed to simplify the code. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- include/migration/qemu-file.h | 9 - migration/qemu-file.c

[Qemu-devel] [PATCH v4 22/28] migration: delete QEMUFile stdio implementation

2016-03-11 Thread Daniel P. Berrange
Now that the exec migration backend and savevm have converted to use the QIOChannel based QEMUFile, there is no user remaining for the stdio based QEMUFile impl and it can be deleted. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- include/migration/qemu-file.h | 2 -

[Qemu-devel] [PATCH v4 17/28] migration: convert RDMA to use QIOChannel interface

2016-03-11 Thread Daniel P. Berrange
This converts the RDMA code to provide a subclass of QIOChannel that uses RDMA for the data transport. This implementation of RDMA does not correctly handle non-blocking mode. Reads might block if there was not already some pending data and writes will block until all data is sent. This flawed beh

[Qemu-devel] [PATCH v4 16/28] migration: convert exec socket protocol to use QIOChannel

2016-03-11 Thread Daniel P. Berrange
Convert the exec socket migration protocol driver to use QIOChannel and QEMUFileChannel, instead of the stdio popen APIs. It can be unconditionally built because the QIOChannelCommand class can report suitable error messages on platforms which can't fork processes. Reviewed-by: Dr. David Alan Gilb

[Qemu-devel] [PATCH v4 10/28] migration: add reporting of errors for outgoing migration

2016-03-11 Thread Daniel P. Berrange
Currently if an application initiates an outgoing migration, it may or may not, get an error reported back on failure. If the error occurs synchronously to the 'migrate' command execution, the client app will see the error message. This is the case for DNS lookup failures. If the error occurs async

[Qemu-devel] [PATCH v4 02/28] io: avoid double-free when closing QIOChannelBuffer

2016-03-11 Thread Daniel P. Berrange
The QIOChannelBuffer's close implementation will free the internal data buffer. It failed to reset the pointer to NULL though, so when the object is later finalized it will free it a second time with predictable crash. Signed-off-by: Daniel P. Berrange --- io/channel-buffer.c | 1 + 1 file chang

[Qemu-devel] [PATCH v4 13/28] migration: rename unix.c to socket.c

2016-03-11 Thread Daniel P. Berrange
The unix.c file will be nearly the same as the tcp.c file, only differing in the initial SocketAddress creation code. Rename unix.c to socket.c and refactor it a little to prepare for merging the TCP code. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- migration/Makef

[Qemu-devel] [PATCH v4 11/28] migration: convert post-copy to use QIOChannelBuffer

2016-03-11 Thread Daniel P. Berrange
The post-copy code does some I/O to/from an intermediate in-memory buffer rather than direct to the underlying I/O channel. Switch this code to use QIOChannelBuffer instead of QEMUSizedBuffer. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- docs/migration.txt | 4

[Qemu-devel] [PATCH v4 12/28] migration: convert unix socket protocol to use QIOChannel

2016-03-11 Thread Daniel P. Berrange
Convert the unix socket migration protocol driver to use QIOChannel and QEMUFileChannel, instead of plain sockets APIs. It can be unconditionally built, since the socket impl of QIOChannel will report a suitable error on platforms where UNIX sockets are unavailable. Reviewed-by: Dr. David Alan Gil

[Qemu-devel] [PATCH v4 05/28] migration: split migration hooks out of QEMUFileOps

2016-03-11 Thread Daniel P. Berrange
The QEMUFileOps struct contains the I/O subsystem callbacks and the migration stage hooks. Split the hooks out into a separate QEMUFileHooks struct to make it easier to refactor the I/O side of QEMUFile without affecting the hooks. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berr

[Qemu-devel] [PATCH v4 07/28] migration: force QEMUFile to blocking mode for outgoing migration

2016-03-11 Thread Daniel P. Berrange
Instead of relying on the default QEMUFile I/O blocking flag state, explicitly turn on blocking I/O for outgoing migration since it takes place in a background thread. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- migration/migration.c | 1 + 1 file changed, 1 insert

[Qemu-devel] [PATCH v4 00/28] Convert migration to QIOChannel & support TLS

2016-03-11 Thread Daniel P. Berrange
This is an update of patches that were previously posted FYI: https://lists.gnu.org/archive/html/qemu-devel/2015-09/msg00829.html v1: https://lists.gnu.org/archive/html/qemu-devel/2016-01/msg01914.html v2: https://lists.gnu.org/archive/html/qemu-devel/2016-02/msg03509.html v3: https://l

[Qemu-devel] [PATCH v4 01/28] s390: use FILE instead of QEMUFile for creating text file

2016-03-11 Thread Daniel P. Berrange
The s390 skeys monitor command needs to write out a plain text file. Currently it is using the QEMUFile class for this, but work is ongoing to refactor QEMUFile and eliminate much code related to it. The only feature qemu_fopen() gives over fopen() is support for QEMU FD passing, but this can be ac

[Qemu-devel] [PATCH v4 04/28] migration: ensure qemu_fflush() always writes full data amount

2016-03-11 Thread Daniel P. Berrange
The QEMUFile writev_buffer / put_buffer functions are expected to write out the full set of requested data, blocking until complete. The qemu_fflush() caller does not expect to deal with partial writes. Clarify the function comments and add a sanity check to the code to catch mistaken implementatio

[Qemu-devel] [PATCH v4 08/28] migration: introduce a new QEMUFile impl based on QIOChannel

2016-03-11 Thread Daniel P. Berrange
Introduce a new QEMUFile implementation that is based on the QIOChannel objects. This impl is different from existing impls in that there is no file descriptor that can be made available, as some channels may be based on higher level protocols such as TLS. Although the QIOChannel based implementat

[Qemu-devel] [PATCH v4 03/28] migration: remove use of qemu_bufopen from vmstate tests

2016-03-11 Thread Daniel P. Berrange
Some of the test-vmstate.c test cases use a temporary file while others use a memory buffer. To facilitate the future removal of the qemu_bufopen() function, convert all the tests to use a temporary file. Reviewed-by: Dr. David Alan Gilbert Signed-off-by: Daniel P. Berrange --- tests/Makefile

Re: [Qemu-devel] BiteSizedPatch-LargeFrames

2016-03-11 Thread Alex Bennée
Siddharth Gupta writes: > From 032be62f56a207833ae12cc9474e3e8be5ed8eb4 Mon Sep 17 00:00:00 2001 > From: Siddharth Gupta > Date: Fri, 11 Mar 2016 20:10:41 +0530 > Subject: [PATCH] > bitesizedtasks-large_frames-hw_dma_xilinx-hw_net_virtio I think the subject should be what was done rather than

Re: [Qemu-devel] [PATCH] iotests: Correct 081's reference output

2016-03-11 Thread Max Reitz
On 11.03.2016 15:14, Max Reitz wrote: > The newly added type parameter for the QUORUM_REPORT_BAD event changed > the output of iotest 081, so the reference should be amended > accordingly. > > Signed-off-by: Max Reitz > --- > tests/qemu-iotests/081.out | 2 +- > 1 file changed, 1 insertion(+), 1

Re: [Qemu-devel] [PATCH v4 15/15] block: More operations for meta dirty bitmap

2016-03-11 Thread Max Reitz
On 08.03.2016 05:45, Fam Zheng wrote: > Callers can create an iterator of meta bitmap with > bdrv_dirty_meta_iter_new(), then use the bdrv_dirty_iter_* operations on > it. Meta iterators are also counted by bitmap->active_iterators. > > Also add a couple of functions to retrieve granularity and co

Re: [Qemu-devel] [PATCH v4 12/15] hbitmap: serialization

2016-03-11 Thread Max Reitz
On 08.03.2016 05:45, Fam Zheng wrote: > From: Vladimir Sementsov-Ogievskiy > > Functions to serialize / deserialize(restore) HBitmap. HBitmap should be > saved to linear sequence of bits independently of endianness and bitmap > array element (unsigned long) size. Therefore Little Endian is chosen

Re: [Qemu-devel] [PATCH v3 00/13] tests: Introducing docker tests

2016-03-11 Thread Alex Bennée
Fam Zheng writes: > v3 changes: I think we are almost there. There a just a few tweaks to be made to help text and prompts. Can you ensure that all examples in commit messages and help text actually do run as expected? Is it proposed this goes through Daniel's treee? > - Merge all docker_*

Re: [Qemu-devel] [PATCH v3 12/13] .gitignore: Ignore temporary dockerfile

2016-03-11 Thread Alex Bennée
Fam Zheng writes: > Docker build requires a "context" directory and we use the > $QEMU_SRC/tests/docker/ directory, and the temoprary dockerfile has to be in > the context. > > docker_build normally cleans up this file but let's add an entry here just in > case it fails to. I think the need for

Re: [Qemu-devel] [PATCH v3 11/13] docs: Add text for tests/docker in build-system.txt

2016-03-11 Thread Alex Bennée
Fam Zheng writes: > Signed-off-by: Fam Zheng Reviewed-by: Alex Bennée > --- > docs/build-system.txt | 5 + > 1 file changed, 5 insertions(+) > > diff --git a/docs/build-system.txt b/docs/build-system.txt > index 5ea..2af1e66 100644 > --- a/docs/build-system.txt > +++ b/docs/build-sy

Re: [Qemu-devel] [PATCH v3 10/13] docker: Add travis tool

2016-03-11 Thread Alex Bennée
Fam Zheng writes: > The script is not named test-travis.sh so it won't run with "make > docker-run", because it can take too long. > > Run it with "make docker-run-travis.sh@ubuntu". 16:08 alex@zen/x86_64 [qemu.git/review/docker-v3] >make docker-run-travis.sh@ubuntu ARCHIVE qemu.tgz COPY RUNN

Re: [Qemu-devel] [PATCH v3 09/13] docker: Add mingw test

2016-03-11 Thread Alex Bennée
Fam Zheng writes: > Signed-off-by: Fam Zheng Reviewed-by: Alex Bennée > --- > tests/docker/test-mingw | 34 ++ > 1 file changed, 34 insertions(+) > create mode 100755 tests/docker/test-mingw > > diff --git a/tests/docker/test-mingw b/tests/docker/test-mingw

Re: [Qemu-devel] [RFC PATCH v2 3/3] VFIO: Type1 IOMMU mapping support for vGPU

2016-03-11 Thread Alex Williamson
On Fri, 11 Mar 2016 04:46:23 + "Tian, Kevin" wrote: > > From: Neo Jia [mailto:c...@nvidia.com] > > Sent: Friday, March 11, 2016 12:20 PM > > > > On Thu, Mar 10, 2016 at 11:10:10AM +0800, Jike Song wrote: > > > > > > >> Is it supposed to be the caller who should set > > > >> up IOMMU by D

Re: [Qemu-devel] [PATCH v3 08/13] docker: Add clang test

2016-03-11 Thread Alex Bennée
Fam Zheng writes: > The (currently partially commented out) configure options are suggested > by John Snow . > > Signed-off-by: Fam Zheng Reviewed-by: Alex Bennée > --- > tests/docker/test-clang | 25 + > 1 file changed, 25 insertions(+) > create mode 100755 tests/d

  1   2   3   >