[Qemu-devel] [Bug 1670175] Re: qemu-system-sparc64 with tribblix-sparc-0m16.iso ends with "panic - kernel: no nucleus hblk8 to allocate"

2017-03-09 Thread Michal Nowak
This is how it ends with 2048 MB of memory instead of 1024: > qemu-system-sparc64 -m 2048 -cdrom Downloads/tmp/tribblix-sparc-0m16.iso > -boot d -nographic OpenBIOS for Sparc64 Configuration device id QEMU version 1 machine id 0 kernel cmdline CPUs: 1 x SUNW,UltraSPARC-IIi UUID: --00

[Qemu-devel] [PATCH v2 0/4] vga: make display size configurable

2017-03-09 Thread Gerd Hoffmann
Hi, Next attempt, this time using device properties (xres and yres) instead of extending the usage of the -g switch, as suggested by paolo. This series has support for virtio, qxl and stdvga. For stdvga the virtual hardware is updated with additional (read-only) registers. cheers, Gerd Ger

[Qemu-devel] [PATCH v2 4/4] [RfC] stdvga: add xres and yres properties.

2017-03-09 Thread Gerd Hoffmann
Add two new registers to the qemu extended register range, carrying the suggested width and height of the display device. In case the xres and yres properties are set, fill these new registers accordingly. Additionally guest driver updates are needed to support the new registers. These changes w

[Qemu-devel] [PATCH v2 1/4] virtio-gpu: add xres and yres properties

2017-03-09 Thread Gerd Hoffmann
So the default resolution is configurable. Signed-off-by: Gerd Hoffmann Reviewed-by: Marc-André Lureau --- hw/display/virtio-gpu.c| 6 -- include/hw/virtio/virtio-gpu.h | 2 ++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/hw/display/virtio-gpu.c b/hw/display/virtio

[Qemu-devel] [PATCH v2 2/4] qxl: add xres and yres properties

2017-03-09 Thread Gerd Hoffmann
Add properties for the default display resolution, pass on that information to the guest so the driver can use it. Also move up qxl_crc32() function so we don't need a forward declaration. Additionally guest driver updates are needed so the guest driver will actually pick this up, which will prob

[Qemu-devel] [PATCH v2 3/4] stdvga: move common properties to common base class

2017-03-09 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/display/vga-pci.c | 11 --- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/hw/display/vga-pci.c b/hw/display/vga-pci.c index ac9a764..8500362 100644 --- a/hw/display/vga-pci.c +++ b/hw/display/vga-pci.c @@ -306,15 +306,12 @@ static void p

Re: [Qemu-devel] What's the next QEMU version after 2.9 ? (or: when is a good point in time to get rid of old interfaces)

2017-03-09 Thread Thomas Huth
On 09.03.2017 03:21, Jason Wang wrote: > > > On 2017年03月08日 19:22, Thomas Huth wrote: >> On 08.03.2017 11:03, Peter Maydell wrote: >>> On 8 March 2017 at 09:26, Thomas Huth wrote: But anyway, the more important thing that keeps me concerned is: Someone once told me that we shoul

[Qemu-devel] [PULL for-2.9 0/2] bugfixes for ohci and qxl

2017-03-09 Thread Gerd Hoffmann
ailable in the git repository at: git://git.kraxel.org/qemu tags/pull-fixes-20170309-1 for you to fetch changes up to dbb5fb8d3519130559b10fa4e1395e4486c633f8: qxl: clear guest_cursor on QXL_CURSOR_HIDE (2017-03-09 09:47:26 +0100) --

[Qemu-devel] [PULL 1/2] ohci: relax link check

2017-03-09 Thread Gerd Hoffmann
The strict td link limit added by commit "95ed569 usb: ohci: limit the number of link eds" causes problems with macos guests. Lets raise the limit. Reported-by: Programmingkid Reported-by: Howard Spoelstra Signed-off-by: Gerd Hoffmann Reviewed-by: BALATON Zoltan Reviewed-by: John Arbuckle Me

[Qemu-devel] [PULL 2/2] qxl: clear guest_cursor on QXL_CURSOR_HIDE

2017-03-09 Thread Gerd Hoffmann
Make sure we don't leave guest_cursor pointing into nowhere. This might lead to (rare) live migration failures, due to target trying to restore the cursor from the stale pointer. Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1421788 Reported-by: Dr. David Alan Gilbert Signed-off-by: Gerd

Re: [Qemu-devel] [PATCH RFC v3 00/15] basic vfio-ccw infrastructure

2017-03-09 Thread Dong Jia Shi
* Dong Jia Shi [2017-02-17 09:29:24 +0100]: > vfio-ccw: the basic infrastructure > == > > Introduction > > > Here we describe the vfio support for I/O subchannel devices for > Linux/s390. Motivation for vfio-ccw is to passthrough subchannels to a > v

Re: [Qemu-devel] [PATCH V3] virtio: do not require IOMMU to be created in advance

2017-03-09 Thread Igor Mammedov
On Thu, 9 Mar 2017 10:32:44 +0800 Jason Wang wrote: > On 2017年03月09日 00:40, Igor Mammedov wrote: > > On Tue, 7 Mar 2017 14:47:30 +0200 > > Marcel Apfelbaum wrote: > > > >> On 03/07/2017 11:09 AM, Jason Wang wrote: > >>> After commit 96a8821d2141 ("virtio: unbreak virtio-pci with IOMMU > >>>

Re: [Qemu-devel] [PATCH V3] virtio: do not require IOMMU to be created in advance

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 10:28, Igor Mammedov wrote: > On Thu, 9 Mar 2017 10:32:44 +0800 > Jason Wang wrote: > >> On 2017年03月09日 00:40, Igor Mammedov wrote: >>> On Tue, 7 Mar 2017 14:47:30 +0200 >>> Marcel Apfelbaum wrote: >>> On 03/07/2017 11:09 AM, Jason Wang wrote: > After commit 96a8821d

Re: [Qemu-devel] What's the next QEMU version after 2.9 ? (or: when is a good point in time to get rid of old interfaces)

2017-03-09 Thread Jason Wang
On 2017年03月09日 16:50, Thomas Huth wrote: On 09.03.2017 03:21, Jason Wang wrote: On 2017年03月08日 19:22, Thomas Huth wrote: On 08.03.2017 11:03, Peter Maydell wrote: On 8 March 2017 at 09:26, Thomas Huth wrote: But anyway, the more important thing that keeps me concerned is: Someone once

Re: [Qemu-devel] [PATCH V3] virtio: do not require IOMMU to be created in advance

2017-03-09 Thread Jason Wang
On 2017年03月09日 17:28, Igor Mammedov wrote: On Thu, 9 Mar 2017 10:32:44 +0800 Jason Wang wrote: On 2017年03月09日 00:40, Igor Mammedov wrote: On Tue, 7 Mar 2017 14:47:30 +0200 Marcel Apfelbaum wrote: On 03/07/2017 11:09 AM, Jason Wang wrote: After commit 96a8821d2141 ("virtio: unbreak vi

Re: [Qemu-devel] [PATCH V3] virtio: do not require IOMMU to be created in advance

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 10:58, Jason Wang wrote: > > > On 2017年03月09日 17:28, Igor Mammedov wrote: >> On Thu, 9 Mar 2017 10:32:44 +0800 >> Jason Wang wrote: >> >>> On 2017年03月09日 00:40, Igor Mammedov wrote: On Tue, 7 Mar 2017 14:47:30 +0200 Marcel Apfelbaum wrote: > On 03/07/2017 1

Re: [Qemu-devel] [PATCH v2] Add inst_dirty_pages_rate in 'info migrate'

2017-03-09 Thread Chao Fan
On Wed, Mar 08, 2017 at 01:45:59PM +, Daniel P. Berrange wrote: >On Wed, Mar 08, 2017 at 04:28:19PM +0800, Chao Fan wrote: >> Auto-converge aims to accelerate migration by slowing down the >> generation of dirty pages. But user doesn't know how to determine the >> throttle value, so, a new item

[Qemu-devel] external snapshots freezes block device since qemu 2.8

2017-03-09 Thread Piotr Rybicki
Hello there. I discovered, that since qemu 2.8 , external snapshots (very similar to: http://wiki.libvirt.org/page/Live-disk-backup-with-active-blockcommit), freezes block device after: # virsh blockcommit (...) There is no error message after completion of the command above. I'm using glust

Re: [Qemu-devel] What's the next QEMU version after 2.9 ? (or: when is a good point in time to get rid of old interfaces)

2017-03-09 Thread Yongbok Kim
On 09/03/2017 09:53, Jason Wang wrote: > > > On 2017年03月09日 16:50, Thomas Huth wrote: >> On 09.03.2017 03:21, Jason Wang wrote: >>> >>> On 2017年03月08日 19:22, Thomas Huth wrote: On 08.03.2017 11:03, Peter Maydell wrote: > On 8 March 2017 at 09:26, Thomas Huth wrote: >> But anyway,

Re: [Qemu-devel] [PATCH] virtio: destroy region cache during reset

2017-03-09 Thread Cornelia Huck
On Thu, 9 Mar 2017 10:19:47 +0800 Jason Wang wrote: > On 2017年03月08日 18:12, Cornelia Huck wrote: > > On Wed, 8 Mar 2017 17:51:22 +0800 > > Jason Wang wrote: > > > >> On 2017年03月08日 17:19, Cornelia Huck wrote: > >>> On Wed, 8 Mar 2017 11:18:27 +0800 > >>> Jason Wang wrote: > >>> > On 2017年0

Re: [Qemu-devel] [PATCH] virtio: destroy region cache during reset

2017-03-09 Thread Paolo Bonzini
On 08/03/2017 10:48, Jason Wang wrote: > > > On 2017年03月08日 17:10, Paolo Bonzini wrote: >> >> - Original Message - >>> From: "Jason Wang" >>> To: "Paolo Bonzini" , m...@redhat.com, >>> qemu-devel@nongnu.org >>> Cc: pet...@redhat.com >>> Sent: Wednesday, March 8, 2017 7:22:06 AM >>> Sub

Re: [Qemu-devel] [PATCH] virtio: destroy region cache during reset

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 12:07, Cornelia Huck wrote: >>> - Driver #2 uses the device without doing a reset or proper setup >> Without this patch, even if driver #2 do a reset, it can still use the >> old map if it don't set queue pfn. > > Yes, the cleanup-on-reset is definetly needed. It is good to have

Re: [Qemu-devel] [PATCH RFC] qdev: add init order filter

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 00:59, Michael S. Tsirkin wrote: > Allow forcing a specific order of initialization on > devices created with -device. > Helpful e.g. for built-in devices such as IOMMUs which must > exist before all other devices. > > Signed-off-by: Michael S. Tsirkin > --- > > Looks like we hav

[Qemu-devel] [PULL 01/11] vl/cpus: be smarter with icount and MTTCG

2017-03-09 Thread Alex Bennée
The sense of the test was inverted. Make it simple, if icount is enabled then we disabled MTTCG by default. If the user tries to force MTTCG upon us then we tell them "no". Signed-off-by: Alex Bennée Reviewed-by: Richard Henderson --- cpus.c | 7 +++ vl.c | 7 ++- 2 files changed, 5 i

[Qemu-devel] [PULL 02/11] target/i386/cpu.h: declare TCG_GUEST_DEFAULT_MO

2017-03-09 Thread Alex Bennée
This suppresses the incorrect warning when forcing MTTCG for x86 guests on x86 hosts. A future patch will still warn when TARGET_SUPPORT_MTTCG hasn't been defined for the guest (which is still pending for x86). Reported-by: Paolo Bonzini Signed-off-by: Alex Bennée Reviewed-by: Richard Henderson

[Qemu-devel] [PULL 03/11] cpus.c: add additional error_report when !TARGET_SUPPORT_MTTCG

2017-03-09 Thread Alex Bennée
While we may fail the memory ordering check later that can be confusing. So in cases where TARGET_SUPPORT_MTTCG has yet to be defined we should say so specifically. Signed-off-by: Alex Bennée Reviewed-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé --- cpus.c | 4 1 file changed

[Qemu-devel] [PULL 00/11] MTTCG Fix-ups for 2.9

2017-03-09 Thread Alex Bennée
The following changes since commit b64842dee42d6b24d51283e4722140b73be1e222: Merge remote-tracking branch 'remotes/kevin/tags/for-upstream' into staging (2017-03-08 09:47:52 +) are available in the git repository at: https://github.com/stsquad/qemu.git tags/pull-mttcg-fixups-090317-1 f

[Qemu-devel] [PULL 05/11] s390x/misc_helper.c: wrap IO instructions in BQL

2017-03-09 Thread Alex Bennée
Helpers that can trigger IO events (including interrupts) need to be protected by the BQL. I've updated all the helpers that call into an ioinst_handle_* functions. Reported-by: Thomas Huth Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé --- target/s390x/misc_helper.c | 21 +

[Qemu-devel] [PULL 06/11] target/xtensa: hold BQL for interrupt processing

2017-03-09 Thread Alex Bennée
Make sure we have the BQL held when processing interrupts. Reported-by: Thomas Huth Signed-off-by: Alex Bennée Acked-by: Max Filippov --- target/xtensa/helper.c| 1 + target/xtensa/op_helper.c | 7 +++ 2 files changed, 8 insertions(+) diff --git a/target/xtensa/helper.c b/target/xtens

[Qemu-devel] [PULL 04/11] sparc/sparc64: grab BQL before calling cpu_check_irqs

2017-03-09 Thread Alex Bennée
IRQ modification is part of device emulation and should be done while the BQL is held to prevent races when MTTCG is enabled. This adds assertions in the hw emulation layer and wraps the calls from helpers in the BQL. Reported-by: Mark Cave-Ayland Signed-off-by: Alex Bennée --- hw/sparc/sun4m.c

[Qemu-devel] [PULL 10/11] target/arm/helper: make it clear the EC field is also in hex

2017-03-09 Thread Alex Bennée
..just like the rest of the displayed ESR register. Otherwise people might scratch their heads if a not obviously hex number is displayed for the EC field. Signed-off-by: Alex Bennée Reviewed-by: Peter Maydell Reviewed-by: KONRAD Frederic Reviewed-by: Philippe Mathieu-Daudé --- target/arm/hel

[Qemu-devel] [PULL 07/11] translate-all: exit cpu_restore_state early if translating

2017-03-09 Thread Alex Bennée
The translation code uses cpu_ld*_code which can trigger a tlb_fill which if it fails will erroneously attempts a fault resolution. This never works during translation as the TB being generated hasn't been added yet. The target should have checked retaddr before calling cpu_restore_state but for th

[Qemu-devel] [PULL 11/11] hw/intc/arm_gic: modernise the DPRINTF

2017-03-09 Thread Alex Bennée
While I was debugging the icount issues I realised a bunch of the messages look quite similar. I've fixed this by including __func__ in the debug print. At the same time I move the a modern if (GATE) style printf which ensures the compiler can check for format string errors even if the code gets op

[Qemu-devel] [PULL 08/11] target/mips: hold BQL for timer interrupts

2017-03-09 Thread Alex Bennée
From: Yongbok Kim Hold BQL when accessing timer which can cause interrupts Signed-off-by: Yongbok Kim Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Alex Bennée --- target/mips/op_helper.c | 21 ++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/target/m

[Qemu-devel] [PULL 09/11] target-i386: defer VMEXIT to do_interrupt

2017-03-09 Thread Alex Bennée
From: Paolo Bonzini Paths through the softmmu code during code generation now need to be audited to check for double locking of tb_lock. In particular, VMEXIT can take tb_lock through cpu_vmexit -> cpu_x86_update_cr4 -> tlb_flush. To avoid this, split VMEXIT delivery in two parts, similar to wh

Re: [Qemu-devel] [PATCH] memory_region: Fix name comments

2017-03-09 Thread Dr. David Alan Gilbert
* Peter Maydell (peter.mayd...@linaro.org) wrote: > On 8 March 2017 at 11:54, Dr. David Alan Gilbert (git) > wrote: > > From: "Dr. David Alan Gilbert" > > > > The 'name' parameter to memory_region_init_* had been marked as debug > > only, however vmstate_region_ram uses it as a parameter to > > q

[Qemu-devel] [RFC PATCH 0/4] ARM/ARM64 fixes for live memory snapshot based on userfaultfd

2017-03-09 Thread Christian Pinto
This patch series introduces a set of fixes to the previous work proposed by Hailiang Zhang to enable in QEMU live memory snapshot based on userfaultfd. See discussion here: http://www.mail-archive.com/qemu-devel@nongnu.org/msg393118.html These patches apply on top of: https://github.com/coloft/q

[Qemu-devel] [RFC PATCH 1/4] migration/postcopy-ram: check pagefault flags in userfaultfd thread

2017-03-09 Thread Christian Pinto
The UFFD_PAGEFAULT_FLAG_WP should be set every time the page fault is due to a write to a write-protected page. Flag should be checked at every time to be sure the page fault is due to a write into WP area. Signed-off-by: Christian Pinto Signed-off-by: Baptiste Reynal --- migration/postcopy-ram

[Qemu-devel] [RFC PATCH 3/4] migration: snapshot thread

2017-03-09 Thread Christian Pinto
VM execution was resumed while migration was still in setup. This was causing a bus error because the userfault thread was waking up VM too early during migration setup. Signed-off-by: Christian Pinto Signed-off-by: Baptiste Reynal --- migration/migration.c| 9 + migration/postcopy

[Qemu-devel] [RFC PATCH 4/4] migration/postcopy-ram: ram_set_pages_wp fix

2017-03-09 Thread Christian Pinto
setting UFFDIO_WRITEPROTECT_MODE_DONTWAKE when write un-protecting a page does not wake up the faulting thread. Set to 0 to force the faulting (VM) thread to wake-up. Signed-off-by: Christian Pinto Signed-off-by: Baptiste Reynal --- migration/postcopy-ram.c | 2 +- 1 file changed, 1 insertion(+

[Qemu-devel] [RFC PATCH 2/4] migration/ram: Fix for ARM/ARM64 page size

2017-03-09 Thread Christian Pinto
Architecture such as ARM use a page size of 1KB, while write protection is done at the granularity of host pages (generally 4KB). All addresses must always be aligned to the size of a host page. Signed-off-by: Christian Pinto Signed-off-by: Baptiste Reynal --- migration/postcopy-ram.c | 6 +++-

[Qemu-devel] [PATCH 2/6] block: Request block status from *file for BDRV_BLOCK_RAW

2017-03-09 Thread Kevin Wolf
This fixes bdrv_co_get_block_status() for the bdrv_mirror_top block driver, which must fall through to bs->backing instead of bs->file. Signed-off-by: Kevin Wolf --- block/io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/io.c b/block/io.c index 8f38d46..2709a70 1006

Re: [Qemu-devel] [PATCH] virtio: destroy region cache during reset

2017-03-09 Thread Cornelia Huck
On Thu, 9 Mar 2017 12:12:00 +0100 Paolo Bonzini wrote: > On 09/03/2017 12:07, Cornelia Huck wrote: > >>> - Driver #2 uses the device without doing a reset or proper setup > >> Without this patch, even if driver #2 do a reset, it can still use the > >> old map if it don't set queue pfn. > > > >

[Qemu-devel] [PATCH 4/6] block: Refresh filename after changing backing file

2017-03-09 Thread Kevin Wolf
In bdrv_open_inherit(), the filename is refreshed after opening the backing file, but we neglected to do the same when the backing file changes later. Signed-off-by: Kevin Wolf --- block.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/block.c b/block.c index 756d607..516cefe 100644 --- a

[Qemu-devel] [PATCH 3/6] commit: Implement bdrv_commit_top.bdrv_co_get_block_status

2017-03-09 Thread Kevin Wolf
In some cases, bdrv_co_get_block_status() is called recursively for the whole backing chain. The automatically inserted bdrv_commit_top filter driver must not stop the recursion, so implement a callback that simply forwards the request to bs->backing. Signed-off-by: Kevin Wolf --- block/commit.c

[Qemu-devel] [PATCH 0/6] block: More op blocker fixes

2017-03-09 Thread Kevin Wolf
Kevin Wolf (6): block: Remove check_new_perm from bdrv_replace_child() block: Request block status from *file for BDRV_BLOCK_RAW commit: Implement bdrv_commit_top.bdrv_co_get_block_status block: Refresh filename after changing backing file mirror: Implement .bdrv_refresh_filename commit

[Qemu-devel] [PATCH 5/6] mirror: Implement .bdrv_refresh_filename

2017-03-09 Thread Kevin Wolf
We want query-block to return the right filename, even if a mirror job put a bdrv_mirror_top on top of the actual image format driver. Let bdrv_mirror_top.bdrv_refresh_filename get the filename from its backing file. Signed-off-by: Kevin Wolf --- block/mirror.c | 9 + 1 file changed, 9 i

[Qemu-devel] [PATCH 6/6] commit: Implement .bdrv_refresh_filename

2017-03-09 Thread Kevin Wolf
We want query-block to return the right filename, even if a commit job put a bdrv_commit_top on top of the actual image format driver. Let bdrv_commit_top.bdrv_refresh_filename get the filename from its backing file. Signed-off-by: Kevin Wolf --- block/commit.c | 8 1 file changed, 8 in

[Qemu-devel] [PATCH 1/6] block: Remove check_new_perm from bdrv_replace_child()

2017-03-09 Thread Kevin Wolf
All callers pass false now, so the parameter can go away again. Signed-off-by: Kevin Wolf --- block.c | 21 ++--- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/block.c b/block.c index dd9ded8..756d607 100644 --- a/block.c +++ b/block.c @@ -1751,8 +1751,18 @@ stat

Re: [Qemu-devel] [PATCH RFC 1/1] vmstate: draft fix for failed iotests case 68 and 91

2017-03-09 Thread Halil Pasic
On 03/09/2017 03:55 AM, QingFeng Hao wrote: > > > 在 2017/3/8 19:33, Halil Pasic 写道: >> >> On 03/08/2017 08:05 AM, QingFeng Hao wrote: >>> >>> 在 2017/3/7 18:19, Halil Pasic 写道: On 03/07/2017 11:05 AM, Kevin Wolf wrote: > Am 07.03.2017 um 10:54 hat Halil Pasic geschrieben: >> On 03/0

Re: [Qemu-devel] [PATCH] virtio: destroy region cache during reset

2017-03-09 Thread Cornelia Huck
On Thu, 9 Mar 2017 12:10:44 +0100 Paolo Bonzini wrote: > On 08/03/2017 10:48, Jason Wang wrote: > > > > > > On 2017年03月08日 17:10, Paolo Bonzini wrote: > >> > >> - Original Message - > >>> From: "Jason Wang" > >>> To: "Paolo Bonzini" , m...@redhat.com, > >>> qemu-devel@nongnu.org > >>>

Re: [Qemu-devel] RAMBlock's named ""

2017-03-09 Thread Paolo Bonzini
On 07/03/2017 20:46, Dr. David Alan Gilbert wrote: > (from https://bugzilla.redhat.com/show_bug.cgi?id=1425273) > The simplest reproducer of this is: > > ./qemu-system-x86_64 -nographic -device e1000e,id=foo -m 1G -M pc,accel=kvm > my.img > > with a Linux image and after it's booted do

[Qemu-devel] [PATCH] e1000e: correctly tear down MSI-X memory regions

2017-03-09 Thread Paolo Bonzini
MSI-X has been disabled by the time the e1000e device is unrealized, hence msix_uninit is never called. This causes the object to be leaked, which shows up as a RAMBlock with empty name when attempting migration. Reported-by: Dr. David Alan Gilbert Cc: Jason Wang Cc: qemu-sta...@nongnu.org Sign

Re: [Qemu-devel] [PATCH] memory_region: Fix name comments

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 12:26, Dr. David Alan Gilbert wrote: > * @name: Region name, becomes part of RAMBlock name used in migration stream > *must be unique within any device Just a note, the uniqueness constraint also applies for RAM regions only. Paolo

Re: [Qemu-devel] [PATCH] e1000e: correctly tear down MSI-X memory regions

2017-03-09 Thread Laurent Vivier
On 09/03/2017 12:58, Paolo Bonzini wrote: > MSI-X has been disabled by the time the e1000e device is unrealized, hence > msix_uninit is never called. This causes the object to be leaked, which > shows up as a RAMBlock with empty name when attempting migration. > > Reported-by: Dr. David Alan Gilb

Re: [Qemu-devel] [PATCH] memory_region: Fix name comments

2017-03-09 Thread Dr. David Alan Gilbert
* Paolo Bonzini (pbonz...@redhat.com) wrote: > > > On 09/03/2017 12:26, Dr. David Alan Gilbert wrote: > > * @name: Region name, becomes part of RAMBlock name used in migration > > stream > > *must be unique within any device > > Just a note, the uniqueness constraint also applies for

Re: [Qemu-devel] [PATCH RFC] qdev: add init order filter

2017-03-09 Thread Marcel Apfelbaum
On 03/09/2017 01:13 PM, Paolo Bonzini wrote: On 09/03/2017 00:59, Michael S. Tsirkin wrote: Allow forcing a specific order of initialization on devices created with -device. Helpful e.g. for built-in devices such as IOMMUs which must exist before all other devices. Signed-off-by: Michael S. T

Re: [Qemu-devel] external snapshots freezes block device since qemu 2.8

2017-03-09 Thread Dr. David Alan Gilbert
* Piotr Rybicki (piotr.rybi...@innervision.pl) wrote: > Hello there. > > I discovered, that since qemu 2.8 , external snapshots (very similar to: > http://wiki.libvirt.org/page/Live-disk-backup-with-active-blockcommit), > freezes block device after: > > # virsh blockcommit (...) > > There is no

Re: [Qemu-devel] [PATCH RFC] qdev: add init order filter

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 13:11, Marcel Apfelbaum wrote: > On 03/09/2017 01:13 PM, Paolo Bonzini wrote: >> >> >> On 09/03/2017 00:59, Michael S. Tsirkin wrote: >>> Allow forcing a specific order of initialization on >>> devices created with -device. >>> Helpful e.g. for built-in devices such as IOMMUs which

Re: [Qemu-devel] [PATCH] intel_iommu: make sure its init before PCI dev

2017-03-09 Thread Paolo Bonzini
On 23/02/2017 16:35, Alex Williamson wrote: > It's the architecture of vfio, the user only gets access to the device > when the container has iommu protection, therefore vfio needs to look > at the device address space to determine if it can share a container > with other devices. Without an iom

Re: [Qemu-devel] What's the next QEMU version after 2.9 ? (or: when is a good point in time to get rid of old interfaces)

2017-03-09 Thread Markus Armbruster
"Daniel P. Berrange" writes: > On Wed, Mar 08, 2017 at 12:22:24PM +0100, Thomas Huth wrote: >> On 08.03.2017 11:03, Peter Maydell wrote: >> > On 8 March 2017 at 09:26, Thomas Huth wrote: >> >> But anyway, the more important thing that keeps me concerned is: Someone >> >> once told me that we sh

Re: [Qemu-devel] [PATCH± SVM I/O permission bitmap for user-level (ring-3) code ignored

2017-03-09 Thread Paolo Bonzini
On 05/03/2017 19:21, Alexander Boettcher wrote: > the SVM I/O permission bitmap for user-level (ring-3) VM code running in > SVM seems to be ignored and causes a GP-fault. (Actual the IO permission > was granted by the kernel via the TSS I/O port permission bitmap). > > After some debugging the

[Qemu-devel] [PATCH v2 1/2] RAMBlocks: qemu_ram_is_shared

2017-03-09 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Provide a helper to say whether a RAMBlock was created as a shared mapping. Signed-off-by: Dr. David Alan Gilbert --- exec.c| 5 + include/exec/cpu-common.h | 1 + 2 files changed, 6 insertions(+) diff --git a/exec.c b/exec.c index aabb03

[Qemu-devel] [PATCH v2 0/2] migration/postcopy: Disable shared RAM

2017-03-09 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Disable postcopy migration when there's shared RAM, we're still figuring out the details. Without this patch there's a chance it might appear to succeed in some cases. Signed-off-by: Dr. David Alan Gilbert v2 Make sure user-only build works (Halil) Dr. David

[Qemu-devel] [PATCH v2 2/2] postcopy: Check for shared memory

2017-03-09 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" Postcopy doesn't support migration of RAM shared with another process yet (we've got a bunch of things to understand). Check for the case and don't allow postcopy to be enabled. Signed-off-by: Dr. David Alan Gilbert --- migration/postcopy-ram.c | 18 +

Re: [Qemu-devel] [PATCH for-2.9] block: Drop unmaintained 'archipelago' driver

2017-03-09 Thread Kevin Wolf
Am 08.03.2017 um 21:02 hat Eric Blake geschrieben: > The driver has failed to build since commit da34e65, in qemu 2.6, > due to a missing include of qapi/error.h for error_setg(). > Since no one has complained in three releases, it is easier to > remove the dead code than to keep it around, especia

Re: [Qemu-devel] [PATCH v2 1/2] RAMBlocks: qemu_ram_is_shared

2017-03-09 Thread Philippe Mathieu-Daudé
On 03/09/2017 10:22 AM, Dr. David Alan Gilbert (git) wrote: From: "Dr. David Alan Gilbert" Provide a helper to say whether a RAMBlock was created as a shared mapping. Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Philippe Mathieu-Daudé --- exec.c| 5 + inclu

Re: [Qemu-devel] [PATCH v2 1/2] RAMBlocks: qemu_ram_is_shared

2017-03-09 Thread Halil Pasic
On 03/09/2017 02:22 PM, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Provide a helper to say whether a RAMBlock was created as a > shared mapping. > > Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Halil Pasic > --- > exec.c| 5 + >

Re: [Qemu-devel] [PATCH 0/6] block: More op blocker fixes

2017-03-09 Thread Eric Blake
On 03/09/2017 05:38 AM, Kevin Wolf wrote: > Kevin Wolf (6): > block: Remove check_new_perm from bdrv_replace_child() > block: Request block status from *file for BDRV_BLOCK_RAW > commit: Implement bdrv_commit_top.bdrv_co_get_block_status > block: Refresh filename after changing backing file

[Qemu-devel] QEMU MicroCheckpointing Pause & Resume Latency

2017-03-09 Thread FENG, Jiasheng
Dear QEMU Development Team, It is my honor to contact with you. I am a postgraduate student from University of Hong Kong. Currently I am working on a project related to QEMU MicroCheckpointing and I have encountered a performance issue during checkpoint pause & resume. Please kindly refer t

Re: [Qemu-devel] [PATCH v7 kernel 3/5] virtio-balloon: implementation of VIRTIO_BALLOON_F_CHUNK_TRANSFER

2017-03-09 Thread Matthew Wilcox
On Fri, Mar 03, 2017 at 01:40:28PM +0800, Wei Wang wrote: > From: Liang Li > 1) allocating pages (6.5%) > 2) sending PFNs to host (68.3%) > 3) address translation (6.1%) > 4) madvise (19%) > > This patch optimizes step 2) by transfering pages to the host in > chunks. A chunk consists of guest phy

Re: [Qemu-devel] QEMU MicroCheckpointing Pause & Resume Latency

2017-03-09 Thread Dr. David Alan Gilbert
* FENG, Jiasheng (nikof...@connect.hku.hk) wrote: > Dear QEMU Development Team, > > > It is my honor to contact with you. > > > > I am a postgraduate student from University of Hong Kong. Currently I am > working on a project related to QEMU MicroCheckpointing and I have > encountered a perfor

[Qemu-devel] [PATCH v2] memory_region: Fix name comments

2017-03-09 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" The 'name' parameter to memory_region_init_* had been marked as debug only, however vmstate_region_ram uses it as a parameter to qemu_ram_set_idstr to set RAMBlock names and these form part of the migration stream. Signed-off-by: Dr. David Alan Gilbert --- v2 Re

Re: [Qemu-devel] [PATCH] intel_iommu: make sure its init before PCI dev

2017-03-09 Thread Michael S. Tsirkin
On Thu, Mar 09, 2017 at 01:31:45PM +0100, Paolo Bonzini wrote: > > > On 23/02/2017 16:35, Alex Williamson wrote: > > It's the architecture of vfio, the user only gets access to the device > > when the container has iommu protection, therefore vfio needs to look > > at the device address space to

Re: [Qemu-devel] [PATCH V3] virtio: do not require IOMMU to be created in advance

2017-03-09 Thread Michael S. Tsirkin
On Thu, Mar 09, 2017 at 11:05:36AM +0100, Paolo Bonzini wrote: > > > On 09/03/2017 10:58, Jason Wang wrote: > > > > > > On 2017年03月09日 17:28, Igor Mammedov wrote: > >> On Thu, 9 Mar 2017 10:32:44 +0800 > >> Jason Wang wrote: > >> > >>> On 2017年03月09日 00:40, Igor Mammedov wrote: > On Tue,

Re: [Qemu-devel] [PATCH] intel_iommu: make sure its init before PCI dev

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 16:29, Michael S. Tsirkin wrote: >> If VFIO had an iommu property, to be used like "-device >> intel_iommu,id=iommu0 -device vfio-pci,iommu=iommu0", It could tell VFIO >> to use separate containers and also ensure proper ordering of command >> line arguments. > > Lots of guests can'

Re: [Qemu-devel] [PATCH V3] virtio: do not require IOMMU to be created in advance

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 16:31, Michael S. Tsirkin wrote: > On Thu, Mar 09, 2017 at 11:05:36AM +0100, Paolo Bonzini wrote: >> >> >> On 09/03/2017 10:58, Jason Wang wrote: >>> >>> >>> On 2017年03月09日 17:28, Igor Mammedov wrote: On Thu, 9 Mar 2017 10:32:44 +0800 Jason Wang wrote: > On 2017年

Re: [Qemu-devel] [PATCH for-2.9 0/3] Fix bdrv_is_allocated usage bugs

2017-03-09 Thread Kevin Wolf
Am 08.03.2017 um 22:34 hat Eric Blake geschrieben: > bdrv_is_allocated() returns tri-state, not just bool, although > there were several callers using it as a bool. Fix them to > either propagate the error or to document why treatment of > failure like allocation is okay. > > [Found during a larg

[Qemu-devel] about restore the pc of the guest code

2017-03-09 Thread oussema ben khedher
hi i search the pc of tb in the guest code i used the function cpu_restore_state_from_tb in cpu_exec_tb but the searching pc take 0 value can someone explain me why searching_pc is 0 or give me some hints thanks

Re: [Qemu-devel] What's the next QEMU version after 2.9 ? (or: when is a good point in time to get rid of old interfaces)

2017-03-09 Thread Kevin Wolf
Am 08.03.2017 um 09:26 hat Thomas Huth geschrieben: > what will be the next version of QEMU after 2.9? Will we go for a 2.10 > (as I've seen it mentioned a couple of times on the mailing list > already), or do we dare to switch to 3.0 instead? > > I personally dislike two-digit minor version numbe

Re: [Qemu-devel] [PATCH v2 2/2] postcopy: Check for shared memory

2017-03-09 Thread Halil Pasic
On 03/09/2017 02:22 PM, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Postcopy doesn't support migration of RAM shared with another process > yet (we've got a bunch of things to understand). > Check for the case and don't allow postcopy to be enabled. > > Signed-off-

Re: [Qemu-devel] [PATCH v2 2/2] postcopy: Check for shared memory

2017-03-09 Thread Dr. David Alan Gilbert
* Halil Pasic (pa...@linux.vnet.ibm.com) wrote: > > > On 03/09/2017 02:22 PM, Dr. David Alan Gilbert (git) wrote: > > From: "Dr. David Alan Gilbert" > > > > Postcopy doesn't support migration of RAM shared with another process > > yet (we've got a bunch of things to understand). > > Check for t

Re: [Qemu-devel] [PATCH v2] memory_region: Fix name comments

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 16:27, Dr. David Alan Gilbert (git) wrote: > + * @name: Region name, becomes part of RAMBlock name used in migration stream > + *must be unique within any device > * @size: size of the region; any subregions beyond this size will be clipped > */ > void memory_region_ini

Re: [Qemu-devel] [PATCH v2] memory_region: Fix name comments

2017-03-09 Thread Dr. David Alan Gilbert
* Paolo Bonzini (pbonz...@redhat.com) wrote: > > > On 09/03/2017 16:27, Dr. David Alan Gilbert (git) wrote: > > + * @name: Region name, becomes part of RAMBlock name used in migration > > stream > > + *must be unique within any device > > * @size: size of the region; any subregions bey

Re: [Qemu-devel] [PATCH v2] memory_region: Fix name comments

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 17:13, Dr. David Alan Gilbert wrote: >>> + * @name: Region name, becomes part of RAMBlock name used in migration >>> stream >>> + *must be unique within any device >>> * @size: size of the region; any subregions beyond this size will be >>> clipped >>> */ >>> void mem

Re: [Qemu-devel] [PATCH] X86/HMP: Expose x86 model specific registers via human monitor

2017-03-09 Thread Paolo Bonzini
On 08/03/2017 19:44, Eduardo Habkost wrote: >>> If it's only supported by x86, I would just move the >>> implementation to a x86-specific file, and add a stub for the >>> other architectures. See qmp_query_gic_capabilities() for an >>> example. >>> >>> Also, the command should be added to >>> qmp

Re: [Qemu-devel] [PATCH] memory: reduce heap Rss size around 3M

2017-03-09 Thread Paolo Bonzini
On 08/03/2017 12:17, Philippe Mathieu-Daudé wrote: > On 03/08/2017 12:11 PM, Yang Zhong wrote: >> Since cpu-memory and memory have same address space,one malloced >> memory is enough. This patch will skip memory malloc for memory >> address space,which will reduce around 3M physical memory in hea

Re: [Qemu-devel] [PATCH v2] memory_region: Fix name comments

2017-03-09 Thread Dr. David Alan Gilbert
* Paolo Bonzini (pbonz...@redhat.com) wrote: > > > On 09/03/2017 17:13, Dr. David Alan Gilbert wrote: > >>> + * @name: Region name, becomes part of RAMBlock name used in migration > >>> stream > >>> + *must be unique within any device > >>> * @size: size of the region; any subregions b

Re: [Qemu-devel] QEMU MicroCheckpointing Pause & Resume Latency

2017-03-09 Thread FENG, Jiasheng
Dear David, Really appreciate your feedback. I have proceeded the experiments in both conditions, and no matter the vCPUs are in idle or busy situation, there is no difference that smp_wmb() will consume a lot of time to proceed its work. In your opinion, may I know that what is the alternative

Re: [Qemu-devel] [PATCH/RFC] exec: add cpu_synchronize_state to cpu_memory_rw_debug

2017-03-09 Thread Paolo Bonzini
On 07/03/2017 15:19, Christian Borntraeger wrote: > I sometimes got "Cannot access memory" when using the x command > on the monitor. Turns out that the cpu env did contain stale data > (e.g. wrong control register content for page table origin). > We must synchronize the state of the CPU before

Re: [Qemu-devel] about restore the pc of the guest code

2017-03-09 Thread Alex Bennée
oussema ben khedher writes: > hi > > i search the pc of tb in the guest code i used the function > cpu_restore_state_from_tb in cpu_exec_tb but the searching pc take 0 > value can someone explain me why searching_pc is 0 or give me some > hints Have you got a backtrace of how you got there? --

Re: [Qemu-devel] [PATCH v2 2/2] postcopy: Check for shared memory

2017-03-09 Thread Halil Pasic
On 03/09/2017 05:06 PM, Dr. David Alan Gilbert wrote: > * Halil Pasic (pa...@linux.vnet.ibm.com) wrote: >> >> >> On 03/09/2017 02:22 PM, Dr. David Alan Gilbert (git) wrote: >>> From: "Dr. David Alan Gilbert" >>> >>> Postcopy doesn't support migration of RAM shared with another process >>> yet (w

Re: [Qemu-devel] QEMU MicroCheckpointing Pause & Resume Latency

2017-03-09 Thread Dr. David Alan Gilbert
(cc'ing in Paolo since he knows our barrier code) * FENG, Jiasheng (nikof...@connect.hku.hk) wrote: > Dear David, > > Really appreciate your feedback. > > I have proceeded the experiments in both conditions, and no matter the > vCPUs are in idle or busy situation, there is no difference that smp

[Qemu-devel] [PATCH] hw/arm/boot: take Linux/arm64 TEXT_OFFSET header field into account

2017-03-09 Thread Ard Biesheuvel
The arm64 boot protocol stipulates that the kernel must be loaded TEXT_OFFSET bytes beyond a 2 MB aligned base address, where TEXT_OFFSET could be any 4 KB multiple between 0 and 2 MB, and whose value can be found in the header of the Image file. So after attempts to load the kernel image as an EL

Re: [Qemu-devel] QEMU MicroCheckpointing Pause & Resume Latency

2017-03-09 Thread nikofeng
Dear David, Yes, it is a normal x86 PC server. Thanks so much for your help and hope to receive your following feedback. Best Regards, Niko Jiasheng Feng Sent from Mail for Windows 10 From: Dr. David Alan Gilbert Sent: Friday, March 10, 2017 1:06 AM To: FENG, Jiasheng Cc: qemu-devel@nongnu.org

[Qemu-devel] [PATCH] SGABIOS: fix wrong video attrs for int 10h, ah==13h

2017-03-09 Thread herbierobinson
Fix Bug #1670509: wrong video attrs for int 10h, ah==13h The subroutine set_cursor_position is trashing %bx. Unfortunately, %bl contains the video attribute for write_string. The fix saves %bx in the function prolog and restores it in the epilog. Also, remove save and restore in set_current_curso

Re: [Qemu-devel] [PATCH] hw/arm/boot: take Linux/arm64 TEXT_OFFSET header field into account

2017-03-09 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Type: series Subject: [Qemu-devel] [PATCH] hw/arm/boot: take Linux/arm64 TEXT_OFFSET header field into account Message-id: 1489079383-11162-1-git-send-email-ard.biesheu...@linaro.org === TEST SCRIPT

Re: [Qemu-devel] QEMU MicroCheckpointing Pause & Resume Latency

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 18:06, Dr. David Alan Gilbert wrote: > (cc'ing in Paolo since he knows our barrier code) > > * FENG, Jiasheng (nikof...@connect.hku.hk) wrote: >> Dear David, >> >> Really appreciate your feedback. >> >> I have proceeded the experiments in both conditions, and no matter the >> vCPUs

Re: [Qemu-devel] [PATCH 0/6] tcg: fix icount super slowdown

2017-03-09 Thread Alex Bennée
Paolo Bonzini writes: Hmm your subject line was: Subject: [PATCH 0/6] tcg: fix icount super slowdown But: > Paolo Bonzini (5): > qemu-timer: fix off-by-one > qemu-timer: do not include sysemu/cpus.h from util/qemu-timer.h > cpus: define QEMUTimerListNotifyCB for QEMU system emulation

Re: [Qemu-devel] [PATCH 0/6] tcg: fix icount super slowdown

2017-03-09 Thread Paolo Bonzini
On 09/03/2017 18:19, Alex Bennée wrote: > > Hmm your subject line was: > > Subject: [PATCH 0/6] tcg: fix icount super slowdown > > But: > >> Paolo Bonzini (5): >> qemu-timer: fix off-by-one >> qemu-timer: do not include sysemu/cpus.h from util/qemu-timer.h >> cpus: define QEMUTimerLis

  1   2   >