[Qemu-devel] [PULL 0/2] Net patches

2018-03-26 Thread Jason Wang
The following changes since commit 7b1db0908d88f0c9cfac24e214ff72a860692e23: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20180323' into staging (2018-03-25 13:51:33 +0100) are available in the git repository at: https://github.com/jasowang/qemu.git tags/net-pull-requ

[Qemu-devel] [PULL 1/2] virtio_net: flush uncompleted TX on reset

2018-03-26 Thread Jason Wang
From: Greg Kurz If the backend could not transmit a packet right away for some reason, the packet is queued for asynchronous sending. The corresponding vq element is tracked in the async_tx.elem field of the VirtIONetQueue, for later freeing when the transmission is complete. If a reset happens

[Qemu-devel] [PULL 2/2] net/vde: print error on vde_open() failure

2018-03-26 Thread Jason Wang
From: Julia Suvorova via Qemu-devel Despite the fact that now when the initialization of vde fails, qemu does not end silently, no informative error is printed. The patch generates an error and pushes it through the calling function. Related bug: https://bugs.launchpad.net/qemu/+bug/676029 Sign

Re: [Qemu-devel] [PATCH] scsi-disk: Don't enlarge min_io_size to max_io_size

2018-03-26 Thread Fam Zheng
On Thu, 03/22 09:19, Daniel Henrique Barboza wrote: > Hi, > > On 03/22/2018 04:38 AM, Fam Zheng wrote: > > Some backends report big max_io_sectors. Making min_io_size the same > > value in this case will make it impossible for guest to align memory, > > therefore the disk may not be usable at all.

Re: [Qemu-devel] [PATCH for-2.12 0/4] Fix crashes with CAN bus and ISA DMA devices

2018-03-26 Thread Paolo Bonzini
On 23/03/2018 19:20, John Snow wrote: > > > On 03/16/2018 06:15 AM, Paolo Bonzini wrote: >> On 16/03/2018 10:51, Thomas Huth wrote: >>> The new CAN bus devices and some older ISA devices that use DMA can be >>> used to crash QEMU. These patches introduce some proper checks so that >>> the users g

Re: [Qemu-devel] [PATCH v8 14/23] monitor: separate QMP parser and dispatcher

2018-03-26 Thread Peter Xu
On Fri, Mar 23, 2018 at 05:18:53PM +0100, Marc-André Lureau wrote: [...] > > +/* > > + * Dispatch one single QMP request. The function will free the req_obj > > + * and objects inside it before return. > > + */ > > +static void monitor_qmp_dispatch_one(QMPRequest *req_obj) > > { > > -QObject

Re: [Qemu-devel] [PATCH v3 6/7] s390x/kvm: handle AP instruction interception

2018-03-26 Thread David Hildenbrand
On 16.03.2018 00:24, Tony Krowiak wrote: > If the CPU model indicates that AP facility is installed on > the guest (i.e., -cpu ,ap=on), then the expectation is that > the AP bus running in the guest will initialize; however, if the > AP instructions are not being interpreted by the firmware, th

Re: [Qemu-devel] [PATCH v8 14/23] monitor: separate QMP parser and dispatcher

2018-03-26 Thread Marc-André Lureau
Hi On Mon, Mar 26, 2018 at 10:07 AM, Peter Xu wrote: > On Fri, Mar 23, 2018 at 05:18:53PM +0100, Marc-André Lureau wrote: > > [...] > >> > +/* >> > + * Dispatch one single QMP request. The function will free the req_obj >> > + * and objects inside it before return. >> > + */ >> > +static void mon

[Qemu-devel] Patchew failure ? (was: Re: [PATCH 00/14] Generalize Dallas/Maxim I2C RTC devices v2)

2018-03-26 Thread Thomas Huth
On 24.03.2018 23:08, no-re...@patchew.org wrote: > Hi, > > This series failed docker-build@min-glib build test. Please find the testing > commands and > their output below. If you have Docker installed, you can probably reproduce > it > locally. > > Type: series > Message-id: 20180324192455.122

Re: [Qemu-devel] [PATCH v3 4/7] s390x/kvm: interface to interpret AP instructions

2018-03-26 Thread David Hildenbrand
On 16.03.2018 00:24, Tony Krowiak wrote: > The VFIO AP device exploits interpretive execution of AP > instructions (APIE). APIE is enabled by setting a device attribute > via the KVM_SET_DEVICE_ATTR ioctl. > > Signed-off-by: Tony Krowiak > --- > target/s390x/kvm.c | 16 >

Re: [Qemu-devel] [PATCH v4 2/9] numa: split out NumaOptions parsing into parse_NumaOptions()

2018-03-26 Thread Laurent Vivier
On 23/03/2018 21:49, Eric Blake wrote: > On 03/23/2018 03:42 PM, Eduardo Habkost wrote: >> On Mon, Mar 12, 2018 at 02:11:08PM +0100, Igor Mammedov wrote: >>> it will allow to reuse parse_NumaOptions() for parsing >>> configuration commands received via QMP interface >>> >>> Signed-off-by: Igor Mamm

Re: [Qemu-devel] [PATCH for-2.12 1/8] qmp: fix qmp_capabilities error regression

2018-03-26 Thread Marc-André Lureau
On Mon, Mar 26, 2018 at 8:38 AM, Peter Xu wrote: > When someone sents a command before QMP handshake, error was like this: > > {"execute": "query-cpus"} > {"error": {"class": "CommandNotFound", "desc": > "Expecting capabilities negotiation with 'qmp_capabilities'"}} > > While after c

Re: [Qemu-devel] [PATCH 2/4] error: Remove NULL checks on error_propagate() calls

2018-03-26 Thread Laurent Vivier
On 23/03/2018 21:50, Eric Blake wrote: > On 03/22/2018 11:12 AM, Laurent Vivier wrote: >> Re-run Coccinelle patch >> scripts/coccinelle/error_propagate_null.cocci >> >> Signed-off-by: Laurent Vivier >> --- >>   io/channel-websock.c | 4 +--- >>   1 file changed, 1 insertion(+), 3 deletions(-) >> >

Re: [Qemu-devel] [qemu-s390x] [PATCH v3 6/7] s390x/kvm: handle AP instruction interception

2018-03-26 Thread David Hildenbrand
On 26.03.2018 10:32, David Hildenbrand wrote: > On 16.03.2018 00:24, Tony Krowiak wrote: >> If the CPU model indicates that AP facility is installed on >> the guest (i.e., -cpu ,ap=on), then the expectation is that >> the AP bus running in the guest will initialize; however, if the >> AP instru

Re: [Qemu-devel] [PATCH for-2.12 2/8] qmp: cleanup qmp queues properly

2018-03-26 Thread Marc-André Lureau
On Mon, Mar 26, 2018 at 8:38 AM, Peter Xu wrote: > Marc-André Lureau reported that we can have this happen: > > 1. client1 connects, send command C1 > 2. client1 disconnects before getting response for C1 > 3. client2 connects, who might receive response of C1 > > However client2 should not receiv

Re: [Qemu-devel] Patchew failure ? (was: Re: [PATCH 00/14] Generalize Dallas/Maxim I2C RTC devices v2)

2018-03-26 Thread Fam Zheng
On Mon, 03/26 10:34, Thomas Huth wrote: > On 24.03.2018 23:08, no-re...@patchew.org wrote: > > Hi, > > > > This series failed docker-build@min-glib build test. Please find the > > testing commands and > > their output below. If you have Docker installed, you can probably > > reproduce it > > loc

Re: [Qemu-devel] [PATCH 1/8] migration: stop compressing page in migration thread

2018-03-26 Thread Peter Xu
On Thu, Mar 22, 2018 at 07:38:07PM +0800, Xiao Guangrong wrote: > > > On 03/21/2018 04:19 PM, Peter Xu wrote: > > On Fri, Mar 16, 2018 at 04:05:14PM +0800, Xiao Guangrong wrote: > > > > > > Hi David, > > > > > > Thanks for your review. > > > > > > On 03/15/2018 06:25 PM, Dr. David Alan Gilbert

Re: [Qemu-devel] [PATCH v3 6/7] s390x/kvm: handle AP instruction interception

2018-03-26 Thread Pierre Morel
On 26/03/2018 10:32, David Hildenbrand wrote: On 16.03.2018 00:24, Tony Krowiak wrote: If the CPU model indicates that AP facility is installed on the guest (i.e., -cpu ,ap=on), then the expectation is that the AP bus running in the guest will initialize; however, if the AP instructions are

[Qemu-devel] [PATCH] docker: Inline "prep_fail" in run script

2018-03-26 Thread Fam Zheng
We don't source common.rc where prep_fail is defined, so spell out the commands and do what was intended. Signed-off-by: Fam Zheng --- tests/docker/run | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/docker/run b/tests/docker/run index 9dd362bb98..7aebf4b569 100755 ---

Re: [Qemu-devel] [PATCH v8 14/23] monitor: separate QMP parser and dispatcher

2018-03-26 Thread Peter Xu
On Mon, Mar 26, 2018 at 10:33:27AM +0200, Marc-André Lureau wrote: > Hi > > On Mon, Mar 26, 2018 at 10:07 AM, Peter Xu wrote: > > On Fri, Mar 23, 2018 at 05:18:53PM +0100, Marc-André Lureau wrote: > > > > [...] > > > >> > +/* > >> > + * Dispatch one single QMP request. The function will free the

Re: [Qemu-devel] [PATCH for-2.12 3/8] monitor: new parameter "x-oob"

2018-03-26 Thread Marc-André Lureau
Hi On Mon, Mar 26, 2018 at 8:38 AM, Peter Xu wrote: > Add new parameter to optionally enable Out-Of-Band for a QMP server. > > An example command line: > > ./qemu-system-x86_64 -chardev stdio,id=char0 \ >-mon chardev=char0,mode=control,x-oob=on > > By default, Out-Of-Ban

Re: [Qemu-devel] [PATCH for-2.12 4/8] qapi: restrict allow-oob value to be "true"

2018-03-26 Thread Marc-André Lureau
On Mon, Mar 26, 2018 at 8:38 AM, Peter Xu wrote: > It was missed in the first version of OOB series. We should check this > to make sure we throw the right error when fault value is passed in. > > Signed-off-by: Peter Xu Not exactly required imho, but why not: Reviewed-by: Marc-André Lureau

Re: [Qemu-devel] [PATCH for-2.12 5/8] tests: let qapi-schema tests detect oob

2018-03-26 Thread Marc-André Lureau
On Mon, Mar 26, 2018 at 8:38 AM, Peter Xu wrote: > The allow_oob parameter was passed in but not used in tests. Now > reflect that in the tests, so we need to touch up other command testers > with that new change. > > Reviewed-by: Eric Blake > Signed-off-by: Peter Xu Reviewed-by: Marc-André Lu

Re: [Qemu-devel] [PATCH for-2.12 3/8] monitor: new parameter "x-oob"

2018-03-26 Thread Peter Xu
On Mon, Mar 26, 2018 at 11:10:30AM +0200, Marc-André Lureau wrote: [...] > > @@ -4568,12 +4569,26 @@ static void monitor_qmp_setup_handlers_bh(void > > *opaque) > > void monitor_init(Chardev *chr, int flags) > > { > > Monitor *mon = g_malloc(sizeof(*mon)); > > +bool use_readline = fla

Re: [Qemu-devel] [PATCH for-2.12 7/8] tests: introduce qtest_init_with_qmp_format()

2018-03-26 Thread Marc-André Lureau
On Mon, Mar 26, 2018 at 8:39 AM, Peter Xu wrote: > It is abstracted from qtest_init_without_qmp_handshake(). It works just > like qtest_init_without_qmp_handshake() but further it would allow the > caller to specify the QMP parameter. > > Signed-off-by: Peter Xu Reviewed-by: Marc-André Lureau

Re: [Qemu-devel] [PATCH for-2.12 6/8] tests: add oob-test for qapi-schema

2018-03-26 Thread Marc-André Lureau
On Mon, Mar 26, 2018 at 8:38 AM, Peter Xu wrote: > It simply tests the new OOB capability, and make sure the QAPISchema can > parse it correctly. > > Signed-off-by: Peter Xu Reviewed-by: Marc-André Lureau > --- > tests/Makefile.include | 1 + > tests/qapi-schema/oob-test.err

Re: [Qemu-devel] [PATCH] docker: Inline "prep_fail" in run script

2018-03-26 Thread Thomas Huth
On 26.03.2018 11:03, Fam Zheng wrote: > We don't source common.rc where prep_fail is defined, so spell out the > commands and do what was intended. > > Signed-off-by: Fam Zheng > --- > tests/docker/run | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/tests/docker/run b/t

Re: [Qemu-devel] [PATCH 01/14] tests: more thorough tests of ds1338

2018-03-26 Thread Paolo Bonzini
On 24/03/2018 20:24, Michael Davidsaver wrote: > Test current time and set+get round trip. > Separate current time test from set/get > tests to avoid test order issues. What are these issues? You can start a different QEMU for each test. Paolo > Signed-off-by: Michael Davidsaver

[Qemu-devel] [PATCH RFC] s390x/kvm: call cpu_synchronize_state() on every kvm_arch_handle_exit()

2018-03-26 Thread David Hildenbrand
Manually having to use cpu_synchronize_state() is error prone. I don't think that the performance impact is that huge if we simply synchronize the state on every kvm_arch_handle_exit() call. This makes the code easier to maintain. We now also call it (although not neded) for - KVM_EXIT_S390_RESET

Re: [Qemu-devel] [PATCH RFC] s390x/kvm: call cpu_synchronize_state() on every kvm_arch_handle_exit()

2018-03-26 Thread David Hildenbrand
On 26.03.2018 11:20, David Hildenbrand wrote: > Manually having to use cpu_synchronize_state() is error prone. I don't > think that the performance impact is that huge if we simply synchronize > the state on every kvm_arch_handle_exit() call. This makes the code > easier to maintain. > > We now al

Re: [Qemu-devel] [PATCH v8 14/23] monitor: separate QMP parser and dispatcher

2018-03-26 Thread Marc-André Lureau
Hi On Mon, Mar 26, 2018 at 11:08 AM, Peter Xu wrote: > On Mon, Mar 26, 2018 at 10:33:27AM +0200, Marc-André Lureau wrote: >> Hi >> >> On Mon, Mar 26, 2018 at 10:07 AM, Peter Xu wrote: >> > On Fri, Mar 23, 2018 at 05:18:53PM +0100, Marc-André Lureau wrote: >> > >> > [...] >> > >> >> > +/* >> >> >

Re: [Qemu-devel] [Consult] nfs-vsocks support

2018-03-26 Thread Liu, Jing2
Hi Stefan, Thank you very much for the response! It truly gave me much help. On 3/24/2018 12:02 AM, Stefan Hajnoczi wrote: On Fri, Mar 23, 2018 at 05:54:53PM +0800, Liu, Jing2 wrote: I am currently trying to use nfs-vsocks on x86 for vitural machine filesystem by some manuals on https://www.sp

Re: [Qemu-devel] [PATCH] block: remove bdrv_dirty_bitmap_make_anon

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
23.03.2018 19:42, Paolo Bonzini wrote: All this function is doing will be repeated by bdrv_do_release_matching_dirty_bitmap_locked, except resetting bm->persistent. But even that does not matter because the bitmap will be freed. Signed-off-by: Paolo Bonzini Reviewed-by: Vladimir Sementsov-Og

Re: [Qemu-devel] [PATCH for-2.12 0/8] Monitor: some oob related patches (fixes, new param, tests)

2018-03-26 Thread Christian Borntraeger
Thanks for the quick fixing. This series on top of master works fine on s390. (make check and iotests) Christian On 03/26/2018 08:38 AM, Peter Xu wrote: > I suppose these are all good even for 2.12, so marked in subject. > Tested with "make check" for all targets on x86_64, and iotest -raw. >

Re: [Qemu-devel] [PATCH for-2.12 v2 00/12] block: Follow-up for .bdrv_co_create (part 1)

2018-03-26 Thread Kevin Wolf
Am 21.03.2018 um 18:37 hat Kevin Wolf geschrieben: > This series adds qemu-iotests for a few more block drivers (yet more to > come in another series) and fixes a few things that previous review and > these tests brought up. > > The only major design change is that I converted the vdi block driver

Re: [Qemu-devel] [PATCH] block: simplify code around releasing bitmaps

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
23.03.2018 19:42, Paolo Bonzini wrote: QLIST_REMOVE does not require walking the list, and once the "bitmap" argument is removed from bdrv_do_release_matching_dirty_bitmap_locked the code simplifies a lot and it is worth inlining everything in the callers of bdrv_do_release_matching_dirty_bitmap.

Re: [Qemu-devel] [PATCH v2 1/1] iotests: fix test case 185

2018-03-26 Thread Kevin Wolf
Am 23.03.2018 um 04:43 hat QingFeng Hao geschrieben: > Test case 185 failed since commit 4486e89c219 --- "vl: introduce > vm_shutdown()". > It's because of the newly introduced function vm_shutdown calls > bdrv_drain_all, > which is called later by bdrv_close_all. bdrv_drain_all resumes the jobs

Re: [Qemu-devel] [PATCH] block: simplify code around releasing bitmaps

2018-03-26 Thread Paolo Bonzini
On 26/03/2018 12:24, Vladimir Sementsov-Ogievskiy wrote: > 23.03.2018 19:42, Paolo Bonzini wrote: >> QLIST_REMOVE does not require walking the list, and once the "bitmap" >> argument is removed from bdrv_do_release_matching_dirty_bitmap_locked >> the code simplifies a lot and it is worth inlining e

[Qemu-devel] [PATCH v2] block: simplify code around releasing bitmaps

2018-03-26 Thread Paolo Bonzini
QLIST_REMOVE does not require walking the list, and once the "bitmap" argument is removed from bdrv_do_release_matching_dirty_bitmap_locked the code simplifies a lot and it is worth inlining everything in the callers of bdrv_do_release_matching_dirty_bitmap. Reviewed-by: Vladimir Sementsov-Ogievsk

Re: [Qemu-devel] [PATCH] iotests: fix wait_until_completed()

2018-03-26 Thread Kevin Wolf
Am 26.03.2018 um 08:11 hat Peter Xu geschrieben: > If there are more than one events, wait_until_completed() might return > the 2nd event even if the 1st event is JOB_COMPLETED, since the for loop > will continue to run even if completed is set to True. > > It never happened before, but it can be

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v5 4/5] virtio-balloon: VIRTIO_BALLOON_F_FREE_PAGE_HINT

2018-03-26 Thread Wei Wang
On 03/22/2018 11:13 AM, Wei Wang wrote: OK. I've tried to implement it this way: create an iothread via the qemu cmdline option: --device virtio-balloon,free-page-hint=true,iothread=iothread10, and schedule a BH to run in the iothread context when free_page_start() is called. I think the dr

Re: [Qemu-devel] [virtio-dev] Re: [PATCH v5 4/5] virtio-balloon: VIRTIO_BALLOON_F_FREE_PAGE_HINT

2018-03-26 Thread Daniel P . Berrangé
On Tue, Mar 20, 2018 at 05:24:39AM +0200, Michael S. Tsirkin wrote: > On Tue, Mar 20, 2018 at 11:18:23AM +0800, Wei Wang wrote: > > On 03/20/2018 10:59 AM, Michael S. Tsirkin wrote: > > > On Tue, Mar 20, 2018 at 10:16:09AM +0800, Wei Wang wrote: > > > > On 03/20/2018 06:55 AM, Michael S. Tsirkin wr

Re: [Qemu-devel] [PATCH for-2.12] qemu-pr-helper: Actually allow users to specify pidfile

2018-03-26 Thread Paolo Bonzini
On 24/03/2018 12:46, Eric Blake wrote: > On 03/24/2018 12:14 AM, Michal Privoznik wrote: >> Due to wrong specification of arguments to getopt_long() any >> attempt to set pidfile resulted in: >> >> 1) the default to be leaked >> 2) the @pidfile variable to be set to NULL (because optarg is >> NULL

[Qemu-devel] [PATCH] dma/i82374: avoid double creation of i82374 device

2018-03-26 Thread Eduardo Otubo
QEMU fails when used with the following command line: ./ppc64-softmmu/qemu-system-ppc64 -S -machine 40p,accel=tcg -device i82374 qemu-system-ppc64: hw/isa/isa-bus.c:110: isa_bus_dma: Assertion `!bus->dma[0] && !bus->dma[1]' failed. Aborted (core dumped) The 40p machine type already c

[Qemu-devel] [PATCH 0/7] Dirty bitmaps fixing and refactoring

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
Nothing critical here. 01 - these functions are unused for now, but the will be used in the qmp bitmaps api. Vladimir Sementsov-Ogievskiy (7): block/dirty-bitmap: add lock to bdrv_enable/disable_dirty_bitmap dirty-bitmaps: fix comment about dirty_bitmap_mutex dirty-bitmap: remove misse

[Qemu-devel] [PATCH 3/7] dirty-bitmap: remove missed bdrv_dirty_bitmap_get_autoload header

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
Signed-off-by: Vladimir Sementsov-Ogievskiy --- include/block/dirty-bitmap.h | 1 - 1 file changed, 1 deletion(-) diff --git a/include/block/dirty-bitmap.h b/include/block/dirty-bitmap.h index 1ff8949b1b..c7e910016d 100644 --- a/include/block/dirty-bitmap.h +++ b/include/block/dirty-bitmap.h @@

[Qemu-devel] [PATCH 5/7] blockdev: refactor block-dirty-bitmap-clear transaction

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
bdrv_clear_dirty_bitmap do not fail, so we can call it in transaction commit, avoiding any rollback. Signed-off-by: Vladimir Sementsov-Ogievskiy --- blockdev.c | 16 +--- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/blockdev.c b/blockdev.c index c31bf3d98d..88eae60c1

[Qemu-devel] [PATCH 7/7] blockdev: unify block-dirty-bitmap-clear command and transaction action

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
- use error messages from qmp command, as they are more descriptive - we need not check bs, as block_dirty_bitmap_lookup never returns bs = NULL on success (and if user set bs to be not NULL pointer), so, let's just assert it. Signed-off-by: Vladimir Sementsov-Ogievskiy --- blockdev.c |

[Qemu-devel] [PATCH 6/7] block/dirty-bitmap: bdrv_clear_dirty_bitmap: drop unused parameter

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
Drop parameter "HBitmap **out" which is unused now, all callers set it to NULL. Signed-off-by: Vladimir Sementsov-Ogievskiy --- include/block/block_int.h | 2 +- block/dirty-bitmap.c | 14 +- blockdev.c| 4 ++-- 3 files changed, 8 insertions(+), 12 deletions(-)

[Qemu-devel] [PATCH 4/7] dirty-bitmap: separate unused meta-bitmap related functions

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
Separate them in the header and clarify needed locking in comments. Signed-off-by: Vladimir Sementsov-Ogievskiy --- include/block/dirty-bitmap.h | 14 +- block/dirty-bitmap.c | 5 + 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/include/block/dirty-bitma

[Qemu-devel] [PATCH 1/7] block/dirty-bitmap: add lock to bdrv_enable/disable_dirty_bitmap

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
Functions write to BdrvDirtyBitmap field, so the should take the lock. Signed-off-by: Vladimir Sementsov-Ogievskiy --- block/dirty-bitmap.c | 4 1 file changed, 4 insertions(+) diff --git a/block/dirty-bitmap.c b/block/dirty-bitmap.c index 967159479d..6c00288fd7 100644 --- a/block/dirty-bi

[Qemu-devel] [PATCH 2/7] dirty-bitmaps: fix comment about dirty_bitmap_mutex

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
Clarify first two cases and fix Modify -> Any access in third case. Also, drop 'only' from third case, as it a bit confuses, when thinking about case where we modify BdrvDirtyBitmap and access HBitmap. Signed-off-by: Vladimir Sementsov-Ogievskiy --- include/block/block_int.h | 12 1

[Qemu-devel] [Bug 1721224] Re: qemu crashes with Assertion `!bus->dma[0] && !bus->dma[1]' failed

2018-03-26 Thread Eduardo Otubo
v4 patch posted: http://lists.nongnu.org/archive/html/qemu-devel/2018-03/msg06565.html -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1721224 Title: qemu crashes with Assertion `!bus->dma[0] && !bus

Re: [Qemu-devel] [PATCH 5/7] blockdev: refactor block-dirty-bitmap-clear transaction

2018-03-26 Thread Paolo Bonzini
On 26/03/2018 13:20, Vladimir Sementsov-Ogievskiy wrote: > bdrv_clear_dirty_bitmap do not fail, so we can call it in transaction > commit, avoiding any rollback. > > Signed-off-by: Vladimir Sementsov-Ogievskiy > --- > blockdev.c | 16 +--- > 1 file changed, 1 insertion(+), 15 deletio

Re: [Qemu-devel] [PATCH 0/7] Dirty bitmaps fixing and refactoring

2018-03-26 Thread Paolo Bonzini
On 26/03/2018 13:20, Vladimir Sementsov-Ogievskiy wrote: > Nothing critical here. > > 01 - these functions are unused for now, but the will be used in > the qmp bitmaps api. > > Vladimir Sementsov-Ogievskiy (7): > block/dirty-bitmap: add lock to bdrv_enable/disable_dirty_bitmap > dirty-b

Re: [Qemu-devel] [PATCH 5/7] blockdev: refactor block-dirty-bitmap-clear transaction

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
26.03.2018 14:44, Paolo Bonzini wrote: On 26/03/2018 13:20, Vladimir Sementsov-Ogievskiy wrote: bdrv_clear_dirty_bitmap do not fail, so we can call it in transaction commit, avoiding any rollback. Signed-off-by: Vladimir Sementsov-Ogievskiy --- blockdev.c | 16 +--- 1 file chang

Re: [Qemu-devel] [PATCH 5/7] blockdev: refactor block-dirty-bitmap-clear transaction

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
26.03.2018 14:48, Vladimir Sementsov-Ogievskiy wrote: 26.03.2018 14:44, Paolo Bonzini wrote: On 26/03/2018 13:20, Vladimir Sementsov-Ogievskiy wrote: bdrv_clear_dirty_bitmap do not fail, so we can call it in transaction commit, avoiding any rollback. Signed-off-by: Vladimir Sementsov-Ogievskiy

[Qemu-devel] [PATCH 5.5/7] dirty-bitmap: drop unused bdrv_undo_clear_dirty_bitmap

2018-03-26 Thread Vladimir Sementsov-Ogievskiy
Signed-off-by: Vladimir Sementsov-Ogievskiy --- include/block/block_int.h | 1 - block/dirty-bitmap.c | 9 - 2 files changed, 10 deletions(-) diff --git a/include/block/block_int.h b/include/block/block_int.h index e5af7820ff..bd857d5099 100644 --- a/include/block/block_int.h +++ b/

Re: [Qemu-devel] [PATCH v3 6/7] s390x/kvm: handle AP instruction interception

2018-03-26 Thread Halil Pasic
On 03/26/2018 11:03 AM, Pierre Morel wrote: >>> +int ap_device_handle_pqap(S390CPU *cpu) >>> +{ >>> +CPUS390XState *env = &cpu->env; >>> +int fc = 4 & (env->regs[0] >> 24); >>> + >>> +/* >>> + * The Query Configuration Information (QCI) function (fc == 4) does  >>> not >>> + *

Re: [Qemu-devel] [PULL 2/2] net/vde: print error on vde_open() failure

2018-03-26 Thread Philippe Mathieu-Daudé
Hi Jason, On 03/26/2018 04:00 AM, Jason Wang wrote: > From: Julia Suvorova via Qemu-devel This doesn't look right, shouldn't it be Julia Suvorova ? > > Despite the fact that now when the initialization of vde fails, qemu > does not end silently, no informative error is printed. The patch > gen

Re: [Qemu-devel] [PATCH] dma/i82374: avoid double creation of i82374 device

2018-03-26 Thread Thomas Huth
On 26.03.2018 13:18, Eduardo Otubo wrote: > QEMU fails when used with the following command line: > > ./ppc64-softmmu/qemu-system-ppc64 -S -machine 40p,accel=tcg -device i82374 > qemu-system-ppc64: hw/isa/isa-bus.c:110: isa_bus_dma: Assertion > `!bus->dma[0] && !bus->dma[1]' failed. >

Re: [Qemu-devel] [PATCH] dma/i82374: avoid double creation of i82374 device

2018-03-26 Thread Paolo Bonzini
On 26/03/2018 14:14, Thomas Huth wrote: >> +object_ref(OBJECT(dev)); >> +object_property_set_bool(OBJECT(dev), false, "realized", &err); >> +if (err) { >> +error_reportf_err(err, "Clean up of device %s failed: ", >> + object_get_typename(OBJECT(dev))); >

Re: [Qemu-devel] [PATCH 1/2] hw/sysbus.h: New sysbus_init_child() helper function

2018-03-26 Thread Igor Mammedov
On Sat, 24 Mar 2018 12:35:22 -0300 Philippe Mathieu-Daudé wrote: > Hi, > > On 02/20/2018 10:23 AM, Igor Mammedov wrote: > > On Tue, 20 Feb 2018 13:13:49 +0100 > > Paolo Bonzini wrote: > > > >> On 16/02/2018 18:40, Philippe Mathieu-Daudé wrote: > >>> we can keep object_initialize() when no

Re: [Qemu-devel] [PULL 0/2] Net patches

2018-03-26 Thread no-reply
Hi, This series failed docker-quick@centos6 build test. Please find the testing commands and their output below. If you have Docker installed, you can probably reproduce it locally. Type: series Message-id: 1522047629-27658-1-git-send-email-jasow...@redhat.com Subject: [Qemu-devel] [PULL 0/2] Ne

Re: [Qemu-devel] [PULL 0/2] Net patches

2018-03-26 Thread Peter Maydell
On 26 March 2018 at 08:00, Jason Wang wrote: > The following changes since commit 7b1db0908d88f0c9cfac24e214ff72a860692e23: > > Merge remote-tracking branch > 'remotes/pmaydell/tags/pull-target-arm-20180323' into staging (2018-03-25 > 13:51:33 +0100) > > are available in the git repository at:

[Qemu-devel] [PULL 02/16] WHPX fix WHvGetCapability out WrittenSizeInBytes

2018-03-26 Thread Paolo Bonzini
From: "Justin Terry (VM)" This fixes a breaking change to WHvGetCapability to include the 'out' WrittenSizeInBytes introduced in Windows Insider SDK 17110. This specifies on return the safe length to read into the WHV_CAPABILITY structure passed to the call. Signed-off-by: Justin Terry (VM) Me

[Qemu-devel] [PULL 00/16] Misc fixes for QEMU 2.12.0-rc1

2018-03-26 Thread Paolo Bonzini
The following changes since commit 7b1db0908d88f0c9cfac24e214ff72a860692e23: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20180323' into staging (2018-03-25 13:51:33 +0100) are available in the git repository at: git://github.com/bonzini/qemu.git tags/for-upstream f

[Qemu-devel] [PULL 03/16] WHPX fix WHvSetPartitionProperty in PropertyCode

2018-03-26 Thread Paolo Bonzini
From: "Justin Terry (VM)" This fixes a breaking change to WHvSetPartitionProperty to pass the 'in' PropertyCode on function invocation introduced in Windows Insider SDK 17110. Usage of this indicates the PropertyCode of the opaque PropertyBuffer passed in on function invocation. Also fixes the r

[Qemu-devel] [PULL 01/16] scripts/get_maintainer.pl: Print proper error message for missing $file

2018-03-26 Thread Paolo Bonzini
From: Ian Jackson If you pass scripts/get_maintainer.pl the name of a FIFO or other exciting object (/dev/stdin, for example), it would falsely print "file not found". Instead: stat the object rather than using -f so that we do not mind if the object is not a file; and print the errno value in t

[Qemu-devel] [PULL 05/16] hw/net/can: Fix segfaults when using the devices without bus

2018-03-26 Thread Paolo Bonzini
From: Thomas Huth The CAN devices can currently be used to crash QEMU, e.g.: $ x86_64-softmmu/qemu-system-x86_64 -device kvaser_pci Segmentation fault (core dumped) So we've got to add a proper check here that the corresponding bus is available. Signed-off-by: Thomas Huth Message-Id: <1521193

[Qemu-devel] [PULL 04/16] WHPX improve vcpu_post_run perf

2018-03-26 Thread Paolo Bonzini
From: "Justin Terry (VM)" This removes the additional call to WHvGetVirtualProcessorRegisters in whpx_vcpu_post_run now that the WHV_VP_EXIT_CONTEXT is returned in all WHV_RUN_VP_EXIT_CONTEXT structures. Signed-off-by: Justin Terry (VM) Message-Id: <1521039163-138-4-git-send-email-jute...@micro

[Qemu-devel] [PULL 07/16] hw/audio: Fix crashes when devices are used on ISA bus without DMA

2018-03-26 Thread Paolo Bonzini
From: Thomas Huth The cs4231a, gus and sb16 sound cards crash QEMU when the user tries to instantiate them on a machine with DMA-less ISA bus (for example with "qemu-system-mips64el -M mips -device sb16"). Add proper checks to the realize functions to avoid the crashes. Signed-off-by: Thomas Hut

[Qemu-devel] [PULL 06/16] fdc: Exit if ISA controller does not support DMA

2018-03-26 Thread Paolo Bonzini
From: Alexey Kardashevskiy A "powernv" machine type defines an ISA bus but it does not add any DMA controller to it so it is possible to hit assert(fdctrl->dma) by adding "-machine powernv -device isa-fdc". This replaces assert() with an error message. Signed-off-by: Alexey Kardashevskiy [thut

[Qemu-devel] [PULL 11/16] tcg: Really fix cpu_io_recompile

2018-03-26 Thread Paolo Bonzini
From: Richard Henderson We have confused the number of instructions that have been executed in the TB with the number of instructions needed to repeat the I/O instruction. We have used cpu_restore_state_from_tb, which means that the guest pc is pointing to the I/O instruction. The only time the

[Qemu-devel] [PULL 08/16] scripts/device-crash-test: Remove fixed isapc-with-iommu entry

2018-03-26 Thread Paolo Bonzini
From: Thomas Huth Fixed in a0c167a18470831e359f0538c3cf67907808f13e ("x86_iommu: check if machine has PCI bus"). Signed-off-by: Thomas Huth Message-Id: <1521193892-15552-5-git-send-email-th...@redhat.com> Signed-off-by: Paolo Bonzini --- scripts/device-crash-test | 1 - 1 file changed, 1 dele

[Qemu-devel] [PULL 16/16] qemu-pr-helper: Actually allow users to specify pidfile

2018-03-26 Thread Paolo Bonzini
From: Michal Privoznik Due to wrong specification of arguments to getopt_long() any attempt to set pidfile resulted in: 1) the default to be leaked 2) the @pidfile variable to be set to NULL (because optarg is NULL without this patch). Signed-off-by: Michal Privoznik Message-Id: <6f10cd53d361

[Qemu-devel] [PULL 12/16] chardev-socket: remove useless if

2018-03-26 Thread Paolo Bonzini
This trips Coverity, which believes the subsequent qio_channel_create_watch can dereference a NULL pointer. In reality, tcp_chr_connect's callers all have s->ioc properly initialized, since they are all rooted at tcp_chr_new_client. Reviewed-by: Marc-André Lureau Signed-off-by: Paolo Bonzini --

[Qemu-devel] [PULL 09/16] vhost-user-test: do not hang if chardev creation failed

2018-03-26 Thread Paolo Bonzini
From: Marc-André Lureau Before the chardev name fix, the following error may happen: "attempt to add duplicate property 'chr-test' to object (type 'container')", due to races. Sadly, error_vprintf() uses g_test_message(), so you have to use read the cryptic --debug-log to see it. Later, it would

[Qemu-devel] [PULL 13/16] scsi: turn "is this a SCSI device?" into a conditional hint

2018-03-26 Thread Paolo Bonzini
If the user does not have permissions to send ioctls to the device (due to SELinux or cgroups, for example), the output can look like qemu-kvm: -device scsi-block,drive=disk: cannot get SG_IO version number: Operation not permitted. Is this a SCSI device? but this is confusing because the ioct

[Qemu-devel] [PULL 14/16] iothread: fix breakage on windows

2018-03-26 Thread Paolo Bonzini
From: Peter Xu OOB can enable iothread for parsing even on Windows. We need some tunes to enable that on Windows otherwise it'll break Windows users. This patch fixes the breakage on Windows with qemu-system-ppc.exe. Reported-by: Howard Spoelstra Tested-by: Howard Spoelstra Suggested-by: Pao

[Qemu-devel] [PULL 15/16] chardev/char-fe: Allow NULL chardev in qemu_chr_fe_init()

2018-03-26 Thread Paolo Bonzini
From: Peter Maydell All the functions in char-fe.c handle the CharBackend having a NULL Chardev pointer, which means that the backend exists but is not connected to anything. The exception is qemu_chr_fe_init(), which will crash if passed a NULL Chardev pointer argument. This can happen for vario

[Qemu-devel] [PULL 10/16] vhost-user-test: add back memfd check

2018-03-26 Thread Paolo Bonzini
From: Marc-André Lureau This revert commit fb68096da3d35e64c88cd610c1fa42766c58e92a, and modify test_read_guest_mem() to use different chardev names, when using memfd (_test_server_free(), where the chardev is removed, runs in idle). Signed-off-by: Marc-André Lureau Message-Id: <20180215212552.

[Qemu-devel] [PATCH v10] vhost: used_memslots refactoring

2018-03-26 Thread Jay Zhou
Used_memslots is shared by vhost kernel and user, it is equal to dev->mem->nregions, which is correct for vhost kernel, but not for vhost user, the latter one uses memory regions that have file descriptor. E.g. a VM has a vhost-user NIC and 8(vhost user memslot upper limit) memory slots, it will be

Re: [Qemu-devel] [PULL 2/2] net/vde: print error on vde_open() failure

2018-03-26 Thread Eric Blake
On 03/26/2018 07:13 AM, Philippe Mathieu-Daudé wrote: Hi Jason, On 03/26/2018 04:00 AM, Jason Wang wrote: From: Julia Suvorova via Qemu-devel This doesn't look right, shouldn't it be Julia Suvorova ? Can patchew be taught to flag mails like this? (The rewrite occurs when a sender's mail

Re: [Qemu-devel] [PATCH v3 2/2] i386/kvm: lower requirements for Hyper-V frequency MSRs exposure

2018-03-26 Thread Roman Kagan
On Fri, Mar 23, 2018 at 04:48:27PM -0300, Eduardo Habkost wrote: > On Fri, Mar 23, 2018 at 12:45:30PM +0300, Roman Kagan wrote: > > On Thu, Mar 22, 2018 at 03:38:13PM -0300, Eduardo Habkost wrote: > > > It looks like the guest can still crash if we migrate > > > "QEMU-2.12 -machine pc-2.11 -cpu ...

Re: [Qemu-devel] [PULL 0/2] Net patches

2018-03-26 Thread Eric Blake
On 03/26/2018 08:14 AM, Peter Maydell wrote: On 26 March 2018 at 08:00, Jason Wang wrote: The following changes since commit 7b1db0908d88f0c9cfac24e214ff72a860692e23: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20180323' into staging (2018-03-25 13:51:33 +0100) ar

Re: [Qemu-devel] [PATCH v4 2/2] i386/kvm: expose Hyper-V frequency MSRs with reenlightenment

2018-03-26 Thread Roman Kagan
On Fri, Mar 23, 2018 at 03:45:49PM +0100, Vitaly Kuznetsov wrote: > Eduardo Habkost writes: > > > On Thu, Mar 22, 2018 at 02:13:58PM +0100, Vitaly Kuznetsov wrote: > >> We can also expose Hyper-V frequency MSRs when reenlightenment feature is > >> enabled and TSC frequency is known, Hyper-V on KV

Re: [Qemu-devel] [PATCH v4 2/9] numa: split out NumaOptions parsing into parse_NumaOptions()

2018-03-26 Thread Eric Blake
On 03/26/2018 03:38 AM, Laurent Vivier wrote:   end: +    if (err) { +    error_propagate(errp, err); +    } "if (err)" is not necessary here.  See scripts/coccinelle/error_propagate_null.cocci. +    parse_NumaOptions(ms, object, &err); + +end:   qapi_free_NumaOptions(object);  

[Qemu-devel] [PULL 09/19] vdi: Fix build with CONFIG_VDI_DEBUG

2018-03-26 Thread Kevin Wolf
Use qemu_uuid_unparse() instead of uuid_unparse() to make vdi.c compile again when CONFIG_VDI_DEBUG is set. In order to prevent future bitrot, replace '#ifdef CONFIG_VDI_DEBUG' by 'if (VDI_DEBUG)' so that the compiler always sees the code. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake --- b

[Qemu-devel] [PULL 03/19] block/quorum: Remove protocol-related fields

2018-03-26 Thread Kevin Wolf
From: Fabiano Rosas The quorum driver is not a protocol so it should implement bdrv_open instead of bdrv_file_open and not provide a protocol_name. Attempts to invoke this driver using protocol syntax (i.e. quorum:) will now fail gracefully: $ qemu-img info quorum:foo qemu-img: Could not op

[Qemu-devel] [PULL 01/19] iotests: 163 is not quick

2018-03-26 Thread Kevin Wolf
From: Eric Blake Testing on ext4, most 'quick' qcow2 tests took less than 5 seconds, but 163 took more than 20. Let's remove it from the quick set. Signed-off-by: Eric Blake Signed-off-by: Kevin Wolf --- tests/qemu-iotests/group | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --g

[Qemu-devel] [PULL 05/19] block/blkreplay: Remove protocol-related fields

2018-03-26 Thread Kevin Wolf
From: Fabiano Rosas The blkreplay driver is not a protocol so it should implement bdrv_open instead of bdrv_file_open and not provide a protocol_name. Attempts to invoke this driver using protocol syntax (i.e. blkreplay:) will now fail gracefully: $ qemu-img info blkreplay:foo qemu-img: Cou

[Qemu-devel] [PULL 06/19] include/block/block_int: Document protocol related functions

2018-03-26 Thread Kevin Wolf
From: Fabiano Rosas Clarify that: - for protocols the brdv_file_open function is used instead of bdrv_open; - when protocol_name is set, a driver should expect to be given only a filename and no other options. Signed-off-by: Fabiano Rosas Signed-off-by: Kevin Wolf --- include/block/block_in

[Qemu-devel] [PULL 00/19] Block layer patches

2018-03-26 Thread Kevin Wolf
The following changes since commit 7b1db0908d88f0c9cfac24e214ff72a860692e23: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20180323' into staging (2018-03-25 13:51:33 +0100) are available in the git repository at: git://repo.or.cz/qemu/kevin.git tags/for-upstream for

[Qemu-devel] [PULL 16/19] vhdx: Require power-of-two block size on create

2018-03-26 Thread Kevin Wolf
Images with a non-power-of-two block size are invalid and cannot be opened. Reject such block sizes when creating an image. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Jeff Cody --- block/vhdx.c | 4 1 file changed, 4 insertions(+) diff --git a/block/vhdx.c b/block/vhd

[Qemu-devel] [PULL 07/19] qcow2: Reset free_cluster_index when allocating a new refcount block

2018-03-26 Thread Kevin Wolf
From: Alberto Garcia When we try to allocate new clusters we first look for available ones starting from s->free_cluster_index and once we find them we increase their reference counts. Before we get to call update_refcount() to do this last step s->free_cluster_index is already pointing to the ne

[Qemu-devel] [PULL 02/19] block/replication: Remove protocol_name field

2018-03-26 Thread Kevin Wolf
From: Fabiano Rosas The protocol_name field is used when selecting a driver via protocol syntax (i.e. :). Drivers that are only selected explicitly (e.g. driver=replication,mode=primary,...) should not have a protocol_name. This patch removes the protocol_name field from the brdv_replication str

[Qemu-devel] [PULL 15/19] qemu-iotests: Test parallels image creation with QMP

2018-03-26 Thread Kevin Wolf
Signed-off-by: Kevin Wolf --- tests/qemu-iotests/212 | 326 + tests/qemu-iotests/212.out | 111 +++ tests/qemu-iotests/group | 1 + 3 files changed, 438 insertions(+) create mode 100755 tests/qemu-iotests/212 create mode 100644 tes

[Qemu-devel] [PULL 11/19] qemu-iotests: Enable 025 for luks

2018-03-26 Thread Kevin Wolf
We want to test resizing even for luks. The only change that is needed is to explicitly zero out new space for luks because it's undefined. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake Reviewed-by: Daniel P. Berrangé --- tests/qemu-iotests/025 | 9 - 1 file changed, 8 insertions(+

[Qemu-devel] [PULL 19/19] qemu-iotests: Test vhdx image creation with QMP

2018-03-26 Thread Kevin Wolf
Signed-off-by: Kevin Wolf --- tests/qemu-iotests/213 | 349 + tests/qemu-iotests/213.out | 121 tests/qemu-iotests/group | 1 + 3 files changed, 471 insertions(+) create mode 100755 tests/qemu-iotests/213 create mode 100644 te

  1   2   3   >