[Qemu-devel] [PULL 02/48] coroutine: remove unused CoQueue AioContext

2013-12-06 Thread Stefan Hajnoczi
From: Marc-André Lureau marcandre.lur...@gmail.com The AioContext ctx field is apparently unused in qemu codebase since 02ffb504485. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- include/block/coroutine.h | 1 - 1 file

[Qemu-devel] [PULL 12/48] block drivers: expose requirement for write same alignment from formats

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com This will let misaligned but large requests use zero clusters. This is important because the cluster size is not guest visible. Signed-off-by: Paolo Bonzini pbonz...@redhat.com Reviewed-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan Hajnoczi

[Qemu-devel] [PULL 09/48] block: make bdrv_co_do_write_zeroes stricter in producing aligned requests

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com Right now, bdrv_co_do_write_zeroes will only try to align the beginning of the request. However, it is simpler for many formats to expect the block layer to separate both the head *and* the tail. This makes sure that the format's bdrv_co_write_zeroes

[Qemu-devel] [PULL 01/48] coroutine: remove qemu_co_queue_wait_insert_head

2013-12-06 Thread Stefan Hajnoczi
From: Marc-André Lureau marcandre.lur...@gmail.com qemu_co_queue_wait_insert_head() is unused in qemu code base now. Signed-off-by: Marc-André Lureau marcandre.lur...@gmail.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- include/block/coroutine.h | 6 -- qemu-coroutine-lock.c

[Qemu-devel] [PULL 15/48] block/iscsi: check WRITE SAME support differently depending on MAY_UNMAP

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com The current check is right for MAY_UNMAP=1. For MAY_UNMAP=0, just try and fall back to regular writes as soon as a WRITE SAME command fails. Signed-off-by: Paolo Bonzini pbonz...@redhat.com Reviewed-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan

[Qemu-devel] [PULL 08/48] block: handle ENOTSUP from discard in generic code

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com Similar to write_zeroes, let the generic code receive a ENOTSUP for discard operations. Since bdrv_discard has advisory semantics, we can just swallow the error. Signed-off-by: Paolo Bonzini pbonz...@redhat.com Reviewed-by: Peter Lieven p...@kamp.de

[Qemu-devel] [PULL 06/48] block: add flags argument to bdrv_co_write_zeroes tracepoint

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com Reviewed-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- block.c | 2 +- trace-events | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/block.c

[Qemu-devel] [PULL 13/48] block/iscsi: remove .bdrv_has_zero_init

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de since commit 3ac21627 the default value changed to 0. Signed-off-by: Peter Lieven p...@kamp.de Signed-off-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- block/iscsi.c | 7 --- 1 file changed, 7 deletions(-) diff

[Qemu-devel] [PULL 10/48] vpc, vhdx: add get_info

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com Reviewed-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- block/vhdx.c | 10 ++ block/vpc.c | 14 ++ 2 files changed, 24 insertions(+) diff --git

[Qemu-devel] [PULL 14/48] block/iscsi: updated copyright

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de added myself to reflect recent work on the iscsi block driver. Signed-off-by: Peter Lieven p...@kamp.de Signed-off-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- block/iscsi.c | 1 + 1 file changed, 1 insertion(+)

[Qemu-devel] [PULL 19/48] qemu-iotests: 033 is fast

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- tests/qemu-iotests/group | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qemu-iotests/group b/tests/qemu-iotests/group index

[Qemu-devel] [PULL 17/48] raw-posix: implement write_zeroes with MAY_UNMAP for block devices

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com See the next commit for the description of the Linux kernel problem that is worked around in raw_open_common. Signed-off-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- block/raw-posix.c | 37

[Qemu-devel] [PULL 21/48] scsi-disk: reject ANCHOR=1 for UNMAP and WRITE SAME commands

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com Since we report ANC_SUP==0 in VPD page B2h, we need to return an error (ILLEGAL REQUEST/INVALID FIELD IN CDB) for all WRITE SAME requests with ANCHOR==1. Inspired by a similar patch to the LIO in-kernel target. Signed-off-by: Paolo Bonzini

[Qemu-devel] [PULL 22/48] scsi-disk: correctly implement WRITE SAME

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com Fetch the data to be written from the input buffer. If it is all zeroes, we can use the write_zeroes call (possibly with the new MAY_UNMAP flag). Otherwise, do as many write cycles as needed, writing 512k at a time. Strictly speaking, this is still

[Qemu-devel] [PULL 34/48] qemu-img: add -l for snapshot in convert

2013-12-06 Thread Stefan Hajnoczi
From: Wenchao Xia xiaw...@linux.vnet.ibm.com Now qemu-img convert have similar options as qemu-nbd for internal snapshot. Signed-off-by: Wenchao Xia xiaw...@linux.vnet.ibm.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- qemu-img-cmds.hx | 4 ++-- qemu-img.c | 44

[Qemu-devel] [PULL 29/48] qemu-iotests: Clean up spaces in usage output

2013-12-06 Thread Stefan Hajnoczi
From: Fam Zheng f...@redhat.com Whitespace changes to align columns. Signed-off-by: Fam Zheng f...@redhat.com Reviewed-by: Benoit Canet ben...@irqsave.net Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- tests/qemu-iotests/common | 16 1 file changed, 8 insertions(+), 8

[Qemu-devel] [PULL 18/48] raw-posix: add support for write_zeroes on XFS and block devices

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com The code is similar to the implementation of discard and write_zeroes with UNMAP. However, failure must be propagated up to block.c. The stale page cache problem can be reproduced as follows: # modprobe scsi-debug lbpws=1 lbprz=1 # ./qemu-io

[Qemu-devel] [PULL 37/48] qemu-img: add support for skipping zeroes in input during convert

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de we currently do not check if a sector is allocated during convert. This means if a sector is unallocated that we allocate a bounce buffer of zeroes, find out its zero later and do not write it in the best case. In the worst case this can lead to reading blocks from

[Qemu-devel] [PULL 24/48] qcow2: Zero-initialise first cluster for new images

2013-12-06 Thread Stefan Hajnoczi
From: Kevin Wolf kw...@redhat.com Strictly speaking, this is only required for has_zero_init() == false, but it's easy enough to just do a cluster-aligned write that is padded with zeros after the header. This fixes that after 'qemu-img create' header extensions are attempted to be parsed that

[Qemu-devel] [PULL 25/48] qemu-iotests: Add -c cache-mode option

2013-12-06 Thread Stefan Hajnoczi
From: Fam Zheng f...@redhat.com The option sets cache mode used in the tests. -nocache is changed to an alias to -c none, and internally passes -t none to qemu-io. Python scripts will make use of option this in the next commit. Signed-off-by: Fam Zheng f...@redhat.com Reviewed-by: Wenchao Xia

[Qemu-devel] [PULL 38/48] qemu-img: fix usage instruction for qemu-img convert

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de Reviewed-by: Eric Blake ebl...@redhat.com Reviewed-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- qemu-img.c | 1 - 1 file changed, 1 deletion(-) diff --git a/qemu-img.c

[Qemu-devel] [PULL 46/48] block: clean up bdrv_drain_all() throttling comments

2013-12-06 Thread Stefan Hajnoczi
Since cc0681c45430a1f1a4c2d06e9499b7775afc9a18 (block: Enable the new throttling code in the block layer.) bdrv_drain_all() no longer spins. The code used to look as follows: do { busy = qemu_aio_wait(); /* FIXME: We do not have timer support here, so this is effectively * a

[Qemu-devel] [PULL 26/48] qemu-iotests: Honour cache mode in iotests.py

2013-12-06 Thread Stefan Hajnoczi
From: Fam Zheng f...@redhat.com This will allow overriding cache mode from the -c mode option. Signed-off-by: Fam Zheng f...@redhat.com Reviewed-by: Wenchao Xia xiaw...@linux.vnet.ibm.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- tests/qemu-iotests/iotests.py | 3 ++- 1 file

[Qemu-devel] [PULL 47/48] aio: make aio_poll(ctx, true) block with no fds

2013-12-06 Thread Stefan Hajnoczi
This patch drops a special case where aio_poll(ctx, true) returns false instead of blocking if no file descriptors are waiting on I/O. Now it is possible to block in aio_poll() to wait for aio_notify(). This change eliminates busy waiting. bdrv_drain_all() used to rely on busy waiting to

[Qemu-devel] [PULL 28/48] qemu-iotests: Change default cache mode to writeback

2013-12-06 Thread Stefan Hajnoczi
From: Fam Zheng f...@redhat.com So that the tests can run faster. Signed-off-by: Fam Zheng f...@redhat.com Reviewed-by: Wenchao Xia xiaw...@linux.vnet.ibm.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- tests/qemu-iotests/common | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[Qemu-devel] [PULL 41/48] block/iscsi: set bs-bl.opt_transfer_length

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de Reviewed-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- block/iscsi.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/block/iscsi.c b/block/iscsi.c index 75d6b87..829d444

Re: [Qemu-devel] [PATCH v6 RESEND 3/5] hw/arm/digic: add timer support

2013-12-06 Thread Peter Maydell
On 4 December 2013 07:50, Antony Pavlov antonynpav...@gmail.com wrote: Signed-off-by: Antony Pavlov antonynpav...@gmail.com Reviewed-by: Peter Maydell peter.mayd...@linaro.org -- PMM

[Qemu-devel] [PULL 36/48] qemu-nbd: add doc for option -f

2013-12-06 Thread Stefan Hajnoczi
From: Wenchao Xia xiaw...@linux.vnet.ibm.com Signed-off-by: Wenchao Xia xiaw...@linux.vnet.ibm.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- qemu-nbd.c| 1 + qemu-nbd.texi | 2 ++ 2 files changed, 3 insertions(+) diff --git a/qemu-nbd.c b/qemu-nbd.c index fe6053c..136e8c9

Re: [Qemu-devel] [PATCH v6 RESEND 5/5] hw/arm/digic: add NOR ROM support

2013-12-06 Thread Peter Maydell
On 4 December 2013 07:50, Antony Pavlov antonynpav...@gmail.com wrote: Signed-off-by: Antony Pavlov antonynpav...@gmail.com --- hw/arm/digic_boards.c | 71 +++ 1 file changed, 71 insertions(+) Reviewed-by: Peter Maydell

[Qemu-devel] [PULL 32/48] qemu-nbd: support internal snapshot export

2013-12-06 Thread Stefan Hajnoczi
From: Wenchao Xia xiaw...@linux.vnet.ibm.com Now it is possible to directly export an internal snapshot, which can be used to probe the snapshot's contents without qemu-img convert. Signed-off-by: Wenchao Xia xiaw...@linux.vnet.ibm.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com ---

[Qemu-devel] [PULL 45/48] qcow2: use start_of_cluster() and offset_into_cluster() everywhere

2013-12-06 Thread Stefan Hajnoczi
From: Hu Tao hu...@cn.fujitsu.com Signed-off-by: Hu Tao hu...@cn.fujitsu.com Reviewed-by: Fam Zheng f...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- block/qcow2-cluster.c | 2 +- block/qcow2-refcount.c | 22 +++--- 2 files changed, 12 insertions(+), 12

[Qemu-devel] [PULL 39/48] block/iscsi: set bdi-cluster_size

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de this patch aims to set bdi-cluster_size to the internal page size of the iscsi target so that enabled callers can align requests properly. Reviewed-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan Hajnoczi

[Qemu-devel] [PULL 31/48] snapshot: distinguish id and name in load_tmp

2013-12-06 Thread Stefan Hajnoczi
From: Wenchao Xia xiaw...@linux.vnet.ibm.com Since later this function will be used so improve it. The only caller of it now is qemu-img, and it is not impacted by introduce function bdrv_snapshot_load_tmp_by_id_or_name() that call bdrv_snapshot_load_tmp() twice to keep old search logic.

Re: [Qemu-devel] [PATCH V4 4/7] qmp: Allow to change password on names block driver states.

2013-12-06 Thread Luiz Capitulino
On Fri, 06 Dec 2013 08:24:33 -0700 Eric Blake ebl...@redhat.com wrote: On 12/06/2013 07:27 AM, Luiz Capitulino wrote: On Thu, 5 Dec 2013 18:15:00 +0100 Benoît Canet ben...@irqsave.net wrote: -{ 'command': 'block_passwd', 'data': {'device': 'str', 'password': 'str'} } +{ 'command':

Re: [Qemu-devel] [PATCH 01/13] target-arm: A64: add support for conditional select

2013-12-06 Thread Richard Henderson
On 12/07/2013 01:45 AM, Peter Maydell wrote: On 5 December 2013 22:26, Richard Henderson r...@twiddle.net wrote: On 12/06/2013 10:51 AM, Peter Maydell wrote: +if (cond = 0x0e) { /* condition always */ +tcg_src = read_cpu_reg(s, rn, sf); +tcg_gen_mov_i64(tcg_rd, tcg_src);

Re: [Qemu-devel] [PATCH 02/13] target-arm: A64: add support for logical (shifted register)

2013-12-06 Thread Richard Henderson
On 12/06/2013 10:36 PM, Alex Bennée wrote: While correct, surely better to work with tcg and select on opc:invert to generate andc/orc/eqv? Shouldn't the TCG optimiser/back-end just be smart enough to figure it out? It seems clearer to express the tcg ops in terms of the front-end's

[Qemu-devel] [PATCH 1/4] pci: do not export pci_bus_reset

2013-12-06 Thread Paolo Bonzini
qbus_reset_all can be used instead. There is no semantic change because pcibus_reset returns 1 and takes care of the device tree traversal. Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- hw/pci/pci.c |8 ++-- hw/pci/pci_bridge.c |2 +- include/hw/pci/pci.h |1 - 3

Re: [Qemu-devel] [PATCH v6 RESEND 1/5] hw/arm: add very initial support for Canon DIGIC SoC

2013-12-06 Thread Peter Maydell
On 4 December 2013 07:50, Antony Pavlov antonynpav...@gmail.com wrote: DIGIC is Canon Inc.'s name for a family of SoC for digital cameras and camcorders. There is no publicly available specification for DIGIC chips. All information about DIGIC chip internals is based on reverse engineering

[Qemu-devel] [PATCH 2/4] pci: clean up resetting of IRQs

2013-12-06 Thread Paolo Bonzini
pci_device_reset will deassert the INTX pins, and this will make the irq_count array all-zeroes. Check that this is the case, and remove the existing loop which might even unsync irq_count and irq_state. Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- hw/pci/pci.c |7 --- 1 files

[Qemu-devel] [PATCH 0/4] qdev: switch reset to post-order, clean up PCI reset

2013-12-06 Thread Paolo Bonzini
PCI is handling resetting of its devices before the bus is reset, but this is only necessary because qdev is broken and usually does pre-order reset. Post-order is a much better definition. Drop the unnecessary flexibility that lets bus decide the reset order, convert to post-order, and make PCI

Re: [Qemu-devel] [PATCH v6 RESEND 0/5] add initial support for Canon DIGIC SoC

2013-12-06 Thread Peter Maydell
On 4 December 2013 07:50, Antony Pavlov antonynpav...@gmail.com wrote: [PATCH v6 RESEND 1/5] hw/arm: add very initial support for Canon [PATCH v6 RESEND 2/5] hw/arm/digic: prepare DIGIC-based boards [PATCH v6 RESEND 3/5] hw/arm/digic: add timer support [PATCH v6 RESEND 4/5] hw/arm/digic: add

[Qemu-devel] [PATCH 3/4] qdev: allow both pre- and post-order vists in qdev walking functions

2013-12-06 Thread Paolo Bonzini
Resetting should be done in post-order, not pre-order. However, qdev_walk_children and qbus_walk_children do not allow this. Fix it by adding two extra arguments to the functions. Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- hw/core/qdev.c | 45

Re: [Qemu-devel] [PATCH v2 02/13] target-arm: A64: add support for logical (shifted register)

2013-12-06 Thread Richard Henderson
On 12/07/2013 02:19 AM, Peter Maydell wrote: From: Alexander Graf ag...@suse.de Add support for the instructions described in C3.5.10 Logical (shifted register). We store the flags in the same locations as the 32 bit decoder. This is slightly awkward when calculating 64 bit results, but

Re: [Qemu-devel] [PATCH v2 01/13] target-arm: A64: add support for conditional select

2013-12-06 Thread Richard Henderson
On 12/07/2013 02:19 AM, Peter Maydell wrote: +tcg_rd = cpu_reg(s, rd); + +if (cond = 0x0e) { /* condition always */ +tcg_src = read_cpu_reg(s, rn, sf); +tcg_gen_mov_i64(tcg_rd, tcg_src); +} else { +/* OPTME: we could use movcond here, at the cost of

[Qemu-devel] [PATCH 3/7] hw/acpi: move typeinfo to the file end

2013-12-06 Thread Igor Mammedov
do so to avoid not necessary forward declarations and place typeinfo registration at the file end where it's usualy expected. Signed-off-by: Igor Mammedov imamm...@redhat.com --- hw/acpi/piix4.c | 80 +++--- 1 files changed, 40 insertions(+), 40

[Qemu-devel] [PATCH 5/7] pci/shpc: convert SHPC hotplug to use hotplug-device interface

2013-12-06 Thread Igor Mammedov
Split shpc_device_hotplug() into hotplug/unplug callbacks and register them as hotplug-device interface implementation of PCI_BRIDGE_DEV device. Replace pci_bus_hotplug() wiring with setting link on PCI BUS hotplug-device property to PCI_BRIDGE_DEV device. Signed-off-by: Igor Mammedov

[Qemu-devel] [PATCH 7/7] hw/pci: convert PCI bus to use hotplug-device interface.

2013-12-06 Thread Igor Mammedov
Signed-off-by: Igor Mammedov imamm...@redhat.com --- hw/pci/pci.c | 70 + include/hw/pci/pci.h | 10 -- include/hw/pci/pci_bus.h |2 - 3 files changed, 51 insertions(+), 31 deletions(-) diff --git a/hw/pci/pci.c

[Qemu-devel] [PATCH v2 2/3] X86, mpx: Intel MPX CPU feature definition

2013-12-06 Thread Qiaowei Ren
This patch defines Intel MPX CPU feature. Signed-off-by: Qiaowei Ren qiaowei@intel.com Signed-off-by: Xudong Hao xudong@intel.com Signed-off-by: Liu Jinsong jinsong@intel.com --- arch/x86/include/asm/cpufeature.h |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git

[Qemu-devel] [PATCH v2 1/3] x86, mpx: add documentation on Intel MPX

2013-12-06 Thread Qiaowei Ren
This patch adds the Documentation/intel_mpx.txt file with some information about Intel MPX. Signed-off-by: Qiaowei Ren qiaowei@intel.com Signed-off-by: Xudong Hao xudong@intel.com Signed-off-by: Liu Jinsong jinsong@intel.com --- Documentation/x86/intel_mpx.txt | 76

Re: [Qemu-devel] [PATCH v8 0/6] target-arm: Add support for VSEL and VMIN/MAXNM.

2013-12-06 Thread Peter Maydell
On 4 December 2013 11:54, Will Newton will.new...@linaro.org wrote: This series adds support for three new instructions added in ARMv8 - VSEL, VMINNM and VMAXNM. Will Newton (6): target-arm: Move call to disas_vfp_insn out of disas_coproc_insn. target-arm: Implement ARMv8 VSEL

[Qemu-devel] [PATCH 6/7] pci/pcie: convert PCIE hotplug to use hotplug-device interface

2013-12-06 Thread Igor Mammedov
Split pcie_cap_slot_hotplug() into hotplug/unplug callbacks and register them as hotplug-device interface implementation of PCIE_SLOT device. Replace pci_bus_hotplug() wiring with setting link on PCI BUS hotplug-device property to PCI_BRIDGE_DEV device. Signed-off-by: Igor Mammedov

[Qemu-devel] [PATCH v2 3/3] X86, mpx: Intel MPX xstate feature definition

2013-12-06 Thread Qiaowei Ren
This patch defines xstate feature and extends struct xsave_hdr_struct to support Intel MPX. Signed-off-by: Qiaowei Ren qiaowei@intel.com Signed-off-by: Xudong Hao xudong@intel.com Signed-off-by: Liu Jinsong jinsong@intel.com --- arch/x86/include/asm/processor.h | 12

[Qemu-devel] [PULL 44/48] qemu-img: decrease progress update interval on convert

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de when doing very large jobs updating the progress only every 2% is too rare. Signed-off-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- qemu-img.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qemu-img.c

Re: [Qemu-devel] [PATCH v3 0/2] Intel MPX feature support at Qemu

2013-12-06 Thread H. Peter Anvin
On 12/06/2013 08:27 AM, Liu, Jinsong wrote: Eric Blake wrote: On 12/06/2013 07:06 AM, Liu, Jinsong wrote: Intel has released Memory Protection Extensions (MPX) recently. Please refer to http://download-software.intel.com/sites/default/files/319433-015.pdf These 2 patches are version2 to

[Qemu-devel] [RFC PATCH 00/19] block: Support for 512b-on-4k emulation

2013-12-06 Thread Kevin Wolf
This patch series adds code to the block layer that allows performing I/O requests in smaller granularities than required by the host backend (most importantly, O_DIRECT restrictions). It achieves this for reads by rounding the request to host-side block boundary, and for writes by performing a

[Qemu-devel] [RFC PATCH 05/19] raw: Probe required direct I/O alignment

2013-12-06 Thread Kevin Wolf
From: Paolo Bonzini pbonz...@redhat.com Add a bs-request_alignment field that contains the required offset/length alignment for I/O requests and fill it in the raw block drivers. Use ioctls if possible, else see what alignment it takes for O_DIRECT to succeed. While at it, also expose the memory

[Qemu-devel] [RFC PATCH 02/19] block: Detect unaligned length in bdrv_qiov_is_aligned()

2013-12-06 Thread Kevin Wolf
For an O_DIRECT request to succeed, it's not only necessary that all base addresses in the qiov are aligned, but also that each lengh in it is aligned. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/block.c b/block.c index

[Qemu-devel] [RFC PATCH 03/19] block: Don't use guest sector size for qemu_blockalign()

2013-12-06 Thread Kevin Wolf
bs-buffer_alignment is set by the device emulation and contains the logical block size of the guest device. This isn't something that the block layer should know, and even less something to use for determining the right alignment of buffers to be used for the host. The new function

[Qemu-devel] [RFC PATCH 01/19] qemu_memalign: Allow small alignments

2013-12-06 Thread Kevin Wolf
The functions used by qemu_memalign() require an alignment that is at least sizeof(void*). Adjust it if it is too small. Signed-off-by: Kevin Wolf kw...@redhat.com --- util/oslib-posix.c | 5 + 1 file changed, 5 insertions(+) diff --git a/util/oslib-posix.c b/util/oslib-posix.c index

[Qemu-devel] [RFC PATCH 07/19] block: Introduce bdrv_co_do_preadv()

2013-12-06 Thread Kevin Wolf
Similar to bdrv_pread(), which aligns byte-aligned request to 512 byte sectors, bdrv_co_do_preadv() takes a byte-aligned request and aligns it to the alignment specified in bs-request_alignment. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 63

[Qemu-devel] [RFC PATCH 04/19] block: rename buffer_alignment to guest_block_size

2013-12-06 Thread Kevin Wolf
From: Paolo Bonzini pbonz...@redhat.com The alignment field is now set to the value that is promised to the guest, rather than required by the host. The next patches will make QEMU aware of the host-provided values, so make this clear. The alignment is also not about memory buffers, but about

[Qemu-devel] [RFC PATCH 08/19] block: Introduce bdrv_aligned_pwritev()

2013-12-06 Thread Kevin Wolf
This separates the part of bdrv_co_do_writev() that needs to happen before the request is modified to match the backend alignment, and a part that needs to be executed afterwards and passes the request to the BlockDriver. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 62

[Qemu-devel] [RFC PATCH 19/19] block: Make bdrv_pwrite() a bdrv_prwv_co() wrapper

2013-12-06 Thread Kevin Wolf
Instead of implementing the alignment adjustment here, use the now existing functionality of bdrv_co_do_pwritev(). Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 64 +--- 1 file changed, 9 insertions(+), 55 deletions(-) diff

[Qemu-devel] [RFC PATCH 11/19] block: Switch BdrvTrackedRequest to byte granularity

2013-12-06 Thread Kevin Wolf
Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 52 +++ block/backup.c| 7 ++- include/block/block_int.h | 4 ++-- 3 files changed, 42 insertions(+), 21 deletions(-) diff --git a/block.c b/block.c index

Re: [Qemu-devel] [PATCH 1/7] define hotplug interface

2013-12-06 Thread Paolo Bonzini
Il 06/12/2013 18:03, Igor Mammedov ha scritto: Provide generic hotplug interface for devices. Intended for replacing hotplug mechanism used by PCI/PCIE/SHPC code. Signed-off-by: Igor Mammedov imamm...@redhat.com --- it's scsi-bus like interface, but abstracted from bus altogether since

[Qemu-devel] [RFC PATCH 10/19] block: Introduce bdrv_co_do_pwritev()

2013-12-06 Thread Kevin Wolf
This is going to become the bdrv_co_do_preadv() equivalent for reads. In this patch, however, just a function taking byte offsets is created, it doesn't align anything yet. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 23 +-- 1 file changed, 17 insertions(+), 6

[Qemu-devel] [RFC PATCH 12/19] block: Allow waiting for overlapping requests between begin/end

2013-12-06 Thread Kevin Wolf
Previously, it was not possible to use wait_for_overlapping_requests() between tracked_request_begin()/end() because it would wait for itself. Ignore the current request in the overlap check and run more of the bdrv_co_do_preadv/pwritev code with a BdrvTrackedRequest present. Signed-off-by:

[Qemu-devel] [RFC PATCH 13/19] block: Make zero-after-EOF work with larger alignment

2013-12-06 Thread Kevin Wolf
Odd file sizes could make bdrv_aligned_preadv() shorten the request in non-aligned ways. Fix it by rounding to the required alignment instead of 512 bytes. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/block.c

[Qemu-devel] [RFC PATCH 15/19] block: Make overlap range for serialisation dynamic

2013-12-06 Thread Kevin Wolf
Copy on Read wants to serialise with all requests touching the same cluster, so wait_serialising_requests() rounded to cluster boundaries. Other users like alignment RMW will have different requirements, though (requests touching the same sector), so make it dynamic. Signed-off-by: Kevin Wolf

Re: [Qemu-devel] [PATCH 0/7] Refactor PCI/SHPC/PCIE hotplug to use a more generic hotplug API

2013-12-06 Thread Paolo Bonzini
Il 06/12/2013 18:03, Igor Mammedov ha scritto: Series is replacement for a more simple attempt to generalize hotplug API http://lists.gnu.org/archive/html/qemu-devel/2013-11/msg02529.html promted by Paolo in this patch review. -- Refactor PCI specific hotplug API to a more generic/reusable

[Qemu-devel] [RFC PATCH 14/19] block: Generalise and optimise COR serialisation

2013-12-06 Thread Kevin Wolf
Change the API so that specific requests can be marked serialising. Only these requests are checked for overlaps then. This means that during a Copy on Read operation, not all requests overlapping other requests are serialised any more, but only those that actually overlap with the specific COR

[Qemu-devel] [RFC PATCH 17/19] block: Change coroutine wrapper to byte granularity

2013-12-06 Thread Kevin Wolf
Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 48 ++-- 1 file changed, 26 insertions(+), 22 deletions(-) diff --git a/block.c b/block.c index 23ad09d..514a5c2 100644 --- a/block.c +++ b/block.c @@ -69,11 +69,11 @@ static int coroutine_fn

Re: [Qemu-devel] [PATCH 7/7] hw/pci: convert PCI bus to use hotplug-device interface.

2013-12-06 Thread Paolo Bonzini
Il 06/12/2013 18:03, Igor Mammedov ha scritto: +hotplug_dev = DEVICE(object_property_get_link(OBJECT(bus), hotplug-device, + local_err)); +if (error_is_set(local_err)) { +goto error_exit; +} +if (hotplug_dev) { +

Re: [Qemu-devel] [PATCH 3/3] X86, mpx: Intel MPX xstate feature definition

2013-12-06 Thread H. Peter Anvin
On 12/06/2013 05:46 AM, Borislav Petkov wrote: I'm guessing this and the struct lwp_struct above is being added so that you can have the LWP XSAVE area size? If so, you don't need it: LWP XSAVE area is 128 bytes at offset 832 according to my manuals so I'd guess having a u8 lwp_area[128]

Re: [Qemu-devel] [PATCH v2 3/3] X86, mpx: Intel MPX xstate feature definition

2013-12-06 Thread Paolo Bonzini
Il 07/12/2013 01:20, Qiaowei Ren ha scritto: This patch defines xstate feature and extends struct xsave_hdr_struct to support Intel MPX. Signed-off-by: Qiaowei Ren qiaowei@intel.com Signed-off-by: Xudong Hao xudong@intel.com Signed-off-by: Liu Jinsong jinsong@intel.com ---

Re: [Qemu-devel] [PATCH v2 01/13] target-arm: A64: add support for conditional select

2013-12-06 Thread Peter Maydell
On 6 December 2013 16:59, Richard Henderson r...@twiddle.net wrote: Sorry for missing this in the first round: For the silly corner case of Rd == XZR, tcg_rd is dead after the branch. We could either move the tcg_rd assignment down into each basic block with the assignment to tcg_src, or

[Qemu-devel] [PULL 40/48] block: add opt_transfer_length to BlockLimits

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de Reviewed-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Peter Lieven p...@kamp.de Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- include/block/block_int.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/block/block_int.h

[Qemu-devel] [PULL 20/48] scsi-disk: catch write protection errors in UNMAP

2013-12-06 Thread Stefan Hajnoczi
From: Paolo Bonzini pbonz...@redhat.com This is the same that is already done for WRITE SAME. Signed-off-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- hw/scsi/scsi-disk.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/hw/scsi/scsi-disk.c

Re: [Qemu-devel] [PATCH] x86: only allow real mode to access 32bit without LMA

2013-12-06 Thread Richard Henderson
On 12/07/2013 01:52 AM, Alexander Graf wrote: When we're running in non-64bit mode with qemu-system-x86_64 we can still end up with virtual addresses that are above the 32bit boundary if a segment offset is set up. GNU Hurd does exactly that. It sets the segment offset to 0x8000 and

Re: [Qemu-devel] [PATCH] tcg: Use bitmaps for free temporaries

2013-12-06 Thread Richard Henderson
Ping. r~ On 11/19/2013 07:57 PM, Richard Henderson wrote: Ping? r~ On 09/20/2013 05:58 AM, Richard Henderson wrote: We previously allocated 32-bits per temp for the next_free_temp entry. We now allocate 4 bits per temp across the 4 bitmaps. Using a linked list meant that if a

Re: [Qemu-devel] [PATCH] net: QEMU_NET_PACKET_FLAG_MORE introduced

2013-12-06 Thread Stefan Weil
Am 06.12.2013 15:44, schrieb Vincenzo Maffione: This patch extends the frontend-backend interface so that it is possible to pass a new flag (QEMU_NET_PACKET_FLAG_MORE) when sending a packet to the other peer. The new flag acts as a hint for the receiving peer, which can accumulate a batch of

Re: [Qemu-devel] [PATCH v2] SPARC: Fix LEON3 power down instruction

2013-12-06 Thread Richard Henderson
On 11/27/2013 08:50 PM, Sebastian Huber wrote: Synchronize the program counter before the power down helper call otherwise interrupts will return to the wrong context. Signed-off-by: Sebastian Huber sebastian.hu...@embedded-brains.de --- target-sparc/translate.c |1 + 1 files changed,

Re: [Qemu-devel] [RFC PATCH 05/19] raw: Probe required direct I/O alignment

2013-12-06 Thread Paolo Bonzini
Il 06/12/2013 18:22, Kevin Wolf ha scritto: @@ -1227,6 +1288,7 @@ static BlockDriver bdrv_file = { .bdrv_aio_writev = raw_aio_writev, .bdrv_aio_flush = raw_aio_flush, .bdrv_aio_discard = raw_aio_discard, +.bdrv_opt_mem_align = raw_opt_mem_align, .bdrv_truncate =

[Qemu-devel] [RFC PATCH 18/19] block: Make bdrv_pread() a bdrv_prwv_co() wrapper

2013-12-06 Thread Kevin Wolf
Instead of implementing the alignment adjustment here, use the now existing functionality of bdrv_co_do_preadv(). Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 49 + 1 file changed, 13 insertions(+), 36 deletions(-) diff --git a/block.c

Re: [Qemu-devel] [PATCH v2 4/4] tcg/optimize: add known-zero bits compute for load ops

2013-12-06 Thread Richard Henderson
On 09/10/2013 05:27 AM, Aurelien Jarno wrote: +CASE_OP_32_64(ld8u): +case INDEX_op_qemu_ld8u: +mask = 0xff; +break; +CASE_OP_32_64(ld16u): +case INDEX_op_qemu_ld16u: +mask = 0x; +break; +case

Re: [Qemu-devel] [PATCH v2 2/4] tcg/optimize: fix known-zero bits optimization

2013-12-06 Thread Richard Henderson
On 09/10/2013 05:27 AM, Aurelien Jarno wrote: Known-zero bits optimization is a great idea that helps to generate more optimized code. However the current implementation only works in very few cases as the computed mask is not saved. Fix this to make it really working. Cc: Richard

Re: [Qemu-devel] [PATCH v2 1/4] tcg/optimize: fix known-zero bits for right shift ops

2013-12-06 Thread Richard Henderson
On 09/10/2013 05:27 AM, Aurelien Jarno wrote: 32-bit versions of sar and shr ops should not propagate known-zero bits from the unused 32 high bits. For sar it could even lead to wrong code being generated. Cc: Richard Henderson r...@twiddle.net Cc: Paolo Bonzini pbonz...@redhat.com Cc:

Re: [Qemu-devel] [PATCH v2 3/4] tcg/optimize: improve known-zero bits for 32-bit ops

2013-12-06 Thread Richard Henderson
On 09/10/2013 05:27 AM, Aurelien Jarno wrote: The shl_i32 op might set some bits of the unused 32 high bits of the mask. Fix that by clearing the unused 32 high bits for all 32-bit ops except load/store which operate on tl values. Cc: Richard Henderson r...@twiddle.net Cc: Paolo Bonzini

Re: [Qemu-devel] [RFC PATCH 00/19] block: Support for 512b-on-4k emulation

2013-12-06 Thread Paolo Bonzini
Il 06/12/2013 18:22, Kevin Wolf ha scritto: This patch series adds code to the block layer that allows performing I/O requests in smaller granularities than required by the host backend (most importantly, O_DIRECT restrictions). It achieves this for reads by rounding the request to host-side

Re: [Qemu-devel] [PATCH v2 3/3] X86, mpx: Intel MPX xstate feature definition

2013-12-06 Thread H. Peter Anvin
On 12/06/2013 09:35 AM, Paolo Bonzini wrote: Sorry for the back-and-forth, but I think this and the removal of XSTATE_FLEXIBLE (perhaps XSTATE_LAZY?) makes your v2 worse than v1. Since Peter already said the same, please undo these changes. Also, how is XSTATE_EAGER used? Should MPX be

[Qemu-devel] [PATCH 4/4] qdev: switch reset to post-order

2013-12-06 Thread Paolo Bonzini
Post-order is the only sensible direction for the reset signals. For example, suppose pre-order is used and the parent has some data structures that cache children state (for example a list of active requests). When the reset method is invoked on the parent, these caches could be in any state.

[Qemu-devel] [RFC PATCH 06/19] block: Introduce bdrv_aligned_preadv()

2013-12-06 Thread Kevin Wolf
This separates the part of bdrv_co_do_readv() that needs to happen before the request is modified to match the backend alignment, and a part that needs to be executed afterwards and passes the request to the BlockDriver. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c | 61

Re: [Qemu-devel] [PATCH 01/13] target-arm: A64: add support for conditional select

2013-12-06 Thread Peter Maydell
On 6 December 2013 16:44, Richard Henderson r...@twiddle.net wrote: On 12/07/2013 01:45 AM, Peter Maydell wrote: On 5 December 2013 22:26, Richard Henderson r...@twiddle.net wrote: On 12/06/2013 10:51 AM, Peter Maydell wrote: +if (cond = 0x0e) { /* condition always */ +tcg_src =

[Qemu-devel] [PULL 42/48] qemu-img: dynamically adjust iobuffer size during convert

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de since the convert process is basically a sync operation it might be benificial in some case to change the hardcoded I/O buffer size to a greater value. This patch increases the I/O buffer size if the output driver advertises an optimal transfer length or discard

[Qemu-devel] [PULL 23/48] block: Close backing file early in bdrv_img_create

2013-12-06 Thread Stefan Hajnoczi
From: Max Reitz mre...@redhat.com Leaving the backing file open although it is not needed anymore can cause problems if it is opened through a block driver which allows exclusive access only and if the create function of the block driver used for the top image (the one being created) tries to

[Qemu-devel] [PATCH 4/7] acpi/piix4pm: convert ACPI PCI hotplug to use hotplug-device interface

2013-12-06 Thread Igor Mammedov
Split piix4_device_hotplug() into hotplug/unplug callbacks and register them as hotplug-device interface implementation of PIIX4_PM device. Replace pci_bus_hotplug() wiring with setting link on PCI BUS hotplug-device property to PIIX4_PM device. Signed-off-by: Igor Mammedov imamm...@redhat.com

[Qemu-devel] [PULL 43/48] qemu-img: round down request length to an aligned sector

2013-12-06 Thread Stefan Hajnoczi
From: Peter Lieven p...@kamp.de this patch shortens requests to end at an aligned sector so that the next request starts aligned. [Squashed Peter's fix for bdrv_get_info() failure discussed on the mailing list. --Stefan] Reviewed-by: Paolo Bonzini pbonz...@redhat.com Signed-off-by: Peter Lieven

[Qemu-devel] [PULL 35/48] qemu-iotests: add test for snapshot in qemu-img convert

2013-12-06 Thread Stefan Hajnoczi
From: Wenchao Xia xiaw...@linux.vnet.ibm.com Signed-off-by: Wenchao Xia xiaw...@linux.vnet.ibm.com Signed-off-by: Stefan Hajnoczi stefa...@redhat.com --- tests/qemu-iotests/058 | 19 ++- tests/qemu-iotests/058.out | 12 2 files changed, 30 insertions(+), 1

[Qemu-devel] [RFC PATCH 09/19] block: write: Handle COR dependency after I/O throttling

2013-12-06 Thread Kevin Wolf
First waiting for all COR requests to complete and calling the throttling function afterwards means that the request could be delayed and we still need to wait for the COR request even if it was issued only after the throttled write request. Signed-off-by: Kevin Wolf kw...@redhat.com --- block.c

[Qemu-devel] [PATCH] hw/arm/highbank: Simplify code (memory region in device state)

2013-12-06 Thread Stefan Weil
The memory region can be included by value instead of by reference in the device state (like it is done in other SoCs). Signed-off-by: Stefan Weil s...@weilnetz.de --- hw/arm/highbank.c |7 +++ 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/hw/arm/highbank.c

<    1   2   3   >