Re: [Qemu-devel] [Qemu-ppc] [PULL 04/12] ppc: tlbie, tlbia and tlbisync are HV only

2016-06-01 Thread Mark Cave-Ayland
On 01/06/16 03:15, David Gibson wrote: > On Tue, May 31, 2016 at 11:28:49PM +0100, Mark Cave-Ayland wrote: >> On 31/05/16 01:41, David Gibson wrote: >> >>> From: Benjamin Herrenschmidt >>> >>> Not that anything remotely recent supports tlbia but ... >>> >>> Signed-off-by: Benjamin Herrenschmidt

Re: [Qemu-devel] [PULL 03/31] hw/char: QOM'ify escc.c

2016-06-01 Thread Mark Cave-Ayland
On 01/06/16 04:06, xiaoqiang zhao wrote: >> 在 2016年6月1日,06:13,Mark Cave-Ayland 写道: >> >>> On 27/05/16 11:06, Paolo Bonzini wrote: >>> >>> From: xiaoqiang zhao >>> >>> * Drop the old SysBus init function and use instance_init >>> * Call qemu_chr_add_handlers in the realize callback >>> >>> Signed

Re: [Qemu-devel] [PULL 03/31] hw/char: QOM'ify escc.c

2016-06-01 Thread xiaoqiang zhao
在 2016年06月01日 15:04, Mark Cave-Ayland 写道: On 01/06/16 04:06, xiaoqiang zhao wrote: 在 2016年6月1日,06:13,Mark Cave-Ayland 写道: On 27/05/16 11:06, Paolo Bonzini wrote: From: xiaoqiang zhao * Drop the old SysBus init function and use instance_init * Call qemu_chr_add_handlers in the realize ca

[Qemu-devel] [PATCH] block/raw-posix: Fix error_report of mounting message

2016-06-01 Thread Wei Jiangang
Use a single error_printf to replace triple error_report. Signed-off-by: Wei Jiangang --- block/raw-posix.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/block/raw-posix.c b/block/raw-posix.c index a4f5a1b..141b01a 100644 --- a/block/raw-posix.c +++ b/block/raw-p

Re: [Qemu-devel] [PATCH] block/raw-posix: Fix error_report of mounting message

2016-06-01 Thread Fam Zheng
On Wed, 06/01 15:08, Wei Jiangang wrote: > Use a single error_printf to replace triple error_report. > > Signed-off-by: Wei Jiangang > --- > block/raw-posix.c | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > > diff --git a/block/raw-posix.c b/block/raw-posix.c > index a4f5a1

Re: [Qemu-devel] [PATCH v2 3/3] qapi: Fix memleak in string visitors on int lists

2016-06-01 Thread Markus Armbruster
Eric Blake writes: > Commit 7f8f9ef1 introduced the ability to store a list of > integers as a sorted list of ranges, but when merging ranges, > it leaks one or more ranges. It was also using range_get_last() > incorrectly within range_compare() (a range is a start/end pair, > but range_get_last

[Qemu-devel] [PATCH] hw/char: QOM'ify escc.c (fix)

2016-06-01 Thread xiaoqiang zhao
The previous commit e7c9136977cb99c6eb52c9139f7b8d8b5fa87db9 (hw/char: QOM'ify escc.c) cause qemu-system-ppc/ppc64 OpenBIOS to freeze on startup, this commit fix it. Signed-off-by: xiaoqiang zhao --- hw/char/escc.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/

Re: [Qemu-devel] [PATCH] docs: Fix a couple of typos in throttle.txt

2016-06-01 Thread Michael Tokarev
30.05.2016 13:00, Alberto Garcia wrote: > On Mon 30 May 2016 08:49:18 AM CEST, Changlong Xie wrote: - Water leaks from the bucket at a rate of 100 IOPS. - Water can be added to the bucket at a rate of 2000 IOPS. - The size of the bucket is 2000 x 60 = 12 - - If

Re: [Qemu-devel] [PATCH] docs/multi-thread-compression: Fix wrong command string

2016-06-01 Thread Michael Tokarev
23.05.2016 12:43, Wei Jiangang wrote: > s/info_migrate_capabilities/info migrate_capabilities Applied to -trivial, thanks! /mjt

Re: [Qemu-devel] [PATCH] host-utils: Prefer 'false' for bool type

2016-06-01 Thread Michael Tokarev
31.05.2016 21:33, Eric Blake wrote: > Mixing '0' and 'bool' looks stupid. Applied to -trivial, thanks! /mjt

Re: [Qemu-devel] [PATCH v6 02/11] fix some coding style problems

2016-06-01 Thread Markus Armbruster
Cao jin writes: > It has: > 1. More newlines make the code block well separated. > 2. Add more comments for msi_init. > 3. Fix a indentation in vmxnet3.c. > 4. ioh3420 & xio3130_downstream: put PCI Express capability init function >together, make it more readable. > > cc: Dmitry Fleytman > c

Re: [Qemu-devel] [PATCH] block: Drop bdrv_ioctl_bh_cb

2016-06-01 Thread Paolo Bonzini
On 01/06/2016 03:52, Fam Zheng wrote: > Similar to the "!drv || !drv->bdrv_aio_ioctl" case above, here it is > okay to set co.ret and return. As pointed out by Paolo, a BH will be > created as necessary by the caller (bdrv_co_maybe_schedule_bh). > Besides, as pointed out by Kevin, "data" was leak

Re: [Qemu-devel] [PATCH qemu v16 04/19] vmstate: Define VARRAY with VMS_ALLOC

2016-06-01 Thread Paolo Bonzini
On 01/06/2016 04:29, Alexey Kardashevskiy wrote: > On 27/05/16 17:54, Alexey Kardashevskiy wrote: >> On 04/05/16 16:52, Alexey Kardashevskiy wrote: >>> This allows dynamic allocation for migrating arrays. >>> >>> Already existing VMSTATE_VARRAY_UINT32 requires an array to be >>> pre-allocated, ho

Re: [Qemu-devel] [PATCH v6 04/11] megasas: Fix

2016-06-01 Thread Markus Armbruster
Title "megasas: Fix" is no good, possibly an editing accident. Suggest something like "megasas: Fix check for msi_init() failure" Cao jin writes: > msi_init returns non-zero value on both failure and success. > > cc: Hannes Reinecke > cc: Paolo Bonzini > cc: Marcel Apfelbaum > > Reviewed-by:

Re: [Qemu-devel] [PATCH v7 04/15] Makefile: Rules for docker testing

2016-06-01 Thread Paolo Bonzini
On 01/06/2016 06:25, Fam Zheng wrote: > +CUR_TIME := $(shell date +%Y-%m-%d-%H.%M.%S.) > +# Makes the definition constant after the first expansion > +DOCKER_SRC_COPY = $(eval DOCKER_SRC_COPY := > /tmp/docker-src.$(CUR_TIME))$(DOCKER_SRC_COPY) > + > +$(DOCKER_SRC_COPY): > + @mkdir $@ > +

Re: [Qemu-devel] [PATCH v7 04/15] Makefile: Rules for docker testing

2016-06-01 Thread Paolo Bonzini
On 01/06/2016 06:25, Fam Zheng wrote: > +# Use a global constant ccache directory to speed up repetitive builds > +DOCKER_CCACHE_DIR := /var/tmp/qemu-docker-ccache Same here, use $HOME/.cache/qemu-docker-ccache instead. Do you need a mkdir -p? Paolo

Re: [Qemu-devel] [PATCH 4/6 Resend] Vhost-pci RFC: Detailed Description in the Virtio Specification Format

2016-06-01 Thread Xiao Guangrong
On 05/29/2016 04:11 PM, Wei Wang wrote: Signed-off-by: Wei Wang --- Details | 324 1 file changed, 324 insertions(+) create mode 100644 Details diff --git a/Details b/Details new file mode 100644 index 000..4ea2252 ---

[Qemu-devel] [PATCH v8 01/17] pci: fix unaligned access in pci_xxx_quad()

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Replace legacy cpu_to_le64w()/le64_to_cpup() calls with stq_le_p()/ldq_le_p(). Motivation for this modification is that follow up patches add utility function pcie_dev_ser_num_init() for PCIe DSN capability creation which uses pci_set_quad() with a misaligned offset. Signe

[Qemu-devel] [PATCH v8 02/17] msix: make msix_clr_pending() visible for clients

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman This function will be used by e1000e device code. Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- hw/pci/msix.c | 2 +- include/hw/pci/msix.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/p

[Qemu-devel] [PATCH v8 06/17] vmxnet3: Use generic function for DSN capability definition

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- hw/net/vmxnet3.c | 12 +--- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/hw/net/vmxnet3.c b/hw/net/vmxnet3.c index 20f26b7..586e915 100644 --- a/hw/net

[Qemu-devel] [PATCH v8 00/17] Introduce Intel 82574 GbE Controller Emulation (e1000e)

2016-06-01 Thread Dmitry Fleytman
Hello All, This is v8 of e1000e series. For convenience, the same patches are available at: https://github.com/daynix/qemu-e1000e/tree/e1000e-submit-v8 Series Reviewed-by: Michael S. Tsirkin Best regards, Dmitry. Changes since v7: 1. Fixed broken ETH macros reported by Jason 2. Rebase to the

[Qemu-devel] [PATCH v8 13/17] vmxnet3: Use pci_dma_* API instead of cpu_physical_memory_*

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman To make this device and network packets abstractions ready for IOMMU. Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- hw/net/net_tx_pkt.c | 16 +++- hw/net/net_tx_pkt.h | 5 +++-- hw/net/vmxnet3.c| 51 +

[Qemu-devel] [PATCH v8 03/17] pci: Introduce define for PM capability version 1.1

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- include/hw/pci/pci_regs.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/hw/pci/pci_regs.h b/include/hw/pci/pci_regs.h index ba8cbe9..7a83142 100644 --- a/includ

[Qemu-devel] [PATCH v8 04/17] pcie: Add support for PCIe CAP v1

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Added support for PCIe CAP v1, while reusing some of the existing v2 infrastructure. Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- hw/pci/pcie.c | 84 -- include/hw

[Qemu-devel] [PATCH v8 05/17] pcie: Introduce function for DSN capability creation

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- hw/pci/pcie.c | 10 ++ include/hw/pci/pcie.h | 1 + 2 files changed, 11 insertions(+) diff --git a/hw/pci/pcie.c b/hw/pci/pcie.c index 24cfc3b..9599fde 100644

[Qemu-devel] [PATCH v8 17/17] e1000e: Introduce qtest for e1000e device

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- tests/Makefile | 3 + tests/e1000e-test.c | 479 2 files changed, 482 insertions(+) create mode 100644 tests/e1000e

[Qemu-devel] [PATCH v8 14/17] e1000_regs: Add definitions for Intel 82574-specific bits

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- hw/net/e1000_regs.h | 345 +++- 1 file changed, 342 insertions(+), 3 deletions(-) diff --git a/hw/net/e1000_regs.h b/hw/net/e10

[Qemu-devel] [PATCH v8 07/17] net: Introduce Toeplitz hash calculator

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- include/net/checksum.h | 45 + 1 file changed, 45 insertions(+) diff --git a/include/net/checksum.h b/include/net/checksum.h index

[Qemu-devel] [PATCH v8 08/17] net: Add macros for MAC address tracing

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman These macros will be used by future commits introducing e1000e device emulation and by vmxnet3 tracing code. Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- include/net/net.h | 5 + 1 file changed, 5 insertions(+) diff

[Qemu-devel] [PATCH v8 09/17] vmxnet3: Use common MAC address tracing macros

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- hw/net/vmxnet3.c | 8 hw/net/vmxnet_debug.h | 3 --- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/hw/net/vmxnet3.c b/hw/net/vmxnet3.c index 586e

[Qemu-devel] [PATCH v8 15/17] e1000: Move out code that will be reused in e1000e

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Code that will be shared moved to a separate files. Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- MAINTAINERS| 5 + hw/net/Makefile.objs | 2 +- hw/net/e1000.c | 411 +++--

[Qemu-devel] [PATCH v8 11/17] rtl8139: Move more TCP definitions to common header

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman Signed-off-by: Dmitry Fleytman Signed-off-by: Leonid Bloch Reviewed-by: Michael S. Tsirkin --- hw/net/rtl8139.c | 5 - include/net/eth.h | 8 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/hw/net/rtl8139.c b/hw/net/rtl8139.c index 1e5ec14..5

Re: [Qemu-devel] [PATCH v6 07/11] intel-hda: change msi property type

2016-06-01 Thread Markus Armbruster
Cao jin writes: >>From uint32 to enum OnOffAuto. > > cc: Gerd Hoffmann > cc: Michael S. Tsirkin > cc: Markus Armbruster > cc: Marcel Apfelbaum > > Signed-off-by: Cao jin > --- > hw/audio/intel-hda.c | 7 --- > 1 file changed, 4 insertions(+), 3 deletions(-) > > diff --git a/hw/audio/int

[Qemu-devel] [PATCH v8 10/17] net_pkt: Name vmxnet3 packet abstractions more generic

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman This patch drops "vmx" prefix from packet abstractions names to emphasize the fact they are generic and not tied to any specific network device. These abstractions will be reused by e1000e emulation implementation introduced by following patches so their names need generali

Re: [Qemu-devel] [PATCH v6 06/11] usb xhci: change msi/msix property type

2016-06-01 Thread Markus Armbruster
Cao jin writes: >>From bit to enum OnOffAuto > > cc: Gerd Hoffmann > cc: Michael S. Tsirkin > cc: Markus Armbruster > cc: Marcel Apfelbaum > > Signed-off-by: Cao jin > --- > hw/usb/hcd-xhci.c | 16 +--- > 1 file changed, 9 insertions(+), 7 deletions(-) > > diff --git a/hw/usb/hc

Re: [Qemu-devel] [PATCH] fix xen hvm direct kernel boot

2016-06-01 Thread Chun Yan Liu
>>> On 5/31/2016 at 12:10 AM, in message , Stefano Stabellini wrote: > On Fri, 29 Apr 2016, Chunyan Liu wrote: > > Since commit a1666142: acpi-build: make ROMs RAM blocks resizeable, > > xen HVM direct kernel boot failed. Xen HVM direct kernel boot will > > insert a linuxboot.bin or multiboo

[Qemu-devel] [PATCH v8 12/17] net_pkt: Extend packet abstraction as required by e1000e functionality

2016-06-01 Thread Dmitry Fleytman
From: Dmitry Fleytman This patch extends the TX/RX packet abstractions with features that will be used by the e1000e device implementation. Changes are: 1. Support iovec lists for RX buffers 2. Deeper RX packets parsing 3. Loopback option for TX packets 4. Extended VLAN headers handling

Re: [Qemu-devel] [PATCH v6 02/11] fix some coding style problems

2016-06-01 Thread Cao jin
On 06/01/2016 04:09 PM, Markus Armbruster wrote: Cao jin writes: It has: 1. More newlines make the code block well separated. 2. Add more comments for msi_init. 3. Fix a indentation in vmxnet3.c. 4. ioh3420 & xio3130_downstream: put PCI Express capability init function together, make it

Re: [Qemu-devel] [PATCH v2 0/2] Let PKGVERSION include the "git describe" output

2016-06-01 Thread Laszlo Ersek
On 06/01/16 06:41, Fam Zheng wrote: > v2: Address Eric's comments: > "echo -n" -> "printf". > "-unclean" -> "-dirty". > > Makefile happened to be in my working set because of the docker test work, so > I > went ahead to try this nice feature last evening before going to bed. My > apologie

Re: [Qemu-devel] [PATCH] virtio: move bi-endian target support to a single location

2016-06-01 Thread Paolo Bonzini
On 01/06/2016 04:33, David Gibson wrote: > On Tue, May 31, 2016 at 03:15:21PM +0200, Paolo Bonzini wrote: >> >> >> On 31/05/2016 15:10, Greg Kurz wrote: >>> +#if defined(TARGET_PPC64) || defined(TARGET_ARM) >>> +#define LEGACY_VIRTIO_IS_BIENDIAN 1 >>> +#endif > > These will

Re: [Qemu-devel] [PATCH] configure: save git working tree information in "pkgversion"

2016-06-01 Thread Laszlo Ersek
On 05/31/16 19:45, Eric Blake wrote: > On 05/31/2016 11:01 AM, Laszlo Ersek wrote: > Grepping git's Documentation/RelNotes/ directory, I find: - in "1.6.6.txt": the introduction of --dirty - in "1.7.6.4.txt": an apparently important bugfix for --dirty Version 1.7.6.4 of gi

Re: [Qemu-devel] [RFC PATCH v4 3/3] VFIO Type1 IOMMU: Add support for mediated devices

2016-06-01 Thread Dong Jia
On Wed, 25 May 2016 01:28:17 +0530 Kirti Wankhede wrote: > + > +/* > + * Pin a set of guest PFNs and return their associated host PFNs for API > + * supported domain only. > + * @vaddr [in]: array of guest PFNs > + * @npage [in]: count of array elements > + * @prot [in] : protection flags > + * @

Re: [Qemu-devel] [PATCH v6 08/11] mptsas: change msi property type

2016-06-01 Thread Markus Armbruster
Cao jin writes: >>From uint32 to enum OnOffAuto, and give it a shorter name. > > cc: Paolo Bonzini > cc: Michael S. Tsirkin > cc: Markus Armbruster > cc: Marcel Apfelbaum > > Signed-off-by: Cao jin > --- > hw/scsi/mptsas.c | 4 ++-- > hw/scsi/mptsas.h | 3 ++- > 2 files changed, 4 insertion

[Qemu-devel] [PATCH qemu v17 09/12] vfio: Add host side DMA window capabilities

2016-06-01 Thread Alexey Kardashevskiy
There are going to be multiple IOMMUs per a container. This moves the single host IOMMU parameter set to a list of VFIOHostDMAWindow. This should cause no behavioral change and will be used later by the SPAPR TCE IOMMU v2 which will also add a vfio_host_win_del() helper. Signed-off-by: Alexey Kar

[Qemu-devel] [PATCH qemu v17 10/12] vfio/spapr: Create DMA window dynamically (SPAPR IOMMU v2)

2016-06-01 Thread Alexey Kardashevskiy
New VFIO_SPAPR_TCE_v2_IOMMU type supports dynamic DMA window management. This adds ability to VFIO common code to dynamically allocate/remove DMA windows in the host kernel when new VFIO container is added/removed. This adds VFIO_IOMMU_SPAPR_TCE_CREATE ioctl to vfio_listener_region_add and adds ju

[Qemu-devel] [PATCH qemu v17 12/12] spapr_iommu, vfio, memory: Notify IOMMU about starting/stopping listening

2016-06-01 Thread Alexey Kardashevskiy
The sPAPR TCE tables manage 2 copies when VFIO is using an IOMMU - a guest view of the table and a hardware TCE table. If there is no VFIO presense in the address space, then just the guest view is used, if this is the case, it is allocated in the KVM. However since there is no support yet for VFIO

[Qemu-devel] [PATCH qemu v17 02/12] spapr_iommu: Introduce "enabled" state for TCE table

2016-06-01 Thread Alexey Kardashevskiy
Currently TCE tables are created once at start and their sizes never change. We are going to change that by introducing a Dynamic DMA windows support where DMA configuration may change during the guest execution. This changes spapr_tce_new_table() to create an empty zero-size IOMMU memory region (

[Qemu-devel] [PATCH qemu v17 08/12] spapr_pci: Add and export DMA resetting helper

2016-06-01 Thread Alexey Kardashevskiy
This will be later used by the "ibm,reset-pe-dma-window" RTAS handler which resets the DMA configuration to the defaults. Signed-off-by: Alexey Kardashevskiy Reviewed-by: David Gibson --- hw/ppc/spapr_pci.c | 10 -- include/hw/pci-host/spapr.h | 2 ++ 2 files changed, 10 inser

Re: [Qemu-devel] [PATCH v7 04/15] Makefile: Rules for docker testing

2016-06-01 Thread Fam Zheng
On Wed, 06/01 10:18, Paolo Bonzini wrote: > > > On 01/06/2016 06:25, Fam Zheng wrote: > > +# Use a global constant ccache directory to speed up repetitive builds > > +DOCKER_CCACHE_DIR := /var/tmp/qemu-docker-ccache > > Same here, use $HOME/.cache/qemu-docker-ccache instead. Do you need a > mkd

[Qemu-devel] [PATCH qemu v17 05/12] spapr_pci: Reset DMA config on PHB reset

2016-06-01 Thread Alexey Kardashevskiy
LoPAPR dictates that during system reset all DMA windows must be removed and the default DMA32 window must be created so does the patch. At the moment there is just one window supported so no change in behaviour is expected. Signed-off-by: Alexey Kardashevskiy Reviewed-by: David Gibson --- Chan

[Qemu-devel] [PATCH qemu v17 11/12] spapr_pci/spapr_pci_vfio: Support Dynamic DMA Windows (DDW)

2016-06-01 Thread Alexey Kardashevskiy
This adds support for Dynamic DMA Windows (DDW) option defined by the SPAPR specification which allows to have additional DMA window(s) The "ddw" property is enabled by default on a PHB but for compatibility the pseries-2.5 machine (TODO: update version) and older disable it. This also creates a s

[Qemu-devel] [PATCH qemu v17 06/12] memory: Add reporting of supported page sizes

2016-06-01 Thread Alexey Kardashevskiy
Every IOMMU has some granularity which MemoryRegionIOMMUOps::translate uses when translating, however this information is not available outside the translate context for various checks. This adds a get_page_sizes callback to MemoryRegionIOMMUOps and a wrapper for it so IOMMU users (such as VFIO) c

[Qemu-devel] [PATCH qemu v17 04/12] spapr_iommu: Add root memory region

2016-06-01 Thread Alexey Kardashevskiy
We are going to have multiple DMA windows at different offsets on a PCI bus. For the sake of migration, we will have as many TCE table objects pre-created as many windows supported. So we need a way to map windows dynamically onto a PCI bus when migration of a table is completed but at this stage a

Re: [Qemu-devel] [PATCH] configure: save git working tree information in "pkgversion"

2016-06-01 Thread Fam Zheng
On Wed, 06/01 10:55, Laszlo Ersek wrote: > (Anyway, this is moot now; I'll happily leave it to Fam! :)) Thanks, I wrote the code before you sent this, so I posted it today anyway. :) Also note that we shouldn't do this at configure time, because between ./configure and make, the tree can be modi

[Qemu-devel] [PATCH qemu v17 03/12] spapr_iommu: Migrate full state

2016-06-01 Thread Alexey Kardashevskiy
The source guest could have reallocated the default TCE table and migrate bigger/smaller table. This adds reallocation in post_load() if the default table size is different on source and destination. This adds @bus_offset, @page_shift to the migration stream as a subsection so when DDW is added, m

[Qemu-devel] [PATCH qemu v17 01/12] vmstate: Define VARRAY with VMS_ALLOC

2016-06-01 Thread Alexey Kardashevskiy
This allows dynamic allocation for migrating arrays. Already existing VMSTATE_VARRAY_UINT32 requires an array to be pre-allocated, however there are cases when the size is not known in advance and there is no real need to enforce it. This defines another variant of VMSTATE_VARRAY_UINT32 with WMS_

[Qemu-devel] [PATCH 1/1] qcow2: avoid extra flushes in qcow2

2016-06-01 Thread Denis V. Lunev
qcow2_cache_flush() calls bdrv_flush() unconditionally after writing cache entries of a particular cache. This can lead to as many as 2 additional fdatasyncs inside bdrv_flush. We can simply skip all fdatasync calls inside qcow2_co_flush_to_os as bdrv_flush for sure will do the job. This seriously

Re: [Qemu-devel] [PATCH v2 0/2] Let PKGVERSION include the "git describe" output

2016-06-01 Thread Fam Zheng
On Wed, 06/01 10:49, Laszlo Ersek wrote: > Some comments / questions on the version string: > - What happens if "--with-pkgversion=blah" was passed to ./configure? > Do I see it right that in that case there's no change in behavior? Yes, Makefile only generates it when ./configure says it's empt

Re: [Qemu-devel] [PATCH v6 10/11] pci bridge dev: change msi property type

2016-06-01 Thread Markus Armbruster
Cao jin writes: >>From bit to enum OnOffAuto. > > cc: Michael S. Tsirkin > cc: Markus Armbruster > cc: Marcel Apfelbaum > > Signed-off-by: Cao jin > --- > hw/pci-bridge/pci_bridge_dev.c | 14 -- > 1 file changed, 8 insertions(+), 6 deletions(-) > > diff --git a/hw/pci-bridge/pci_

Re: [Qemu-devel] [PATCH v6 09/11] megasas: change msi/msix property type

2016-06-01 Thread Markus Armbruster
Cao jin writes: >>From bit to enum OnOffAuto. > > cc: Hannes Reinecke > cc: Paolo Bonzini > cc: Michael S. Tsirkin > cc: Markus Armbruster > cc: Marcel Apfelbaum > > Signed-off-by: Cao jin > --- > hw/scsi/megasas.c | 28 +++- > 1 file changed, 11 insertions(+), 17 d

Re: [Qemu-devel] [PATCH 02/10] qcow2: add qcow2_co_write_compressed

2016-06-01 Thread Kevin Wolf
Am 27.05.2016 um 19:33 hat Stefan Hajnoczi geschrieben: > On Sat, May 14, 2016 at 03:45:50PM +0300, Denis V. Lunev wrote: > > +qemu_co_mutex_lock(&s->lock); > > +cluster_offset = \ > > +qcow2_alloc_compressed_cluster_offset(bs, sector_num << 9, > > out_len); > > The backslash isn'

Re: [Qemu-devel] [SeaBIOS] [PATCH v5] fw/pci: Add support for mapping Intel IGD via QEMU

2016-06-01 Thread Gerd Hoffmann
On Di, 2016-05-17 at 14:44 -0600, Alex Williamson wrote: > QEMU provides two fw_cfg files to support IGD. The first holds the > OpRegion data which holds the Video BIOS Table (VBT). This needs to > be copied into reserved memory and the address stored in the ASL > Storage register of the device a

Re: [Qemu-devel] GUI for peripherals

2016-06-01 Thread KONRAD Frederic
Hi Karthik, I think Liviu did something about this: https://lists.nongnu.org/archive/html/qemu-devel/2015-07/msg03825.html Fred Le 30/05/2016 à 08:25, Karthik a écrit : Hello, What would be the best way to provide GUI for peripheral control? This is not for linux rather than embedded system r

Re: [Qemu-devel] [PATCH 02/10] qcow2: add qcow2_co_write_compressed

2016-06-01 Thread Kevin Wolf
Am 31.05.2016 um 20:42 hat Eric Blake geschrieben: > On 05/30/2016 06:58 AM, Pavel Butsykin wrote: > > > > > Sorry, but it seems this will never happen, because the second write > > will not pass this check: > > > > uint64_t qcow2_alloc_compressed_cluster_offset(BlockDriverState *bs, > >

Re: [Qemu-devel] [PATCH 07/16] xen: Use DIV_ROUND_UP

2016-06-01 Thread Stefano Stabellini
On Tue, 31 May 2016, Laurent Vivier wrote: > Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). > > This patch is the result of coccinelle script > scripts/coccinelle/round.cocci > > CC: Stefano Stabellini > Signed-off-by: Laurent Vivier Reviewed-by: Stefano Stabellini > hw/display/xenfb

Re: [Qemu-devel] [PATCH] configure: save git working tree information in "pkgversion"

2016-06-01 Thread Kashyap Chamarthy
On Tue, May 31, 2016 at 05:04:04PM +0200, Laszlo Ersek wrote: > When building QEMU from a git working tree (either in-tree or > out-of-tree), it is useful to capture the working tree status in the QEMU > binary, for the "-version" option to report. > > Daniel suggested using the "pkgversion" varia

[Qemu-devel] [PATCH v3 0/2] Let PKGVERSION include the "git describe" output

2016-06-01 Thread Fam Zheng
v3: Use the "2.6.50 (v2.6.0-603-g684a494)" format. [Laszlo] printf '-dirty' -> printf -- '-dirty'. v2: Address Eric's comments: "echo -n" -> "printf". "-unclean" -> "-dirty". Makefile happened to be in my working set because of the docker test work, so I went ahead to try this nice fe

[Qemu-devel] [PATCH v3 1/2] Makefile: Add a "FORCE" target

2016-06-01 Thread Fam Zheng
Signed-off-by: Fam Zheng --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 3a3c5dc..1e2d6f9 100644 --- a/Makefile +++ b/Makefile @@ -81,7 +81,7 @@ Makefile: ; configure: ; .PHONY: all clean cscope distclean dvi html info install install

[Qemu-devel] [PULL 01/16] tests: Add utilities for docker testing

2016-06-01 Thread Fam Zheng
docker.py is added with a number of useful subcommands to manager docker images and instances for QEMU docker testing. Subcommands are: run: A wrapper of "docker run" (or "sudo -n docker run" if necessary), which takes care of killing and removing the running container at SIGINT. clean: Tear down

[Qemu-devel] [PULL 03/16] Makefile: Always include rules.mak

2016-06-01 Thread Fam Zheng
When config-host.mak is not found it is safe to assume SRC_PATH is ".". So, it is okay to move inclusion of ruls.mak out of the ifeq condition. Signed-off-by: Fam Zheng Message-id: 1464755128-32490-4-git-send-email-f...@redhat.com --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion

[Qemu-devel] [PATCH v3 2/2] Makefile: Derive "PKGVERSION" from "git describe" by default

2016-06-01 Thread Fam Zheng
Currently, if not specified in "./configure", QEMU_PKGVERSION will be empty. Write a rule in Makefile to generate a value from "git describe" combined with a possible git tree cleanness suffix, and write into a new header. $ cat qemu-version.h #define QEMU_PKGVERSION "-v2.6.0-557-gd6550e9-

[Qemu-devel] [PULL v2 00/16] docker queue

2016-06-01 Thread Fam Zheng
The following changes since commit 500acc9c410bcea17148a1072e323c08d12e6a6b: Merge remote-tracking branch 'remotes/dgibson/tags/ppc-for-2.7-20160531' into staging (2016-05-31 10:37:22 +0100) are available in the git repository at: git://github.com/famz/qemu tags/pull-docker-201

[Qemu-devel] [PULL 04/16] Makefile: Rules for docker testing

2016-06-01 Thread Fam Zheng
This adds a group of make targets to run docker tests, all are available in source tree without running ./configure. The usage is shown with "make docker". Besides the fixed ones, dynamic targets for building each image and running each test in each image are generated automatically by make, scan

[Qemu-devel] [PULL 12/16] docker: Add travis tool

2016-06-01 Thread Fam Zheng
The script is not prefixed with test- so it won't run with "make docker-test", because it can take too long. Run it with "make docker-travis@ubuntu". Reviewed-by: Alex Bennée Signed-off-by: Fam Zheng Message-id: 1464755128-32490-13-git-send-email-f...@redhat.com --- tests/docker/travis| 21

[Qemu-devel] [PULL 06/16] docker: Add test runner

2016-06-01 Thread Fam Zheng
It's better to have a launcher for all tests, to make it easier to initialize and manage the environment. If "DEBUG=1" a shell prompt will show up before the test runs. Reviewed-by: Alex Bennée Signed-off-by: Fam Zheng Message-id: 1464755128-32490-7-git-send-email-f...@redhat.com --- tests/do

[Qemu-devel] [PULL 09/16] docker: Add full test

2016-06-01 Thread Fam Zheng
This builds all available targets. Signed-off-by: Fam Zheng Reviewed-by: Alex Bennée Message-id: 1464755128-32490-10-git-send-email-f...@redhat.com --- tests/docker/test-full | 17 + 1 file changed, 17 insertions(+) create mode 100755 tests/docker/test-full diff --git a/tests/

[Qemu-devel] [PULL 05/16] docker: Add images

2016-06-01 Thread Fam Zheng
Reviewed-by: Alex Bennée Signed-off-by: Fam Zheng Message-id: 1464755128-32490-6-git-send-email-f...@redhat.com --- tests/docker/dockerfiles/centos6.docker | 6 ++ tests/docker/dockerfiles/fedora.docker | 7 +++ tests/docker/dockerfiles/ubuntu.docker | 11 +++ 3 files changed

[Qemu-devel] [PULL 13/16] docs: Add text for tests/docker in build-system.txt

2016-06-01 Thread Fam Zheng
Reviewed-by: Alex Bennée Signed-off-by: Fam Zheng Message-id: 1464755128-32490-14-git-send-email-f...@redhat.com --- 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.

[Qemu-devel] [PULL 16/16] .gitignore: Ignore docker source copy

2016-06-01 Thread Fam Zheng
Signed-off-by: Fam Zheng --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 88a80ff..38ee1c5 100644 --- a/.gitignore +++ b/.gitignore @@ -108,4 +108,5 @@ cscope.* tags TAGS +docker-src.* *~ -- 2.8.2

[Qemu-devel] [PULL 07/16] docker: Add common.rc

2016-06-01 Thread Fam Zheng
"requires" checks the "FEATURE" environment for specified prerequisits, and skip the execution of test if not found. "build_qemu" is the central routine to compile QEMU for tests to call. Reviewed-by: Alex Bennée Signed-off-by: Fam Zheng Message-id: 1464755128-32490-8-git-send-email-f...@redhat

[Qemu-devel] [PULL 02/16] rules.mak: Add "COMMA" constant

2016-06-01 Thread Fam Zheng
Using "," literal in $(call quiet-command, ...) arguments is awkward. Add this constant to make it at least doable. Signed-off-by: Fam Zheng Message-id: 1464755128-32490-3-git-send-email-f...@redhat.com --- rules.mak | 2 ++ 1 file changed, 2 insertions(+) diff --git a/rules.mak b/rules.mak ind

[Qemu-devel] [PULL 14/16] docker: Add EXTRA_CONFIGURE_OPTS

2016-06-01 Thread Fam Zheng
Whatever passed in this variable will be appended to all configure commands. Signed-off-by: Fam Zheng Reviewed-by: Alex Bennée Message-id: 1464755128-32490-15-git-send-email-f...@redhat.com --- tests/docker/Makefile.include | 3 +++ tests/docker/common.rc| 1 + 2 files changed, 4 insert

[Qemu-devel] [RFC PATCH v0 2/2] spapr: Increase max memslots to 512

2016-06-01 Thread Bharata B Rao
KVM now supports 512 memslots on PowerPC (earlier it was 32). Hence allow user to specify a max of 512 hotpluggable memory slots. Instead of hard coding the max value, use the KVM supplied value if KVM is enabled. Otherwise resort to the default value of 32. Signed-off-by: Bharata B Rao --- hw/

[Qemu-devel] [PULL 08/16] docker: Add quick test

2016-06-01 Thread Fam Zheng
Reviewed-by: Alex Bennée Signed-off-by: Fam Zheng Message-id: 1464755128-32490-9-git-send-email-f...@redhat.com --- tests/docker/test-quick | 19 +++ 1 file changed, 19 insertions(+) create mode 100755 tests/docker/test-quick diff --git a/tests/docker/test-quick b/tests/docker/

[Qemu-devel] [RFC PATCH v0 0/2] Increase max memslots to 512 for PowerPC

2016-06-01 Thread Bharata B Rao
Recently the number of memory slots supported by KVM for PowerPC was changed from 32 to 512. QEMU was restricting the user specifiable hot-pluggable memory slots to 32. This patchset changes that to 512. This allows more number of slots to be available for memory hotplugging. Bharata B Rao (2):

[Qemu-devel] [PULL 10/16] docker: Add clang test

2016-06-01 Thread Fam Zheng
The (currently partially commented out) configure options are suggested by John Snow . Signed-off-by: Fam Zheng Reviewed-by: Alex Bennée Message-id: 1464755128-32490-11-git-send-email-f...@redhat.com --- tests/docker/test-clang | 26 ++ 1 file changed, 26 insertions(+)

Re: [Qemu-devel] [PATCH 02/10] qcow2: add qcow2_co_write_compressed

2016-06-01 Thread Pavel Butsykin
On 01.06.2016 00:13, Eric Blake wrote: On 05/31/2016 03:00 PM, Denis V. Lunev wrote: On 05/31/2016 09:42 PM, Eric Blake wrote: On 05/30/2016 06:58 AM, Pavel Butsykin wrote: Sorry, but it seems this will never happen, because the second write will not pass this check: uint64_t qcow2_alloc_com

[Qemu-devel] [RFC PATCH v0 1/2] kvm: API to obtain max supported mem slots

2016-06-01 Thread Bharata B Rao
Introduce kvm_get_max_memslots() API that can be used to obtain the maximum number of memslots supported by KVM. Signed-off-by: Bharata B Rao --- include/sysemu/kvm.h | 1 + kvm-all.c| 7 +++ 2 files changed, 8 insertions(+) diff --git a/include/sysemu/kvm.h b/include/sysemu/kvm

[Qemu-devel] [PULL 11/16] docker: Add mingw test

2016-06-01 Thread Fam Zheng
Reviewed-by: Alex Bennée Signed-off-by: Fam Zheng Message-id: 1464755128-32490-12-git-send-email-f...@redhat.com --- tests/docker/test-mingw | 34 ++ 1 file changed, 34 insertions(+) create mode 100755 tests/docker/test-mingw diff --git a/tests/docker/test-mingw

[Qemu-devel] [PATCH qemu v17 00/12] spapr: vfio: Enable Dynamic DMA windows (DDW)

2016-06-01 Thread Alexey Kardashevskiy
Each Partitionable Endpoint (IOMMU group) has an address range on a PCI bus where devices are allowed to do DMA. These ranges are called DMA windows. By default, there is a single DMA window, 1 or 2GB big, mapped at zero on a PCI bus. PAPR defines a DDW RTAS API which allows pseries guests queryin

[Qemu-devel] [PULL 15/16] MAINTAINERS: Add tests/docker

2016-06-01 Thread Fam Zheng
Reviewed-by: Alex Bennée Signed-off-by: Fam Zheng Message-id: 1464755128-32490-16-git-send-email-f...@redhat.com --- MAINTAINERS | 7 +++ 1 file changed, 7 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 3c949d5..091272e 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -1615,3 +1615

Re: [Qemu-devel] [Qemu-discuss] iolimits for virtio-9p

2016-06-01 Thread Pradeep Kiruvale
Thanks Alberto. Regards, Pradeep On 6 May 2016 at 14:16, Alberto Garcia wrote: > On Fri 06 May 2016 09:39:13 AM CEST, Pradeep Kiruvale wrote: > > >> The throttling API is currently only used by block devices, and the > >> only documentation out-there is the code itself... > > > > Thanks, I will

[Qemu-devel] [PATCH 1/2] migration: fix typos in qapi-schema from latest migration additions

2016-06-01 Thread Daniel P. Berrange
Recent migration QAPI enhancements had a few spelling mistakes and also incorrect version number in a few places. Signed-off-by: Daniel P. Berrange --- qapi-schema.json | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/qapi-schema.json b/qapi-schema.json index 8483bd

Re: [Qemu-devel] [RFC PATCH v0 1/2] kvm: API to obtain max supported mem slots

2016-06-01 Thread Paolo Bonzini
On 01/06/2016 11:51, Bharata B Rao wrote: > Introduce kvm_get_max_memslots() API that can be used to obtain the > maximum number of memslots supported by KVM. > > Signed-off-by: Bharata B Rao > --- > include/sysemu/kvm.h | 1 + > kvm-all.c| 7 +++ > 2 files changed, 8 insertion

[Qemu-devel] [PATCH qemu] KVM CAPS DBG

2016-06-01 Thread Alexey Kardashevskiy
--- target-ppc/kvm.c | 16 1 file changed, 16 insertions(+) diff --git a/target-ppc/kvm.c b/target-ppc/kvm.c index df6b45c..896b38b 100644 --- a/target-ppc/kvm.c +++ b/target-ppc/kvm.c @@ -113,6 +113,22 @@ int kvm_arch_init(MachineState *ms, KVMState *s) cap_spapr_tce_64 = k

Re: [Qemu-devel] [PATCH 1/1] qcow2: avoid extra flushes in qcow2

2016-06-01 Thread Kevin Wolf
Am 01.06.2016 um 11:12 hat Denis V. Lunev geschrieben: > qcow2_cache_flush() calls bdrv_flush() unconditionally after writing > cache entries of a particular cache. This can lead to as many as > 2 additional fdatasyncs inside bdrv_flush. > > We can simply skip all fdatasync calls inside qcow2_co_f

[Qemu-devel] [PATCH qemu v17 07/12] vfio: spapr: Add DMA memory preregistering (SPAPR IOMMU v2)

2016-06-01 Thread Alexey Kardashevskiy
This makes use of the new "memory registering" feature. The idea is to provide the userspace ability to notify the host kernel about pages which are going to be used for DMA. Having this information, the host kernel can pin them all once per user process, do locked pages accounting (once) and not s

Re: [Qemu-devel] [Qemu-block] [PATCH] qcow2 resize with snapshot

2016-06-01 Thread zhangzhiming
hi, here are all changes of my code. thanks for the review! zhangzhiming zhangzhimin...@meituan.com Signed-off-by: zhangzhiming --- block.c | 19 +++ block/qcow2-cluster.c| 29 + block/qcow2-snapshot.c | 33 +

[Qemu-devel] [PATCH 0/2] Misc followup fixes for migration tls series

2016-06-01 Thread Daniel P. Berrange
This small series addresses the few comments made about the migration tls series after it was merged. Daniel P. Berrange (2): migration: fix typos in qapi-schema from latest migration additions migration: rename functions to starting migrations include/migration/migration.h | 26

Re: [Qemu-devel] [PATCH v3 1/2] Makefile: Add a "FORCE" target

2016-06-01 Thread Daniel P. Berrange
On Wed, Jun 01, 2016 at 05:44:20PM +0800, Fam Zheng wrote: > Signed-off-by: Fam Zheng > --- > Makefile | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/Makefile b/Makefile > index 3a3c5dc..1e2d6f9 100644 > --- a/Makefile > +++ b/Makefile > @@ -81,7 +81,7 @@ Makefile: ; >

  1   2   3   >