Re: [Qemu-devel] [PATCH v5 0/5] Geometry and blocksize detection for backing devices.

2015-01-13 Thread Christian Borntraeger
Am 02.01.2015 um 13:57 schrieb Stefan Hajnoczi: > On Thu, Dec 18, 2014 at 04:59:50PM +0100, Christian Borntraeger wrote: >> Are you ok with the patches? If yes, can you take care of these patches in >> the block tree? > > This series looks close, I've left comments on the patches. OK, so you wou

Re: [Qemu-devel] [PATCH 2/3] configure: Default to enable module build

2015-01-13 Thread Fam Zheng
On Mon, 01/12 11:26, Andreas Färber wrote: > Am 12.01.2015 um 05:43 schrieb Fam Zheng: > > We have module build support around for a while, but also had it bitrot > > several times. It probably makes sense to enable it by default so that > > people can notice and use it. > > > > Counterpart to --e

Re: [Qemu-devel] [PATCH 01/14] libqos: Split apart pc_alloc_init

2015-01-13 Thread Marc Marí
El Mon, 12 Jan 2015 22:34:26 -0500 John Snow escribió: > Move the list-specific initialization over into > malloc.c, to keep all of the list implementation > details within the same file. > > The allocation and freeing of these structures are > now both back within the same layer. > > Signed-off

[Qemu-devel] [PATCH v2 0/2] buildsys: Fix and enable module build

2015-01-13 Thread Fam Zheng
v2: Fix on error handling nit in configure. (Andreas) Skip rules.mak fix because Paolo applied it. Fam Fam Zheng (2): configure: Default to enable module build .travis.yml: Add "--disable-modules" .travis.yml | 3 ++ configure | 95 ++-

[Qemu-devel] [PATCH v2 1/2] configure: Default to enable module build

2015-01-13 Thread Fam Zheng
We have module build support around for a while, but also had it bitrot several times. It probably makes sense to enable it by default so that people can notice and use it. Counterpart to --enable-modules, which is turned as default, --disable-modules is added to suppress it. If both are omitted,

Re: [Qemu-devel] [libvirt] should active block commit ever be allowed to show 0 total progress?

2015-01-13 Thread Michal Privoznik
On 12.01.2015 23:31, Eric Blake wrote: I was trying to work on a libvirt bug, when I discovered the following: $ qemu-img create -f qcow2 a.qcow2 10M Formatting 'a.qcow2', fmt=qcow2 size=10485760 encryption=off cluster_size=65536 lazy_refcounts=off $ qemu-img create -f qcow2 \ -obacking_file=

[Qemu-devel] [PATCH v2 2/2] .travis.yml: Add "--disable-modules"

2015-01-13 Thread Fam Zheng
Now we default to "--enable-modules", let's cover the old way in travis. Signed-off-by: Fam Zheng --- .travis.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.travis.yml b/.travis.yml index ad66e5b..12bf1db 100644 --- a/.travis.yml +++ b/.travis.yml @@ -98,3 +98,6 @@ matrix:

[Qemu-devel] Linux 3.4, VersatilePB and PCI

2015-01-13 Thread Marc Marí
Hi In short: I have a Linux 3.4 kernel on top of a VersatilePB machine that fails to mount root file system with message: sym53c8xx :00:0c.0: BAR 0: can't reserve [io 0x4400-0x44ff] after booting with: qemu-system-arm -M versatilepb -serial telnet::,server -kernel vmlinuz-3.4.0

Re: [Qemu-devel] [PATCH 0/1] pci: allow 0 address for PCI IO/MEM regions

2015-01-13 Thread Claudio Fontana
On 13.01.2015 06:46, David Gibson wrote: > On Mon, Jan 12, 2015 at 07:24:06AM -0600, Michael Roth wrote: >> Quoting Michael Roth (2014-12-23 13:33:35) >>> This patch enables the programming of address 0 for IO/MMIO BARs for >>> PCI devices. >>> >>> It was originally included as part of a series imp

Re: [Qemu-devel] [RFC PATCH v7 15/21] replay: checkpoints

2015-01-13 Thread Pavel Dovgaluk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 12/01/2015 13:01, Pavel Dovgalyuk wrote: > > +default: > > +case QEMU_CLOCK_VIRTUAL: > > +if ((replay_mode != REPLAY_MODE_NONE && !runstate_is_running()) > > +|| !replay_checkpoint(run_all ? 2 : 3)) { > > +

Re: [Qemu-devel] [PATCH 2/4] pci: Add generic PCIe host bridge

2015-01-13 Thread Claudio Fontana
On 12.01.2015 22:20, Peter Maydell wrote: > On 12 January 2015 at 21:06, Alexander Graf wrote: >> >> >> On 12.01.15 21:08, Peter Maydell wrote: >>> On 12 January 2015 at 17:38, Alexander Graf wrote: I'd prefer to keep things as easy as we humanly can for now. Then add MSI. And if we the

Re: [Qemu-devel] [RFC PATCH v7 15/21] replay: checkpoints

2015-01-13 Thread Pavel Dovgaluk
> From: Pavel Dovgaluk [mailto:pavel.dovga...@ispras.ru] > > From: Paolo Bonzini [mailto:pbonz...@redhat.com] > > On 12/01/2015 13:01, Pavel Dovgalyuk wrote: > > > +default: > > > +case QEMU_CLOCK_VIRTUAL: > > > +if ((replay_mode != REPLAY_MODE_NONE && !runstate_is_running()) > > >

Re: [Qemu-devel] [PATCH 9/9] block-migration: add named dirty bitmaps migration

2015-01-13 Thread Vladimir Sementsov-Ogievskiy
On 12.01.2015 17:42, Paolo Bonzini wrote: On 12/01/2015 15:20, Vladimir Sementsov-Ogievskiy wrote: On 09.01.2015 01:36, Paolo Bonzini wrote: The bitmaps are transmitted many times in their entirety, but only the last copy actually means something. The others are lost. This means you should use

Re: [Qemu-devel] [RFC PATCH v7 12/21] replay: recording and replaying clock ticks

2015-01-13 Thread Pavel Dovgaluk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 12/01/2015 13:00, Pavel Dovgalyuk wrote: > > +/*! Reads next clock event from the input. */ > > +int64_t replay_read_clock(unsigned int kind) > > +{ > > +if (kind >= REPLAY_CLOCK_COUNT) { > > +fprintf(stderr, "invalid clock ID %d f

Re: [Qemu-devel] [PATCH v11 08/13] block: Add bitmap successors

2015-01-13 Thread Fam Zheng
On Mon, 01/12 11:31, John Snow wrote: > A bitmap successor is an anonymous BdrvDirtyBitmap that is intended to > be created just prior to a sensitive operation (e.g. Incremental Backup) > that can either succeed or fail, but during the course of which we still > want a bitmap tracking writes. > >

Re: [Qemu-devel] [PATCH v11 09/13] qmp: Add support of "dirty-bitmap" sync mode for drive-backup

2015-01-13 Thread Fam Zheng
On Mon, 01/12 11:31, John Snow wrote: > For "dirty-bitmap" sync mode, the block job will iterate through the > given dirty bitmap to decide if a sector needs backup (backup all the > dirty clusters and skip clean ones), just as allocation conditions of > "top" sync mode. > > Signed-off-by: Fam Zhe

Re: [Qemu-devel] Question regarding two variables in qemu migration code

2015-01-13 Thread Dr. David Alan Gilbert
* Jidong Xiao (jidong.x...@gmail.com) wrote: > Hi, Hi, > I am looking at the qemu source code, and trying to understand the > migration part. In arch_init.c, there are two variables which seems > quite confusing to me, > > They are: > > static uint64_t migration_dirty_pages; 'migration_dirty_p

Re: [Qemu-devel] [PATCH] vl.c: optimized code format

2015-01-13 Thread Markus Armbruster
Zhang Min writes: > From: Rudy Zhang > > There are several tab characters in the 'vl.c' file. It leads to > to misalignment of the code. So, let the space instead of the tab. > > Signed-off-by: Rudy Zhang While we don't want tabs in new code, we generally leave existing ones alone until we nee

Re: [Qemu-devel] [RFC PATCH v7 12/21] replay: recording and replaying clock ticks

2015-01-13 Thread Paolo Bonzini
On 13/01/2015 10:21, Pavel Dovgaluk wrote: >>> +/*! Reads next clock event from the input. */ >>> > > +int64_t replay_read_clock(unsigned int kind) >>> > > +{ >>> > > +if (kind >= REPLAY_CLOCK_COUNT) { >>> > > +fprintf(stderr, "invalid clock ID %d for replay\n", kind); >>> > > +

Re: [Qemu-devel] [RFC PATCH v7 15/21] replay: checkpoints

2015-01-13 Thread Paolo Bonzini
On 13/01/2015 10:15, Pavel Dovgaluk wrote: > The numbers have no meaning. They just have to be distinct in different > places. This is easier to achieve if you give a name to each place. > Sorry, missed one thing. > run_all is used to distinguish timers processed in AIO by calling of > timerl

Re: [Qemu-devel] question about live migration with storage

2015-01-13 Thread Paolo Bonzini
On 13/01/2015 03:03, Zhang Haoyu wrote: > >I want to live migrate a vm with storage, with regard to the migration of > >storage, > >should I use drive_mirror or traditional mechanism implemented in > >block-migration.c ? > > Because I don't use libvirtd to manage vm, > if I want to use drive_m

Re: [Qemu-devel] [PATCH v10 06/13] block: Add bdrv_copy_dirty_bitmap and bdrv_clear_dirty_bitmap

2015-01-13 Thread Vladimir Sementsov-Ogievskiy
Hmm, can't find it in v11 Best regards, Vladimir On 10.01.2015 06:25, John Snow wrote: On 12/30/2014 08:47 AM, Vladimir Sementsov-Ogievskiy wrote: I'm sorry if it was already discussed, but I think it is inconsistent to have "size" in sectors and "granularity" in bytes in one structure. I've

Re: [Qemu-devel] [PATCH v5 0/5] Geometry and blocksize detection for backing devices.

2015-01-13 Thread Ekaterina Tumanova
On 01/02/2015 02:30 PM, Stefan Hajnoczi wrote: On Thu, Dec 18, 2014 at 12:17:59PM +0100, Ekaterina Tumanova wrote: Updates v4 -> v5: Minor Updates according the last review from Markus: 1. update commit message for patch 2 2. fix comment typos 3. fix check_for_dasd to return -1 instead of -ENOT

Re: [Qemu-devel] [PATCH v5 2/5] raw-posix: Refactor logical block size detection.

2015-01-13 Thread Ekaterina Tumanova
On 01/02/2015 02:52 PM, Stefan Hajnoczi wrote: On Thu, Dec 18, 2014 at 12:18:01PM +0100, Ekaterina Tumanova wrote: +#if defined(BLKSSZGET) +# define SECTOR_SIZE BLKSSZGET +#elif defined(DKIOCGETBLOCKSIZE) +# define SECTOR_SIZE DKIOCGETBLOCKSIZE +#elif defined(DIOCGSECTORSIZE) +# define SECTOR

Re: [Qemu-devel] Linux 3.4, VersatilePB and PCI

2015-01-13 Thread Peter Maydell
On 13 January 2015 at 09:05, Marc Marí wrote: > Hi > > In short: > I have a Linux 3.4 kernel on top of a VersatilePB machine that > fails to mount root file system with message: > > sym53c8xx :00:0c.0: BAR 0: can't reserve [io 0x4400-0x44ff] > > after booting with: > > qemu-system-arm

Re: [Qemu-devel] [PATCH 2/4] pci: Add generic PCIe host bridge

2015-01-13 Thread Peter Maydell
On 13 January 2015 at 00:13, Alexander Graf wrote: > My main problem with multiple IRQs is that we'd have to describe the > mapping. This is true... > I'd rather not have a fixed number of PCI slots hardcoded > anywhere, especially not in the map. ...but this doesn't follow. What you do is the

Re: [Qemu-devel] [PATCH 0/1] pci: allow 0 address for PCI IO/MEM regions

2015-01-13 Thread Michael S. Tsirkin
On Mon, Jan 12, 2015 at 07:24:06AM -0600, Michael Roth wrote: > Quoting Michael Roth (2014-12-23 13:33:35) > > This patch enables the programming of address 0 for IO/MMIO BARs for > > PCI devices. > > > > It was originally included as part of a series implementing PCI > > hotplug for pseries guest

Re: [Qemu-devel] [PATCH v2 0/8] qemu: guest agent: implement guest-exec command for Linux

2015-01-13 Thread Denis V. Lunev
On 09/01/15 22:29, Michael Roth wrote: Quoting Denis V. Lunev (2015-01-09 12:09:10) On 09/01/15 20:06, Michael Roth wrote: Quoting Denis V. Lunev (2014-12-31 07:06:46) hese patches for guest-agent add the functionality to execute commands on a guest UNIX machine. Hi Denis, Glad to see these

Re: [Qemu-devel] Linux 3.4, VersatilePB and PCI

2015-01-13 Thread Marc Marí
El Tue, 13 Jan 2015 10:06:00 + Peter Maydell escribió: > On 13 January 2015 at 09:05, Marc Marí > wrote: > > Hi > > > > In short: > > I have a Linux 3.4 kernel on top of a VersatilePB machine that > > fails to mount root file system with message: > > > > sym53c8xx :00:0c.0: BAR 0: can't r

Re: [Qemu-devel] Linux 3.4, VersatilePB and PCI

2015-01-13 Thread Peter Maydell
On 13 January 2015 at 10:35, Marc Marí wrote: > I was fearing that answer :). No, I can't. I want to compare the > behaviour of a "normal" Linux 3.4 with another modified Linux 3.4, and > the second one is fixed. > > And is not that ancient, it only has 2.5 years :) In that case you'll need to de

Re: [Qemu-devel] [PATCH v5 0/5] Geometry and blocksize detection for backing devices.

2015-01-13 Thread Markus Armbruster
Christian Borntraeger writes: > Am 02.01.2015 um 13:57 schrieb Stefan Hajnoczi: >> On Thu, Dec 18, 2014 at 04:59:50PM +0100, Christian Borntraeger wrote: >>> Are you ok with the patches? If yes, can you take care of these >>> patches in the block tree? >> >> This series looks close, I've left co

Re: [Qemu-devel] Linux 3.4, VersatilePB and PCI

2015-01-13 Thread Marc Marí
El Tue, 13 Jan 2015 10:46:20 + Peter Maydell escribió: > On 13 January 2015 at 10:35, Marc Marí > wrote: > > I was fearing that answer :). No, I can't. I want to compare the > > behaviour of a "normal" Linux 3.4 with another modified Linux 3.4, > > and the second one is fixed. > > > > And is

Re: [Qemu-devel] [v2] xen-pt: Fix PCI devices re-attach failed

2015-01-13 Thread Stefano Stabellini
On Tue, 13 Jan 2015, Liang Li wrote: > Use the 'xl pci-attach $DomU $BDF' command to attach more than > one PCI devices to the guest, then detach the devices with > 'xl pci-detach $DomU $BDF', after that, re-attach these PCI > devices again, an error message will be reported like following: > >

Re: [Qemu-devel] Press Inquiry: Qemu Advent Calendar (German Linux Magazin)

2015-01-13 Thread Tim Schürmann
Hi, first of all, sorry for the late answer and thanks for your quick reply. The http://qemu-advent-calendar.org/ website has credits for each disk image showing who created the image. For example, "Disk image prepared by Alexander Graf, game by Jochen Voss". Please include the credits. Sur

Re: [Qemu-devel] Press Inquiry: Qemu Advent Calendar (German Linux Magazin)

2015-01-13 Thread Gerd Hoffmann
Hi, > > The Zork UEFI image requires internet access because the Zork game > > binary is *not* freely redistributable. When you run the image it > > prompts the user to download the Zork binary since we are not allowed to > > distribute it ourselves. > > I will note this in the HTML menu on th

Re: [Qemu-devel] [PATCH] vl.c: optimized code format

2015-01-13 Thread Stefan Weil
Am 13.01.2015 um 10:38 schrieb Markus Armbruster: Zhang Min writes: From: Rudy Zhang There are several tab characters in the 'vl.c' file. It leads to to misalignment of the code. So, let the space instead of the tab. Signed-off-by: Rudy Zhang While we don't want tabs in new code, we gener

Re: [Qemu-devel] [PATCH 4/9] hbitmap: store / restore

2015-01-13 Thread Vladimir Sementsov-Ogievskiy
Best regards, Vladimir On 09.01.2015 00:21, John Snow wrote: On 12/11/2014 09:17 AM, Vladimir Sementsov-Ogievskiy wrote: Functions to store / restore HBitmap. HBitmap should be saved to linear bitmap format independently of endianess. Because of restoring in several steps, every step writes

[Qemu-devel] [PATCH] vl: Fix bogus error message for implied mon ID clashing

2015-01-13 Thread Markus Armbruster
monitor_parse() desugars --monitor, --qmp and -qmp-pretty to --mon. The ID it picks can clash with a user-specified ID. When it happens, the error message is misleading. Reproducer: $ qemu --mon id=compat_monitor0 --monitor stdio Message before the patch: duplicate chardev: compat_moni

Re: [Qemu-devel] [PULL v2 00/44] Block patches

2015-01-13 Thread Stefan Hajnoczi
On Mon, Jan 12, 2015 at 09:43:28PM +, Peter Maydell wrote: > On 12 January 2015 at 16:39, Stefan Hajnoczi wrote: > > The following changes since commit 64ea8038ffbf703dcd438a108d2d5499c8ff95d9: > > > > Merge remote-tracking branch > > 'remotes/awilliam/tags/vfio-update-20150109.0' into stag

[Qemu-devel] nested VMX with IA32_FEATURE_CONTROL MSR(addr: 0x3a) value of ZERO

2015-01-13 Thread Huaicheng Li
Hi, all I have a Linux 3.8 kernel (host) and run QEMU 1.5.3 on it. I want to test another hypervisor software in qemu so I enabled KVM's nested VMX function(by passing "nested=1" parameter to the kvm module) and then started a guest machine. In the guest, I could see the "vmx" instruction set by r

Re: [Qemu-devel] nested VMX with IA32_FEATURE_CONTROL MSR(addr: 0x3a) value of ZERO

2015-01-13 Thread Paolo Bonzini
On 13/01/2015 14:19, Huaicheng Li wrote: > Hi, all > > I have a Linux 3.8 kernel (host) and run QEMU 1.5.3 on it. I want to > test another hypervisor software in qemu so I enabled KVM's nested VMX > function(by passing "nested=1" parameter to the kvm module) and then > started a guest machine. I

[Qemu-devel] [PULL v3 00/38] Block patches

2015-01-13 Thread Stefan Hajnoczi
The following changes since commit 7d5ad15d17f26dd4f9ff5f3491828bc34e74f28c: Merge remote-tracking branch 'remotes/stefanha/tags/net-pull-request' into staging (2015-01-12 11:13:24 +) are available in the git repository at: git://github.com/stefanha/qemu.git tags/block-pull-request for

[Qemu-devel] [PULL v3 02/38] qemu-iotests: Speed up make check-block

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng Using /tmp, which is usually mounted as tmpfs, the quick group can be quicker. On my laptop (Lenovo T430s with Fedora 20), this reduces the time from 50s to 30s. Signed-off-by: Fam Zheng Reviewed-by: Max Reitz Signed-off-by: Kevin Wolf --- tests/qemu-iotests-quick.sh | 2 +-

[Qemu-devel] [PULL v3 05/38] block: replace g_new0 with g_new for bottom half allocation.

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini This saves about 15% of the clock cycles spent on allocation. Using the slice allocator does not add a visible improvement; allocation is faster than malloc, while freeing seems to be slower. Signed-off-by: Paolo Bonzini Signed-off-by: Kevin Wolf --- async.c | 10 ++--

[Qemu-devel] [PULL v3 03/38] block: mark AioContext as recursive

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini AioContext can be accessed recursively, in fact that's what we do with aio_poll. Marking the GSource as recursive avoids that GLib blocks it and unblocks it around every call to aio_dispatch, which is a pretty expensive operation. Signed-off-by: Paolo Bonzini Signed-off-by:

[Qemu-devel] [PULL v3 01/38] qemu-iotests: Remove 091 from quick group

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng For the purpose of allowing running quick group on tmpfs. Signed-off-by: Fam Zheng Signed-off-by: Kevin Wolf --- 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 a4742c6..0809

[Qemu-devel] [PULL v3 06/38] checkpatch: Brace handling on multi-line condition

2015-01-13 Thread Stefan Hajnoczi
From: Max Reitz CODING_STYLE states the following about braces around blocks: > The opening brace is on the line that contains the control flow > statement that introduces the new block; [...] This is obviously impossible with multi-line conditions. Therefore, CODING_STYLE does not make any cle

[Qemu-devel] [PULL v3 09/38] block: Relative backing file for image creation

2015-01-13 Thread Stefan Hajnoczi
From: Max Reitz Relative backing filenames are always relative to the backed image's directory; the same applies to image creation. Therefore, if the backing file has to be opened for determining its size (in case the size has not been explicitly specified) its filename should be interpreted rela

[Qemu-devel] [PULL v3 07/38] block: Get full backing filename from string

2015-01-13 Thread Stefan Hajnoczi
From: Max Reitz Introduce bdrv_get_full_backing_filename_from_filename(), a function which takes the name of the backed file and a potentially relative backing filename to produce the full (absolute) backing filename. Use this function from bdrv_get_full_backing_filename(). Signed-off-by: Max R

[Qemu-devel] [PULL v3 13/38] block: fix spoiling all dirty bitmaps by mirror and migration

2015-01-13 Thread Stefan Hajnoczi
From: Vladimir Sementsov-Ogievskiy Mirror and migration use dirty bitmaps for their purposes, and since commit [block: per caller dirty bitmap] they use their own bitmaps, not the global one. But they use old functions bdrv_set_dirty and bdrv_reset_dirty, which change all dirty bitmaps. Named di

[Qemu-devel] [PULL v3 04/38] block: do not allocate an iovec per read of a growable/zero_after_eof BDS

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini Most reads do not go past the end of the file, and they can use the input QEMUIOVector instead of creating one. This removes the qemu_iovec_* functions from the profile. Signed-off-by: Paolo Bonzini Signed-off-by: Kevin Wolf --- block.c | 12 +--- 1 file changed,

[Qemu-devel] [PULL v3 08/38] block: JSON filenames and relative backing files

2015-01-13 Thread Stefan Hajnoczi
From: Max Reitz When using a relative backing file name, qemu needs to know the directory of the top image file. For JSON filenames, such a directory cannot be easily determined (e.g. how do you determine the directory of a qcow2 BDS directly on top of a quorum BDS?). Therefore, do not allow rela

[Qemu-devel] [PULL v3 22/38] qemu-iotests: Replace "/bin/true" with "true"

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng The former is not portable because on Mac OSX it is /usr/bin/true. Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- tests/qemu-iotests/common.config | 2 +- tests/qemu-iotests/common.filter | 2 +- tests/qemu-iotests/common.rc | 2 +- 3 files changed, 3 insertio

[Qemu-devel] [PULL v3 15/38] qmp: Add command 'blockdev-backup'

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng Similar to drive-backup, but this command uses a device id as target instead of creating/opening an image file. Also add blocker on target bs, since the target is also a named device now. Add check and report error for bs == target which became possible but is an illegal case wi

[Qemu-devel] [PULL v3 10/38] block/vmdk: Relative backing file for creation

2015-01-13 Thread Stefan Hajnoczi
From: Max Reitz When a vmdk image is created with a backing file, it is opened to check whether it is indeed a vmdk file by letting qemu probe it. When doing so, the backing filename is relative to the image's base directory so it should be interpreted accordingly. Signed-off-by: Max Reitz Revi

[Qemu-devel] [PULL v3 16/38] block: Add blockdev-backup to transaction

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng Signed-off-by: Fam Zheng Reviewed-by: John Snow Reviewed-by: Max Reitz Reviewed-by: Markus Armbruster Message-id: 1418899027-8445-4-git-send-email-f...@redhat.com Signed-off-by: Max Reitz --- blockdev.c | 79 qap

[Qemu-devel] [PULL v3 25/38] coroutine-ucontext: use __thread

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini ELF thread local storage is about 10% faster on tests/test-coroutine's perf/cost test. The timing on my machine is 190ns per iteration with pthread TLS, 170 with ELF TLS. Based on a patch by Kevin Wolf and Peter Lieven, but redone to follow the model of coroutine-win32.c (in

[Qemu-devel] [PULL v3 19/38] migration/block: fix pending() return value

2015-01-13 Thread Stefan Hajnoczi
From: Vladimir Sementsov-Ogievskiy Because of wrong return value of .save_live_pending() in migration/block.c, migration finishes before the whole disk is transferred. Such situation occurs when the migration process is fast enough, for example when source and dest are on the same host. If in th

[Qemu-devel] [PULL v3 11/38] iotests: Add test for relative backing file names

2015-01-13 Thread Stefan Hajnoczi
From: Max Reitz Sometimes, qemu does not have a filename to work with, so it does not know which directory to use for a backing file specified by a relative filename. Add a test which tests that qemu exits with an appropriate error message. Additionally, add a test for qemu-img create with a bac

[Qemu-devel] [PULL v3 17/38] qemu-iotests: Test blockdev-backup in 055

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng This applies cases on drive-backup on blockdev-backup, except cases with target format and mode. Also add a case to check source == target. Signed-off-by: Fam Zheng Reviewed-by: Max Reitz Reviewed-by: Markus Armbruster Message-id: 1418899027-8445-5-git-send-email-f...@redhat.

[Qemu-devel] [PULL v3 28/38] QSLIST: add lock-free operations

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini These operations are trivial to implement and do not have ABA problems. They are enough to implement simple multiple-producer, single consumer lock-free lists or, as in the next patch, the multiple consumers can steal a whole batch of elements and process them at their leisure

[Qemu-devel] [PULL v3 14/38] qapi: Comment version info in TransactionAction

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng Signed-off-by: Fam Zheng Reviewed-by: Eric Blake Reviewed-by: Max Reitz Reviewed-by: Markus Armbruster Message-id: 1418899027-8445-2-git-send-email-f...@redhat.com Signed-off-by: Max Reitz --- qapi-schema.json | 6 ++ 1 file changed, 6 insertions(+) diff --git a/qapi-sc

[Qemu-devel] [PULL v3 23/38] qemu-iotests: Add "_supported_os Linux" to 058

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng Other cases have this, and this test is not portable as well, as we want to add "make check-block" to "make check", it shouldn't fail on Mac OS X. Reported-by: Peter Maydell Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- tests/qemu-iotests/058 | 1 + 1 file chang

[Qemu-devel] [PULL v3 24/38] qemu-iotests: Add supported os parameter for python tests

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng If I understand correctly, qemu-iotests never meant to be portable. We only support Linux for all the shell cases, but didn't specify it for python tests. Now add this and default all the python tests as Linux only. If we cares enough later, we can override the parameter in indivi

Re: [Qemu-devel] [PATCH v5] block: add event when disk usage exceeds threshold

2015-01-13 Thread Francesco Romani
- Original Message - > From: "Stefan Hajnoczi" > To: "Francesco Romani" > Cc: qemu-devel@nongnu.org, kw...@redhat.com, lcapitul...@redhat.com, > mdr...@linux.vnet.ibm.com, ebl...@redhat.com > Sent: Tuesday, January 13, 2015 2:54:41 PM > Subject: Re: [PATCH v5] block: add event when disk

[Qemu-devel] [PULL v3 12/38] qapi: Fix document for BlockStats.node-name

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng Signed-off-by: Fam Zheng Reviewed-by: Eric Blake Message-id: 1418694024-26498-1-git-send-email-f...@redhat.com Signed-off-by: Max Reitz --- qapi/block-core.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qapi/block-core.json b/qapi/block-core.json inde

[Qemu-devel] [PULL v3 30/38] coroutine: drop qemu_coroutine_adjust_pool_size

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini This is not needed anymore. The new TLS-based algorithm is adaptive. Signed-off-by: Paolo Bonzini Reviewed-by: Fam Zheng Message-id: 1417518350-6167-7-git-send-email-pbonz...@redhat.com Signed-off-by: Stefan Hajnoczi --- block/block-backend.c | 4 include/block

[Qemu-devel] [PULL v3 29/38] coroutine: rewrite pool to avoid mutex

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini This patch removes the mutex by using fancy lock-free manipulation of the pool. Lock-free stacks and queues are not hard, but they can suffer from the ABA problem so they are better avoided unless you have some deferred reclamation scheme like RCU. Otherwise you have to stic

[Qemu-devel] [PULL v3 18/38] iotests: Filter out "I/O thread spun..." warning

2015-01-13 Thread Stefan Hajnoczi
From: Max Reitz Filter out the "main loop: WARNING: I/O thread spun for..." warning from qemu output (it hardly matters for code specifically testing I/O). Furthermore, use _filter_qemu in all the custom functions which run qemu. Signed-off-by: Max Reitz Signed-off-by: Kevin Wolf --- tests/q

[Qemu-devel] [PULL v3 32/38] block: limited request size in write zeroes unsupported path

2015-01-13 Thread Stefan Hajnoczi
From: Peter Lieven If bs->bl.max_write_zeroes is large and we end up in the unsupported path we might allocate a lot of memory for the iovector and/or even generate an oversized requests. Fix this by limiting the request by the minimum of the reported maximum transfer size or 16MB (32768 sectors

[Qemu-devel] [PULL v3 27/38] test-coroutine: avoid overflow on 32-bit systems

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini unsigned long is not large enough to represent 10 * duration there. Just use floating point. Signed-off-by: Paolo Bonzini Reviewed-by: Fam Zheng Message-id: 1417518350-6167-4-git-send-email-pbonz...@redhat.com Signed-off-by: Stefan Hajnoczi --- tests/test-coroutin

[Qemu-devel] [PULL v3 36/38] MAINTAINERS: Update email addresses for Chrysostomos Nanakos

2015-01-13 Thread Stefan Hajnoczi
From: Chrysostomos Nanakos Remove first email address and let the one from which I am contributing. Signed-off-by: Chrysostomos Nanakos Signed-off-by: Stefan Hajnoczi --- MAINTAINERS | 1 - 1 file changed, 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index 29c6834..cd7b04f 100644 ---

[Qemu-devel] [PULL v3 21/38] .gitignore: Ignore generated "common.env"

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index e32a584..090f974 100644 --- a/.gitignore +++ b/.gitignore @@ -109,3 +109,4 @@ cscope.* tags TAGS *~ +/tests/qemu-iotests/c

[Qemu-devel] [PULL v3 33/38] block: Split BLOCK_OP_TYPE_COMMIT to BLOCK_OP_TYPE_COMMIT_{SOURCE, TARGET}

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng Like BLOCK_OP_TYPE_BACKUP_SOURCE and BLOCK_OP_TYPE_BACKUP_TARGET, block-commit involves two asymmetric devices. This change is not user-visible (yet), because commit only works with device names. But once we enable backing reference in blockdev-add, or specifying node-name in bl

[Qemu-devel] [PULL v3 20/38] libqos: Convert malloc-pc allocator to a generic allocator

2015-01-13 Thread Stefan Hajnoczi
From: Marc Marí The allocator in malloc-pc has been extracted, so it can be used in every arch. This operation showed that both the alloc and free functions can be also generic. Because of this, the QGuestAllocator has been removed from is function to wrap the alloc and free function, and now jus

[Qemu-devel] [PULL v3 31/38] coroutine: try harder not to delete coroutines

2015-01-13 Thread Stefan Hajnoczi
From: Peter Lieven Placing coroutines on the global pool should be preferrable, because it can help all threads. But if the global pool is full, we can still try to save some allocations by stashing completed coroutines on the local pool. This is quite cheap too, because it does not require ato

[Qemu-devel] [PULL v3 37/38] MAINTAINERS: Add migration/block* to block subsystem

2015-01-13 Thread Stefan Hajnoczi
From: Fam Zheng We are moving block-migration.c to the separated migration directory, keep this file watched by block maintainers is a good idea. Signed-off-by: Fam Zheng Signed-off-by: Stefan Hajnoczi --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINE

[Qemu-devel] [PULL v3 38/38] NVMe: Set correct VS Value for 1.1 Compliant Controllers

2015-01-13 Thread Stefan Hajnoczi
From: Anubhav Rakshit According to NVMe specifications Bits 15:08 represent Minor Version number. Signed-off-by: Anubhav Rakshit Signed-off-by: Stefan Hajnoczi --- hw/block/nvme.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/block/nvme.c b/hw/block/nvme.c index 4f70f

[Qemu-devel] [PULL v3 26/38] qemu-thread: add per-thread atexit functions

2015-01-13 Thread Stefan Hajnoczi
From: Paolo Bonzini Destructors are the main additional feature of pthread TLS compared to __thread. If we were using C++ (hint, hint!) we could have used thread-local objects with a destructor. Since we are not, instead, we add a simple Notifier-based API. Note that the notifier must be per-t

[Qemu-devel] [PATCH] sheepdog: selectable object size support

2015-01-13 Thread Teruaki Ishizaki
Previously, qemu block driver of sheepdog used hard-coded VDI object size. This patch enables users to handle "block_size_shift" value for calculating VDI object size. When you start qemu, you don't need to specify additional command option. But when you create the VDI which doesn't have default

[Qemu-devel] [PULL v3 34/38] ide: Implement VPD response for ATAPI

2015-01-13 Thread Stefan Hajnoczi
From: John Snow SCSI devices have multiple kinds of queries they need to respond to, as defined in the "cmd inquiry" section in MMC-6 and SPC-3. Relevent sections: MMC-6 revision 2g: Non-VPD response data and pointer to SPC-3; Section 6.8 "Inquiry Command" SPC-3 revision 23: In

[Qemu-devel] vm console often stuck for one or two seconds when the sys time is high

2015-01-13 Thread yuchangw
Hi all.    Our vm created by qemu is often stuck for one or two seconds.The following is our configuration.    Qemu:        QEMU emulator version 2.0.0 (Debian 2.0.0+dfsg-2ubuntu1.1), Copyright (c) 2003-2008 Fabrice Bellar   Hypervisor System: Ubuntu-14.04-server    VM System: Centos6.5-x86_64

[Qemu-devel] [PULL v3 35/38] nvme: Fix get/set number of queues feature

2015-01-13 Thread Stefan Hajnoczi
From: Alex Friedman According to the specification, the low 16 bits should contain the number of I/O submission queues, and the high 16 bits should contain the number of I/O completion queues. Signed-off-by: Alex Friedman Acked-by: Keith Busch Signed-off-by: Stefan Hajnoczi --- hw/block/nvme

Re: [Qemu-devel] [PATCH v5] block: add event when disk usage exceeds threshold

2015-01-13 Thread Stefan Hajnoczi
On Mon, Jan 12, 2015 at 02:11:13PM +0100, Francesco Romani wrote: > Managing applications, like oVirt (http://www.ovirt.org), make extensive > use of thin-provisioned disk images. > To let the guest run smoothly and be not unnecessarily paused, oVirt sets > a disk usage threshold (so called 'high w

Re: [Qemu-devel] [PATCH v3 0/5] libqos: Virtio MMIO driver

2015-01-13 Thread Stefan Hajnoczi
On Wed, Dec 3, 2014 at 9:31 AM, Marc Marí wrote: > Add virtio-mmio support to libqos and test case for virtio-blk. > > This series depends on patch "libqos: Convert malloc-pc allocator to a generic > allocator" > > Changes from version 2: > - Fix leaks and minor bugs > - Extract basic test case

Re: [Qemu-devel] [PATCH 14/19] block/parallels: create catalog_offset helper

2015-01-13 Thread Roman Kagan
On Tue, Dec 30, 2014 at 01:07:07PM +0300, Denis V. Lunev wrote: > to calculate entry offset inside catalog bitmap in parallels image. > This is a matter of convinience. > > Signed-off-by: Denis V. Lunev > CC: Kevin Wolf > CC: Stefan Hajnoczi > --- > block/parallels.c | 12 > 1 fil

Re: [Qemu-devel] [PATCH v4] block/raw-posix.c: Fixes raw_getlength() on Mac OS X so that it reports the correct length of a real CD

2015-01-13 Thread Stefan Hajnoczi
On Tue, Jan 6, 2015 at 3:04 PM, Programmingkid wrote: > > On Jan 6, 2015, at 9:02 AM, Stefan Hajnoczi wrote: > >> On Fri, Jan 02, 2015 at 04:44:38PM -0500, Programmingkid wrote: >>> Removes redundant ret variable and renames sectorSize variable to meet QEMU >>> coding standards. >> >> This is a c

Re: [Qemu-devel] [PATCH 15/19] block/parallels: rename catalog_ names to bat_

2015-01-13 Thread Roman Kagan
On Tue, Dec 30, 2014 at 01:07:08PM +0300, Denis V. Lunev wrote: > BAT means 'block allocation table'. Thus this name is clean and shorter > on writing. > > Signed-off-by: Denis V. Lunev > CC: Kevin Wolf > CC: Stefan Hajnoczi > --- > block/parallels.c | 48 --

Re: [Qemu-devel] [PATCH 13/19] block/parallels: store ParallelsHeader to the BDRVParallelsState

2015-01-13 Thread Roman Kagan
On Tue, Dec 30, 2014 at 01:07:06PM +0300, Denis V. Lunev wrote: > This would be useful for the future for speed optimizations of new block > creation in the image. At the moment each write to the catalog bitmap > results in read-modify-write transaction. It would be beneficial to > write by pages o

[Qemu-devel] [Bug 1338957] Re: RFE: add an event to report block devices watermark

2015-01-13 Thread Francesco Romani
patch posted on qemu-devel, reviewd, acked and merged into maintainer's branch: https://github.com/stefanha/qemu/commit/f050ea639522e9dd7e501ef285a2a12709b8726a -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.ne

Re: [Qemu-devel] [RFC PATCH v7 15/21] replay: checkpoints

2015-01-13 Thread Pavel Dovgaluk
> From: Paolo Bonzini [mailto:pbonz...@redhat.com] > On 13/01/2015 10:15, Pavel Dovgaluk wrote: > > The numbers have no meaning. They just have to be distinct in different > > places. > > This is easier to achieve if you give a name to each place. > > > Sorry, missed one thing. > > run_all is us

Re: [Qemu-devel] [PULL v3 00/38] Block patches

2015-01-13 Thread Peter Maydell
On 13 January 2015 at 13:47, Stefan Hajnoczi wrote: > The following changes since commit 7d5ad15d17f26dd4f9ff5f3491828bc34e74f28c: > > Merge remote-tracking branch 'remotes/stefanha/tags/net-pull-request' into > staging (2015-01-12 11:13:24 +) > > are available in the git repository at: > >

Re: [Qemu-devel] nested VMX with IA32_FEATURE_CONTROL MSR(addr: 0x3a) value of ZERO

2015-01-13 Thread Jan Kiszka
On 2015-01-13 14:43, Paolo Bonzini wrote: > > > On 13/01/2015 14:19, Huaicheng Li wrote: >> Hi, all >> >> I have a Linux 3.8 kernel (host) and run QEMU 1.5.3 on it. I want to >> test another hypervisor software in qemu so I enabled KVM's nested VMX >> function(by passing "nested=1" parameter to t

Re: [Qemu-devel] [PATCH 16/19] block/parallels: no need to flush on each block allocation table update

2015-01-13 Thread Roman Kagan
On Tue, Dec 30, 2014 at 01:07:09PM +0300, Denis V. Lunev wrote: > From the point of guest each write to real disk prior to disk barrier > operation could be lost. Therefore there is no problem that "not synced" > new block is lost due to not updated allocation table if QEMU is crashed. > > This pa

Re: [Qemu-devel] [RFC PATCH v7 15/21] replay: checkpoints

2015-01-13 Thread Paolo Bonzini
On 13/01/2015 15:26, Pavel Dovgaluk wrote: >> > Should you instead distinguish which TimerListGroup is being run? Then >> > main loop would checkpoint once for every TimerListGroup (which means >> > twice). > Then I'll have to introduce some kind of deterministic ID for them > and new asynchrono

Re: [Qemu-devel] [RFC PATCH v7 15/21] replay: checkpoints

2015-01-13 Thread Paolo Bonzini
On 13/01/2015 15:26, Pavel Dovgaluk wrote: >> > Should you instead distinguish which TimerListGroup is being run? Then >> > main loop would checkpoint once for every TimerListGroup (which means >> > twice). > Then I'll have to introduce some kind of deterministic ID for them > and new asynchrono

Re: [Qemu-devel] [PATCH 16/19] block/parallels: no need to flush on each block allocation table update

2015-01-13 Thread Denis V. Lunev
On 13/01/15 17:50, Roman Kagan wrote: On Tue, Dec 30, 2014 at 01:07:09PM +0300, Denis V. Lunev wrote: From the point of guest each write to real disk prior to disk barrier operation could be lost. Therefore there is no problem that "not synced" new block is lost due to not updated allocation ta

Re: [Qemu-devel] [PATCH v5 2/5] raw-posix: Refactor logical block size detection.

2015-01-13 Thread Stefan Hajnoczi
On Tue, Jan 13, 2015 at 01:03:03PM +0300, Ekaterina Tumanova wrote: > On 01/02/2015 02:52 PM, Stefan Hajnoczi wrote: > >On Thu, Dec 18, 2014 at 12:18:01PM +0100, Ekaterina Tumanova wrote: > >>+#if defined(BLKSSZGET) > >>+# define SECTOR_SIZE BLKSSZGET > >>+#elif defined(DKIOCGETBLOCKSIZE) > >>+#

Re: [Qemu-devel] [PATCH 0/1] pci: allow 0 address for PCI IO/MEM regions

2015-01-13 Thread Michael Roth
Quoting Michael S. Tsirkin (2015-01-13 04:12:19) > On Mon, Jan 12, 2015 at 07:24:06AM -0600, Michael Roth wrote: > > Quoting Michael Roth (2014-12-23 13:33:35) > > > This patch enables the programming of address 0 for IO/MMIO BARs for > > > PCI devices. > > > > > > It was originally included as pa

Re: [Qemu-devel] qemu is freezing in rebooting after CPU hot-unplug.

2015-01-13 Thread Paulo Vital
Hello. Any advice for this issue? --- Paulo Vital On Fri, Jan 9, 2015 at 3:14 PM, Paulo Vital wrote: > Hi > > I'm doing some tests on CPU hot-unplug using as base the mentioned patch > set in [1] and I'm facing some problems while executing a reboot (via > 'shutdown -r now' command in guest's

  1   2   3   >