Re: [Qemu-devel] [RFC 19/29] migration: let dst listen on port always

2017-08-02 Thread Peter Xu
On Tue, Aug 01, 2017 at 11:56:10AM +0100, Daniel P. Berrange wrote: > On Fri, Jul 28, 2017 at 04:06:28PM +0800, Peter Xu wrote: > > Signed-off-by: Peter Xu > > --- > > migration/exec.c | 2 +- > > migration/fd.c | 2 +- > > migration/socket.c | 4 ++-- > > 3 files changed, 4 insertions(+),

Re: [Qemu-devel] [PATCH] migration: fix small leaks

2017-08-02 Thread Juan Quintela
Marc-André Lureau wrote: > Spotted thanks to valgrind and tests/device-introspect-test: > > ==11711== 1 bytes in 1 blocks are definitely lost in loss record 6 of 14,537 > ==11711==at 0x4C2EB6B: malloc (vg_replace_malloc.c:299) > ==11711==by 0x1E0CDBD8: g_malloc (gmem.c:94) > ==11711==b

[Qemu-devel] [PATCH] target-i386 : reduce rtc 0x70 access vm-exit time

2017-08-02 Thread Peng Hao
some versions of windows guest access rtc frequently because of rtc as system tick.guest access rtc like this: write register index to 0x70, then write or read data from 0x71. writing 0x70 port is just as index and do nothing else. So writing 0x70 is not necessory to exit to userspace every tim

Re: [Qemu-devel] [PULL 02/17] cpu_physical_memory_sync_dirty_bitmap: Fix alignment check

2017-08-02 Thread Paolo Bonzini
On 01/08/2017 20:04, Dr. David Alan Gilbert wrote: > * Peter Maydell (peter.mayd...@linaro.org) wrote: >> On 1 August 2017 at 17:17, Paolo Bonzini wrote: >>> From: "Dr. David Alan Gilbert" >>> >>> This code has an optimised, word aligned version, and a boring >>> unaligned version. Recently 0841

Re: [Qemu-devel] [for-2.11 PATCH 26/26] spapr: add hotplug hooks for PHB hotplug

2017-08-02 Thread Greg Kurz
On Wed, 2 Aug 2017 12:39:12 +1000 David Gibson wrote: > On Tue, Aug 01, 2017 at 05:30:46PM +0200, Greg Kurz wrote: > > On Fri, 28 Jul 2017 14:24:03 +1000 > > David Gibson wrote: > > > > > On Thu, Jul 27, 2017 at 07:09:55PM +0200, Greg Kurz wrote: > > > > On Thu, 27 Jul 2017 14:41:31 +1000 >

Re: [Qemu-devel] [PATCH] vfio/pci-quirks: Set non-zero GMS memory size for IGD

2017-08-02 Thread Dmitry Fleytman
> On 2 Aug 2017, at 24:24 AM, Alex Williamson > wrote: > > On Fri, 28 Jul 2017 08:22:45 +0300 > Dmitry Fleytman mailto:dmi...@daynix.com>> wrote: > >>> On 28 Jul 2017, at 07:51 AM, Zhang, Xiong Y wrote: >>> > On 26 Jul 2017, at 08:22 AM, Zhang, Xiong Y wrote: > > Sorry

Re: [Qemu-devel] [PATCH for-2.10 0/5] tests: acpi: make sure FADT is compared to reference table

2017-08-02 Thread Igor Mammedov
On Wed, 2 Aug 2017 00:14:18 +0300 "Michael S. Tsirkin" wrote: > On Mon, Jul 31, 2017 at 05:40:47PM +0200, Igor Mammedov wrote: > > While refactoring i386/FADT generation to build_append_int_noprefix() > > > > and testing it, It turned out that FADT is only tested for valid

Re: [Qemu-devel] [for-2.10 PATCH] spapr_drc: fix realize and unrealize

2017-08-02 Thread Greg Kurz
On Fri, 28 Jul 2017 14:27:45 +1000 David Gibson wrote: > On Thu, Jul 27, 2017 at 03:50:37PM -0500, Michael Roth wrote: > > Quoting Greg Kurz (2017-07-27 08:45:47) > > > If object_property_add_alias() returns an error in realize(), we should > > > propagate it to the caller and certainly not unr

Re: [Qemu-devel] [PATCH 1/2] migration: fix comment disorder in RAMState

2017-08-02 Thread Juan Quintela
Peter Xu wrote: > Comments for "migration_dirty_pages" and "bitmap_mutex" are switched. > Fix it. > > Reviewed-by: Dr. David Alan Gilbert > Signed-off-by: Peter Xu Reviewed-by: Juan Quintela

Re: [Qemu-devel] [PATCH 2/2] io: fix qio_channel_socket_accept err handling

2017-08-02 Thread Juan Quintela
Peter Xu wrote: > When accept failed, we should setup errp with the reason. More > importantly, the caller may assume errp be non-NULL when error happens, > and not setting the errp may crash QEMU. > > At the same time, move the trace_qio_channel_socket_accept_fail() after > the if check on EINTR.

Re: [Qemu-devel] [PATCH 4/6] hw/block: Fix the return type

2017-08-02 Thread Mao Zhongyi
Hi On 08/01/2017 10:29 PM, Markus Armbruster wrote: Stefan Hajnoczi writes: On Wed, Jul 26, 2017 at 08:02:53PM +0800, Mao Zhongyi wrote: When the function no success value to transmit, it usually make the function return void. It has turned out not to be a success, because it means that the

Re: [Qemu-devel] [PATCH] watchdog: wdt_aspeed: Add support for the reset width register

2017-08-02 Thread Andrew Jeffery
On Tue, 2017-08-01 at 09:21 +0200, Cédric Le Goater wrote: > On 08/01/2017 03:04 AM, Andrew Jeffery wrote: > > The reset width register controls how the pulse on the SoC's WDTRST{1,2} > > pins behaves. A pulse is emitted if the external reset bit is set in > > WDT_CTRL. WDT_RESET_WIDTH requires mag

Re: [Qemu-devel] [RFC 19/29] migration: let dst listen on port always

2017-08-02 Thread Daniel P. Berrange
On Wed, Aug 02, 2017 at 03:02:24PM +0800, Peter Xu wrote: > On Tue, Aug 01, 2017 at 11:56:10AM +0100, Daniel P. Berrange wrote: > > On Fri, Jul 28, 2017 at 04:06:28PM +0800, Peter Xu wrote: > > > Signed-off-by: Peter Xu > > > --- > > > migration/exec.c | 2 +- > > > migration/fd.c | 2 +- >

Re: [Qemu-devel] [RFC 16/29] qmp: hmp: add migrate "resume" option

2017-08-02 Thread Daniel P. Berrange
On Wed, Aug 02, 2017 at 01:56:46PM +0800, Peter Xu wrote: > On Tue, Aug 01, 2017 at 12:03:48PM +0100, Daniel P. Berrange wrote: > > On Fri, Jul 28, 2017 at 04:06:25PM +0800, Peter Xu wrote: > > > It will be used when we want to resume one paused migration. > > > > > > Signed-off-by: Peter Xu > >

Re: [Qemu-devel] [PATCH 2/2] io: fix qio_channel_socket_accept err handling

2017-08-02 Thread Daniel P. Berrange
On Wed, Aug 02, 2017 at 11:25:21AM +0800, Peter Xu wrote: > When accept failed, we should setup errp with the reason. More > importantly, the caller may assume errp be non-NULL when error happens, > and not setting the errp may crash QEMU. > > At the same time, move the trace_qio_channel_socket_ac

Re: [Qemu-devel] [PATCH 1/3] block: add options parameter to bdrv_new_open_driver()

2017-08-02 Thread Stefan Hajnoczi
On Tue, Aug 01, 2017 at 04:49:05PM +0300, Manos Pitsidianakis wrote: > diff --git a/block.c b/block.c > index 37e72b7a96..886a457ab0 100644 > --- a/block.c > +++ b/block.c > @@ -1149,16 +1149,26 @@ free_and_fail: > return ret; > } > > +/* > + * If options is not NULL it is cloned (which add

Re: [Qemu-devel] [PATCH 2/2] io: fix qio_channel_socket_accept err handling

2017-08-02 Thread Peter Xu
On Wed, Aug 02, 2017 at 10:30:20AM +0100, Daniel P. Berrange wrote: > On Wed, Aug 02, 2017 at 11:25:21AM +0800, Peter Xu wrote: > > When accept failed, we should setup errp with the reason. More > > importantly, the caller may assume errp be non-NULL when error happens, > > and not setting the errp

[Qemu-devel] [PATCH v2 0/2] migration: fixes for 2.10

2017-08-02 Thread Peter Xu
v2: - patch 2: move trace_*() after error_setg_errno(). [Dan] Two patches isolated from the postcopy recovery series, which may be good for 2.10. Peter Xu (2): migration: fix comment disorder in RAMState io: fix qio_channel_socket_accept err handling io/channel-socket.c | 3 ++- migration/r

[Qemu-devel] [PATCH v2 2/2] io: fix qio_channel_socket_accept err handling

2017-08-02 Thread Peter Xu
When accept failed, we should setup errp with the reason. More importantly, the caller may assume errp be non-NULL when error happens, and not setting the errp may crash QEMU. At the same time, move the trace_qio_channel_socket_accept_fail() after the if check on EINTR. Two reasons: 1. when EINTR

Re: [Qemu-devel] [PATCH v2 2/2] io: fix qio_channel_socket_accept err handling

2017-08-02 Thread Daniel P. Berrange
On Wed, Aug 02, 2017 at 05:41:20PM +0800, Peter Xu wrote: > When accept failed, we should setup errp with the reason. More > importantly, the caller may assume errp be non-NULL when error happens, > and not setting the errp may crash QEMU. > > At the same time, move the trace_qio_channel_socket_ac

[Qemu-devel] [PATCH v2 1/2] migration: fix comment disorder in RAMState

2017-08-02 Thread Peter Xu
Comments for "migration_dirty_pages" and "bitmap_mutex" are switched. Fix it. Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela Signed-off-by: Peter Xu --- migration/ram.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/migration/ram.c b/migration/ram.c ind

Re: [Qemu-devel] [PATCH 2/3] block: skip implicit nodes in snapshots, blockjobs

2017-08-02 Thread Stefan Hajnoczi
On Tue, Aug 01, 2017 at 04:49:06PM +0300, Manos Pitsidianakis wrote: > diff --git a/block.c b/block.c > index 886a457ab0..9ebdba28b0 100644 > --- a/block.c > +++ b/block.c > @@ -4947,3 +4947,20 @@ bool bdrv_can_store_new_dirty_bitmap(BlockDriverState > *bs, const char *name, > > return drv-

Re: [Qemu-devel] [PATCH v2 1/2] s390x/css: use macro for event-information pending error recover code

2017-08-02 Thread Cornelia Huck
On Wed, 2 Aug 2017 09:15:18 +0800 Dong Jia Shi wrote: > * Halil Pasic [2017-08-01 17:24:10 +0200]: > > > > > > > On 08/01/2017 09:57 AM, Dong Jia Shi wrote: > > > Let's use a macro for the ERC (error recover code) when generating a > > > Channel Subsystem Event-information pending CRW (chan

[Qemu-devel] [PATCH for-2.10 0/3] target/mips: Fix fallout from indirect branch optimisation

2017-08-02 Thread James Hogan
Primarily patch 1 fixes some fallout from the recent indirect branch optimisations in v2.10.0-rc0, where interrupt handling may be delayed after interrupts are enabled until it is too late. Patch 2 and 3 then fix a couple of other loosely related issues spotted in the process or in testing. Pleas

[Qemu-devel] [PATCH for-2.10 3/3] target/mips: Fix RDHWR CC with icount

2017-08-02 Thread James Hogan
RDHWR CC reads the CPU timer like MFC0 CP0_Count, so with icount enabled it must set can_do_io while it calls the helper to avoid the "Bad icount read" error. It should also break out of the translation loop to ensure that timer interrupts are immediately handled. Fixes: 2e70f6efa8b9 ("Add instruc

[Qemu-devel] [PATCH for-2.10 2/3] target/mips: Drop redundant gen_io_start/stop()

2017-08-02 Thread James Hogan
DMTC0 CP0_Cause does a redundant gen_io_start() and gen_io_end() pair, even though this is done for all DMTC0 operations outside of the switch statement. Remove these redundant calls. Fixes: 5dc5d9f055c5 ("mips: more fixes to the MIPS interrupt glue logic") Signed-off-by: James Hogan Cc: Yongbok

[Qemu-devel] [PATCH for-2.10 1/3] target/mips: Use BS_EXCP where interrupts are expected

2017-08-02 Thread James Hogan
Commit e350d8ca3ac7 ("target/mips: optimize indirect branches") made indirect branches able to directly find the next TB and jump straight to it without breaking out of translated code and going around the main execution loop. This breaks the assumption in target/mips/translate.c that BS_STOP is su

Re: [Qemu-devel] [PATCH v2 2/2] s390x/css: generate solicited crw for rchp completion signaling

2017-08-02 Thread Cornelia Huck
On Tue, 1 Aug 2017 17:16:37 +0200 Halil Pasic wrote: > On 08/01/2017 09:57 AM, Dong Jia Shi wrote: > [..] > > --- a/hw/s390x/css.c > > +++ b/hw/s390x/css.c > > @@ -1745,10 +1745,10 @@ int css_do_rchp(uint8_t cssid, uint8_t chpid) > > } > > > > /* We don't really use a channel path, so

Re: [Qemu-devel] [PATCH 3/3] block: remove legacy I/O throttling

2017-08-02 Thread Stefan Hajnoczi
On Tue, Aug 01, 2017 at 04:49:07PM +0300, Manos Pitsidianakis wrote: > diff --git a/block.c b/block.c > index 9ebdba28b0..c6aad25286 100644 > --- a/block.c > +++ b/block.c > @@ -1975,6 +1975,7 @@ BdrvChild *bdrv_root_attach_child(BlockDriverState > *child_bs, > child = g_new(BdrvChild, 1); >

Re: [Qemu-devel] [PULL 00/10] pc, acpi, virtio: fixes, test speedup for rc1

2017-08-02 Thread Peter Maydell
On 1 August 2017 at 22:37, Michael S. Tsirkin wrote: > The following changes since commit 7d48cf8102a10e4a54333811bafb5eb566509268: > > Merge remote-tracking branch 'remotes/stefanha/tags/tracing-pull-request' > into staging (2017-08-01 14:33:56 +0100) > > are available in the git repository at

Re: [Qemu-devel] [PATCH] migration: fix small leaks

2017-08-02 Thread Dr. David Alan Gilbert
* Marc-André Lureau (marcandre.lur...@redhat.com) wrote: > Spotted thanks to valgrind and tests/device-introspect-test: > > ==11711== 1 bytes in 1 blocks are definitely lost in loss record 6 of 14,537 > ==11711==at 0x4C2EB6B: malloc (vg_replace_malloc.c:299) > ==11711==by 0x1E0CDBD8: g_mal

Re: [Qemu-devel] [PATCH 1/1] qemu-iotests/109: Fix lock race condition

2017-08-02 Thread Kevin Wolf
Am 01.08.2017 um 23:31 hat Cleber Rosa geschrieben: > A race condition is currently present between the clean up attempt of > the QEMU process and the execution of qemu-img. The actual (bad) > output is: > > -Warning: Image size mismatch! > -Images are identical. > +qemu-img: Could not open '/

Re: [Qemu-devel] [PATCH v2 0/2] migration: fixes for 2.10

2017-08-02 Thread Dr. David Alan Gilbert
* Peter Xu (pet...@redhat.com) wrote: > v2: > - patch 2: move trace_*() after error_setg_errno(). [Dan] > > Two patches isolated from the postcopy recovery series, which may be > good for 2.10. Queued > Peter Xu (2): > migration: fix comment disorder in RAMState > io: fix qio_channel_socket_

Re: [Qemu-devel] [PATCH 3/3] block: remove legacy I/O throttling

2017-08-02 Thread Kevin Wolf
Am 02.08.2017 um 12:07 hat Stefan Hajnoczi geschrieben: > On Tue, Aug 01, 2017 at 04:49:07PM +0300, Manos Pitsidianakis wrote: > > diff --git a/block.c b/block.c > > index 9ebdba28b0..c6aad25286 100644 > > --- a/block.c > > +++ b/block.c > > @@ -1975,6 +1975,7 @@ BdrvChild *bdrv_root_attach_child(B

Re: [Qemu-devel] [PATCH 3/3] block: remove legacy I/O throttling

2017-08-02 Thread Manos Pitsidianakis
On Wed, Aug 02, 2017 at 11:07:24AM +0100, Stefan Hajnoczi wrote: On Tue, Aug 01, 2017 at 04:49:07PM +0300, Manos Pitsidianakis wrote: diff --git a/block.c b/block.c index 9ebdba28b0..c6aad25286 100644 --- a/block.c +++ b/block.c @@ -1975,6 +1975,7 @@ BdrvChild *bdrv_root_attach_child(BlockDriver

Re: [Qemu-devel] [PATCH v3 4/7] block: convert ThrottleGroup to object with QOM

2017-08-02 Thread Stefan Hajnoczi
On Tue, Aug 01, 2017 at 07:49:33PM +0300, Manos Pitsidianakis wrote: > On Tue, Aug 01, 2017 at 04:47:03PM +0100, Stefan Hajnoczi wrote: > > On Mon, Jul 31, 2017 at 12:54:40PM +0300, Manos Pitsidianakis wrote: > > > ThrottleGroup is converted to an object. This will allow the future > > > throttle b

[Qemu-devel] [PATCH] cpu: don't allow negative core id

2017-08-02 Thread Laurent Vivier
With pseries machine type a negative core-id is not managed properly: -1 gives an inaccurate error message ("core -1 already populated"), -2 crashes QEMU (core dump) As it seems a negative value is invalid for any architecture, instead of checking this in spapr_core_pre_plug() I think it's better

Re: [Qemu-devel] [RFC] block-insert-node and block-job-delete

2017-08-02 Thread Stefan Hajnoczi
On Fri, Jul 28, 2017 at 01:55:38PM +0200, Kevin Wolf wrote: > Am 28.07.2017 um 00:09 hat John Snow geschrieben: > > On 07/26/2017 02:23 PM, Manos Pitsidianakis wrote: > > > On Wed, Jul 26, 2017 at 04:12:21PM +0100, Stefan Hajnoczi wrote: > > > > On Wed, Jul 26, 2017 at 05:19:24PM +0300, Manos Pitsi

Re: [Qemu-devel] [PATCH v3 4/7] block: convert ThrottleGroup to object with QOM

2017-08-02 Thread Manos Pitsidianakis
On Wed, Aug 02, 2017 at 11:39:22AM +0100, Stefan Hajnoczi wrote: On Tue, Aug 01, 2017 at 07:49:33PM +0300, Manos Pitsidianakis wrote: On Tue, Aug 01, 2017 at 04:47:03PM +0100, Stefan Hajnoczi wrote: > On Mon, Jul 31, 2017 at 12:54:40PM +0300, Manos Pitsidianakis wrote: > > ThrottleGroup is conve

Re: [Qemu-devel] [RFC 19/29] migration: let dst listen on port always

2017-08-02 Thread Peter Xu
On Wed, Aug 02, 2017 at 10:26:48AM +0100, Daniel P. Berrange wrote: > On Wed, Aug 02, 2017 at 03:02:24PM +0800, Peter Xu wrote: > > On Tue, Aug 01, 2017 at 11:56:10AM +0100, Daniel P. Berrange wrote: > > > On Fri, Jul 28, 2017 at 04:06:28PM +0800, Peter Xu wrote: > > > > Signed-off-by: Peter Xu >

Re: [Qemu-devel] [PATCH 00/13] instrument: Add basic event instrumentation

2017-08-02 Thread Stefan Hajnoczi
On Tue, Aug 01, 2017 at 02:54:29PM +0100, Peter Maydell wrote: > On 1 August 2017 at 14:48, Stefan Hajnoczi wrote: > > Thanks for sharing the requirements. A stable API is necessary for > > providing these features. > > > > We're essentially talking about libqemu. That means QEMU in library > >

Re: [Qemu-devel] [PATCH 00/13] instrument: Add basic event instrumentation

2017-08-02 Thread Stefan Hajnoczi
On Fri, Jul 28, 2017 at 07:21:04PM +0300, Lluís Vilanova wrote: > Stefan Hajnoczi writes: > > > On Thu, Jul 27, 2017 at 11:40:17AM +0100, Peter Maydell wrote: > >> On 27 July 2017 at 11:32, Stefan Hajnoczi wrote: > >> > On Wed, Jul 26, 2017 at 03:44:39PM +0300, Lluís Vilanova wrote: > >> >> And w

Re: [Qemu-devel] [PATCH 00/13] instrument: Add basic event instrumentation

2017-08-02 Thread Peter Maydell
On 2 August 2017 at 12:04, Stefan Hajnoczi wrote: > On Tue, Aug 01, 2017 at 02:54:29PM +0100, Peter Maydell wrote: >> and I don't need the TCG engine to be a library to do that... > > You do need TCG APIs if you want TCG-level instrumentation, tuning > options, callbacks, etc. I need an API; that

[Qemu-devel] Where is the VM live migration code?

2017-08-02 Thread Aditya Bhardwaj
My lab setup is: 3 HP Servers each of 4 GB RAM. Server 1 and Server 2: installed with Virtualization using KVM on Redhat 6.5 System. On top of this I am using libvirtd for managing virtual machines. NFS server is installed on Server 3 for shared disk image. VM migration is working correctly. Now i

[Qemu-devel] Where is the VM live migration code?

2017-08-02 Thread Aditya Bhardwaj
My lab setup is: 3 HP Servers each of 4 GB RAM. Server 1 and Server 2: installed with Virtualization using KVM on Redhat 6.5 System. On top of this I am using libvirtd for managing virtual machines. NFS server is installed on Server 3 for shared disk image. VM migration is working correctly. Now i

[Qemu-devel] [PATCH] firmware: add const to bin_attribute structures

2017-08-02 Thread Bhumika Goyal
Add const to bin_attribute structures as they are only passed to the functions sysfs_{remove/create}_bin_file. The arguments passed are of type const, so declare the structures to be const. Done using Coccinelle. @m disable optional_qualifier@ identifier s; position p; @@ static struct bin_attrib

Re: [Qemu-devel] Where is the VM live migration code?

2017-08-02 Thread Daniel P. Berrange
On Wed, Aug 02, 2017 at 04:25:08PM +0530, Aditya Bhardwaj wrote: > My lab setup is: 3 HP Servers each of 4 GB RAM. Server 1 and Server 2: > installed with Virtualization using KVM on Redhat 6.5 System. On top of > this I am using libvirtd for managing virtual machines. NFS server is > installed on

Re: [Qemu-devel] [PATCH v3 1/6] seccomp: changing from whitelist to blacklist

2017-08-02 Thread Daniel P. Berrange
On Fri, Jul 28, 2017 at 02:10:35PM +0200, Eduardo Otubo wrote: > This patch changes the default behavior of the seccomp filter from > whitelist to blacklist. By default now all system calls are allowed and > a small black list of definitely forbidden ones was created. > > Signed-off-by: Eduardo Ot

Re: [Qemu-devel] [PATCH v3 5/5] docs: update documentation considering PCIE-PCI bridge

2017-08-02 Thread Marcel Apfelbaum
On 02/08/2017 1:23, Laszlo Ersek wrote: On 08/01/17 23:39, Michael S. Tsirkin wrote: On Wed, Aug 02, 2017 at 12:33:12AM +0300, Alexander Bezzubikov wrote: 2017-08-01 23:31 GMT+03:00 Laszlo Ersek : (Whenever my comments conflict with Michael's or Marcel's, I defer to them.) On 07/29/17 01:37,

Re: [Qemu-devel] [PATCH] virtio: Mark virtio-device as non-user-creatable

2017-08-02 Thread Halil Pasic
On 08/02/2017 01:01 AM, Eduardo Habkost wrote: > TYPE_VIRTIO_DEVICE devices are already not usable with -device > and device_add, but they are reported as user-creatable on > "-device help" and through monitor interfaces. I've tried -device virtio-rng on s390x and from what I see, it seems we 'a

Re: [Qemu-devel] Where is the VM live migration code?

2017-08-02 Thread Eric Blake
On 08/02/2017 07:18 AM, Daniel P. Berrange wrote: > On Wed, Aug 02, 2017 at 04:25:08PM +0530, Aditya Bhardwaj wrote: >> My lab setup is: 3 HP Servers each of 4 GB RAM. Server 1 and Server 2: >> installed with Virtualization using KVM on Redhat 6.5 System. On top of >> this I am using libvirtd for m

Re: [Qemu-devel] [PATCH v3 2/6] seccomp: add obsolete argument to command line

2017-08-02 Thread Daniel P. Berrange
On Fri, Jul 28, 2017 at 02:10:36PM +0200, Eduardo Otubo wrote: > This patch introduces the argument [,obsolete=allow] to the `-sandbox on' > option. It allows Qemu to run safely on old system that still relies on > old system calls. > > Signed-off-by: Eduardo Otubo > --- > include/sysemu/seccomp

Re: [Qemu-devel] [PATCH v3 3/6] seccomp: add elevateprivileges argument to command line

2017-08-02 Thread Daniel P. Berrange
On Fri, Jul 28, 2017 at 02:10:37PM +0200, Eduardo Otubo wrote: > This patch introduces the new argument > [,elevateprivileges=allow|deny|children] to the `-sandbox on'. It allows > or denies Qemu process to elevate its privileges by blacklisting all > set*uid|gid system calls. The 'children' option

Re: [Qemu-devel] [PATCH v3 2/6] seccomp: add obsolete argument to command line

2017-08-02 Thread Daniel P. Berrange
On Wed, Aug 02, 2017 at 01:33:56PM +0100, Daniel P. Berrange wrote: > On Fri, Jul 28, 2017 at 02:10:36PM +0200, Eduardo Otubo wrote: > > This patch introduces the argument [,obsolete=allow] to the `-sandbox on' > > option. It allows Qemu to run safely on old system that still relies on > > old syst

Re: [Qemu-devel] [PATCH v3 6/6] seccomp: adding documentation to new seccomp model

2017-08-02 Thread Daniel P. Berrange
On Fri, Jul 28, 2017 at 02:10:40PM +0200, Eduardo Otubo wrote: > Adding new documention under docs/ to describe every one and each new > option added by the seccomp refactoring patchset. > > Signed-off-by: Eduardo Otubo > --- > docs/seccomp.txt | 31 +++ > 1 file chan

Re: [Qemu-devel] [PATCH v2 1/4] qemu-img: Sort sub-command names in --help

2017-08-02 Thread Daniel P. Berrange
On Fri, Jul 28, 2017 at 11:47:05AM -0500, Eric Blake wrote: > 'amend' was the only sub-command not listed alphabetically; hoist > it earlier, and separate the @end table block to make it easier > to copy-and-paste the addition of future sub-commands. > > Signed-off-by: Eric Blake > --- > qemu-im

Re: [Qemu-devel] >256 Virtio-net-pci hotplug Devices

2017-08-02 Thread Marcel Apfelbaum
On 25/07/2017 21:00, Kinsella, Ray wrote: Hi Marcel, Hi Ray, On 24/07/2017 00:14, Marcel Apfelbaum wrote: On 24/07/2017 7:53, Kinsella, Ray wrote: Even if I am not aware of how much time would take to init a bare-metal PCIe Root Port, it seems too much. So I repeated the testing for 64

Re: [Qemu-devel] [PATCH v2 2/4] qemu-io: Give more --version information

2017-08-02 Thread Daniel P. Berrange
On Fri, Jul 28, 2017 at 11:47:06AM -0500, Eric Blake wrote: > Include the package version information (useful for detecting > builds from git or downstream backports), and the copyright notice. > > Signed-off-by: Eric Blake > --- > qemu-io.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletio

Re: [Qemu-devel] [PATCH v2 3/4] qga: Give more --version information

2017-08-02 Thread Daniel P. Berrange
On Fri, Jul 28, 2017 at 11:47:07AM -0500, Eric Blake wrote: > Include the package version information (useful for detecting > builds from git or downstream backports), and the copyright notice. > > Signed-off-by: Eric Blake > --- > qga/main.c | 6 -- > 1 file changed, 4 insertions(+), 2 dele

Re: [Qemu-devel] [PATCH v2 4/4] maint: Include bug-reporting info in --help output.

2017-08-02 Thread Daniel P. Berrange
On Fri, Jul 28, 2017 at 11:47:08AM -0500, Eric Blake wrote: > These days, many programs are including a bug-reporting address, > or better yet, a link to the project web site, at the tail of > their --help output. However, we were not very consistent at > doing so: only qemu-nbd and qemu-qa mentio

Re: [Qemu-devel] Where is the VM live migration code?

2017-08-02 Thread Dr. David Alan Gilbert
* Aditya Bhardwaj (adityaf...@gmail.com) wrote: > My lab setup is: 3 HP Servers each of 4 GB RAM. Server 1 and Server 2: > installed with Virtualization using KVM on Redhat 6.5 System. On top of > this I am using libvirtd for managing virtual machines. NFS server is > installed on Server 3 for shar

Re: [Qemu-devel] Where is the VM live migration code?

2017-08-02 Thread Daniel P. Berrange
On Wed, Aug 02, 2017 at 01:49:44PM +0100, Dr. David Alan Gilbert wrote: > * Aditya Bhardwaj (adityaf...@gmail.com) wrote: > > My lab setup is: 3 HP Servers each of 4 GB RAM. Server 1 and Server 2: > > installed with Virtualization using KVM on Redhat 6.5 System. On top of > > this I am using libvir

Re: [Qemu-devel] [PATCH for-2.10 1/5] tests: acpi: move tested tables array allocation outside of test_acpi_dsdt_table()

2017-08-02 Thread Marcel Apfelbaum
On 31/07/2017 18:40, Igor Mammedov wrote: at best it's confusing that array for list of tables to be tested against reference tables is allocated within test_acpi_dsdt_table() and at worst it would just overwrite list of tables if they were added before test_acpi_dsdt_table(). Move array initiali

Re: [Qemu-devel] [PATCH for-2.10 2/5] tests: acpi: init table descriptor in test_dst_table()

2017-08-02 Thread Marcel Apfelbaum
On 31/07/2017 18:40, Igor Mammedov wrote: remove code duplication and make sure that table descriptor passed in for initialization is in expected state. Signed-off-by: Igor Mammedov --- tests/bios-tables-test.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tests/bios

Re: [Qemu-devel] [PATCH for-2.10 3/5] tests: acpi: rename test_acpi_tables()/test_dst_table() to reflect its usage

2017-08-02 Thread Marcel Apfelbaum
On 31/07/2017 18:40, Igor Mammedov wrote: Main purpose of test_dst_table() is loading a table from QEMU with checking that checksum in header matches actual one, rename it reflect main action it performs. Likewise test_acpi_tables() name is to broad, while the function only loads tables referenc

Re: [Qemu-devel] [PATCH for-2.10 4/5] tests: acpi: add comments to fetch_rsdt_referenced_tables/data->tables usage

2017-08-02 Thread Marcel Apfelbaum
On 31/07/2017 18:40, Igor Mammedov wrote: Signed-off-by: Igor Mammedov --- tests/bios-tables-test.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/bios-tables-test.c b/tests/bios-tables-test.c index ed32e9a..a2a90d7 100644 --- a/tests/bios-tables-test.c +++ b/tests/bios-tables-t

Re: [Qemu-devel] [PATCH] virtio: Mark virtio-device as non-user-creatable

2017-08-02 Thread Eduardo Habkost
On Tue, Aug 01, 2017 at 08:01:55PM -0300, Eduardo Habkost wrote: > TYPE_VIRTIO_DEVICE devices are already not usable with -device > and device_add, but they are reported as user-creatable on > "-device help" and through monitor interfaces. > > Mark them as not user-creatable to avoid confusing use

Re: [Qemu-devel] [PATCH for-2.10 5/5] tests: acpi: fix FADT not being compared to reference table

2017-08-02 Thread Marcel Apfelbaum
On 31/07/2017 18:40, Igor Mammedov wrote: It turns out that FADT isn't actually tested for changes against reference table, since it happens to be the 1st table in RSDT which is currently ignored. Fix it by making sure that all tables from RSDT are added to test list. Hi Igor, Signed-off-by:

Re: [Qemu-devel] [PATCH v6 2/7] qemu.py: fix is_running() return before first launch()

2017-08-02 Thread Stefan Hajnoczi
On Tue, Aug 01, 2017 at 02:56:55PM +0200, Amador Pahim wrote: > On Tue, Aug 1, 2017 at 12:50 PM, Eduardo Habkost wrote: > > On Tue, Aug 01, 2017 at 11:09:25AM +0100, Stefan Hajnoczi wrote: > >> On Mon, Jul 31, 2017 at 10:51:05AM +0200, Amador Pahim wrote: > >> > is_running() returns None when call

Re: [Qemu-devel] [PATCH] cpu: don't allow negative core id

2017-08-02 Thread Philippe Mathieu-Daudé
Hi Laurent, On Wed, Aug 2, 2017 at 7:32 AM, Laurent Vivier wrote: > With pseries machine type a negative core-id is not managed properly: > -1 gives an inaccurate error message ("core -1 already populated"), > -2 crashes QEMU (core dump) > > As it seems a negative value is invalid for any archite

Re: [Qemu-devel] [PATCH v3 5/5] docs: update documentation considering PCIE-PCI bridge

2017-08-02 Thread Michael S. Tsirkin
On Wed, Aug 02, 2017 at 12:23:46AM +0200, Laszlo Ersek wrote: > On 08/01/17 23:39, Michael S. Tsirkin wrote: > > On Wed, Aug 02, 2017 at 12:33:12AM +0300, Alexander Bezzubikov wrote: > >> 2017-08-01 23:31 GMT+03:00 Laszlo Ersek : > >>> (Whenever my comments conflict with Michael's or Marcel's, I de

Re: [Qemu-devel] [PATCH] cpu: don't allow negative core id

2017-08-02 Thread Laurent Vivier
On 02/08/2017 15:42, Philippe Mathieu-Daudé wrote: > Hi Laurent, > > On Wed, Aug 2, 2017 at 7:32 AM, Laurent Vivier wrote: >> With pseries machine type a negative core-id is not managed properly: >> -1 gives an inaccurate error message ("core -1 already populated"), >> -2 crashes QEMU (core dump)

Re: [Qemu-devel] [Qemu-ppc] [PATCH] cpu: don't allow negative core id

2017-08-02 Thread Greg Kurz
On Wed, 2 Aug 2017 12:32:59 +0200 Laurent Vivier wrote: > With pseries machine type a negative core-id is not managed properly: > -1 gives an inaccurate error message ("core -1 already populated"), > -2 crashes QEMU (core dump) > > As it seems a negative value is invalid for any architecture, >

[Qemu-devel] [PATCH] target-mips: apply CP0.PageMask before writing into TLB entry

2017-08-02 Thread Yongbok Kim
From: Leon Alrae PFN0 and PFN1 have to be masked out with PageMask_Mask. Signed-off-by: Leon Alrae Reviewed-by: Yongbok Kim [Yongbok Kim: Added commit message] Signed-off-by: Yongbok Kim --- target/mips/op_helper.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ta

[Qemu-devel] [PULL 0/3] migration queue

2017-08-02 Thread Dr. David Alan Gilbert (git)
From: "Dr. David Alan Gilbert" The following changes since commit d3d183a638d6a3ead515618a6547b3f80d39fcb9: Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging (2017-08-02 09:49:02 +0100) are available in the git repository at: git://github.com/dagrh/qemu.git tags/pu

[Qemu-devel] [PULL 2/3] migration: fix comment disorder in RAMState

2017-08-02 Thread Dr. David Alan Gilbert (git)
From: Peter Xu Comments for "migration_dirty_pages" and "bitmap_mutex" are switched. Fix it. Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Juan Quintela Signed-off-by: Peter Xu Message-Id: <1501666880-10159-2-git-send-email-pet...@redhat.com> Signed-off-by: Dr. David Alan Gilbert --- mig

[Qemu-devel] [PULL 3/3] io: fix qio_channel_socket_accept err handling

2017-08-02 Thread Dr. David Alan Gilbert (git)
From: Peter Xu When accept failed, we should setup errp with the reason. More importantly, the caller may assume errp be non-NULL when error happens, and not setting the errp may crash QEMU. At the same time, move the trace_qio_channel_socket_accept_fail() after the if check on EINTR. Two reason

[Qemu-devel] [PULL 1/3] migration: fix small leaks

2017-08-02 Thread Dr. David Alan Gilbert (git)
From: Marc-André Lureau Spotted thanks to valgrind and tests/device-introspect-test: ==11711== 1 bytes in 1 blocks are definitely lost in loss record 6 of 14,537 ==11711==at 0x4C2EB6B: malloc (vg_replace_malloc.c:299) ==11711==by 0x1E0CDBD8: g_malloc (gmem.c:94) ==11711==by 0x1E0E696

Re: [Qemu-devel] [PATCH] slirp: check len against dhcp options array end

2017-08-02 Thread Michael Tokarev
17.07.2017 17:48, Samuel Thibault wrote: > P J P, on lun. 17 juil. 2017 17:33:26 +0530, wrote: >> From: Prasad J Pandit >> >> While parsing dhcp options string in 'dhcp_decode', if an options' >> length 'len' appeared towards the end of 'bp_vend' array, ensuing >> read could lead to an OOB memory

Re: [Qemu-devel] [PATCH for-2.10 5/5] tests: acpi: fix FADT not being compared to reference table

2017-08-02 Thread Igor Mammedov
On Wed, 2 Aug 2017 16:15:10 +0300 Marcel Apfelbaum wrote: > On 31/07/2017 18:40, Igor Mammedov wrote: > > It turns out that FADT isn't actually tested for changes > > against reference table, since it happens to be the 1st > > table in RSDT which is currently ignored. > > Fix it by making sure th

Re: [Qemu-devel] [PATCH v3 5/5] docs: update documentation considering PCIE-PCI bridge

2017-08-02 Thread Laszlo Ersek
On 08/02/17 15:47, Michael S. Tsirkin wrote: > On Wed, Aug 02, 2017 at 12:23:46AM +0200, Laszlo Ersek wrote: >> On 08/01/17 23:39, Michael S. Tsirkin wrote: >>> On Wed, Aug 02, 2017 at 12:33:12AM +0300, Alexander Bezzubikov wrote: 2017-08-01 23:31 GMT+03:00 Laszlo Ersek : > (Whenever my co

Re: [Qemu-devel] [PATCH v3 5/5] docs: update documentation considering PCIE-PCI bridge

2017-08-02 Thread Marcel Apfelbaum
On 02/08/2017 17:16, Laszlo Ersek wrote: On 08/02/17 15:47, Michael S. Tsirkin wrote: On Wed, Aug 02, 2017 at 12:23:46AM +0200, Laszlo Ersek wrote: On 08/01/17 23:39, Michael S. Tsirkin wrote: On Wed, Aug 02, 2017 at 12:33:12AM +0300, Alexander Bezzubikov wrote: 2017-08-01 23:31 GMT+03:00 Las

Re: [Qemu-devel] [for-2.10 PATCH] spapr_drc: fix realize and unrealize

2017-08-02 Thread David Gibson
On Wed, Aug 02, 2017 at 10:14:56AM +0200, Greg Kurz wrote: > On Fri, 28 Jul 2017 14:27:45 +1000 > David Gibson wrote: > > > On Thu, Jul 27, 2017 at 03:50:37PM -0500, Michael Roth wrote: > > > Quoting Greg Kurz (2017-07-27 08:45:47) > > > > If object_property_add_alias() returns an error in real

Re: [Qemu-devel] [PATCH] cpu: don't allow negative core id

2017-08-02 Thread David Gibson
On Wed, Aug 02, 2017 at 12:32:59PM +0200, Laurent Vivier wrote: > With pseries machine type a negative core-id is not managed properly: > -1 gives an inaccurate error message ("core -1 already populated"), > -2 crashes QEMU (core dump) > > As it seems a negative value is invalid for any architectu

Re: [Qemu-devel] [PATCH 3/3] block: remove legacy I/O throttling

2017-08-02 Thread Stefan Hajnoczi
On Wed, Aug 02, 2017 at 01:34:46PM +0300, Manos Pitsidianakis wrote: > On Wed, Aug 02, 2017 at 11:07:24AM +0100, Stefan Hajnoczi wrote: > > On Tue, Aug 01, 2017 at 04:49:07PM +0300, Manos Pitsidianakis wrote: > > > @@ -3729,6 +3731,12 @@ const char *bdrv_get_parent_name(const > > > BlockDriverStat

Re: [Qemu-devel] [PATCH] vl.c/exit: pause cpus before closing block devices

2017-08-02 Thread Alberto Garcia
On Thu, Jul 13, 2017 at 08:01:16PM +0100, Dr. David Alan Gilbert (git) wrote: > --- a/vl.c > +++ b/vl.c > @@ -4787,8 +4787,8 @@ int main(int argc, char **argv, char **envp) > replay_disable_events(); > iothread_stop_all(); > > -bdrv_close_all(); > pause_all_vcpus(); > +bdrv

Re: [Qemu-devel] [PATCH v3 4/7] block: convert ThrottleGroup to object with QOM

2017-08-02 Thread Stefan Hajnoczi
On Wed, Aug 02, 2017 at 01:57:04PM +0300, Manos Pitsidianakis wrote: > On Wed, Aug 02, 2017 at 11:39:22AM +0100, Stefan Hajnoczi wrote: > > On Tue, Aug 01, 2017 at 07:49:33PM +0300, Manos Pitsidianakis wrote: > > > On Tue, Aug 01, 2017 at 04:47:03PM +0100, Stefan Hajnoczi wrote: > > > > On Mon, Jul

[Qemu-devel] [PATCH] kvm: workaround build break on gcc-7.1.1 / fedora26

2017-08-02 Thread Greg Kurz
Building QEMU on fedora26 with the latest gcc package fails: CC ppc64-softmmu/target/ppc/kvm.o In file included from include/sysemu/hw_accel.h:16:0, from target/ppc/kvm.c:31: target/ppc/kvm.c: In function ‘kvmppc_booke_watchdog_enable’: include/sysemu/kvm.h:449:35: error: ‘

[Qemu-devel] KVM call for 2017-08-15

2017-08-02 Thread Juan Quintela
Hi Please, send any topic that you are interested in covering. At the end of Monday I will send an email with the agenda or the cancellation of the call, so hurry up. After discussions on the QEMU Summit, we are going to have always open a KVM call where you can add topics. Call details: By

Re: [Qemu-devel] [PATCH 00/13] instrument: Add basic event instrumentation

2017-08-02 Thread Stefan Hajnoczi
On Wed, Aug 02, 2017 at 12:10:14PM +0100, Peter Maydell wrote: > On 2 August 2017 at 12:04, Stefan Hajnoczi wrote: > > On Tue, Aug 01, 2017 at 02:54:29PM +0100, Peter Maydell wrote: > >> and I don't need the TCG engine to be a library to do that... > > > > You do need TCG APIs if you want TCG-leve

Re: [Qemu-devel] [PULL 0/3] migration queue

2017-08-02 Thread Peter Maydell
On 2 August 2017 at 14:58, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > The following changes since commit d3d183a638d6a3ead515618a6547b3f80d39fcb9: > > Merge remote-tracking branch 'remotes/mst/tags/for_upstream' into staging > (2017-08-02 09:49:02 +0100) > > are a

Re: [Qemu-devel] [PATCH for-2.10 1/3] target/mips: Use BS_EXCP where interrupts are expected

2017-08-02 Thread Richard Henderson
On 08/02/2017 02:59 AM, James Hogan wrote: Commit e350d8ca3ac7 ("target/mips: optimize indirect branches") made indirect branches able to directly find the next TB and jump straight to it without breaking out of translated code and going around the main execution loop. This breaks the assumption

Re: [Qemu-devel] [PATCH for-2.10 3/3] target/mips: Fix RDHWR CC with icount

2017-08-02 Thread Richard Henderson
On 08/02/2017 02:59 AM, James Hogan wrote: RDHWR CC reads the CPU timer like MFC0 CP0_Count, so with icount enabled it must set can_do_io while it calls the helper to avoid the "Bad icount read" error. It should also break out of the translation loop to ensure that timer interrupts are immediatel

Re: [Qemu-devel] [PATCH for-2.10 2/3] target/mips: Drop redundant gen_io_start/stop()

2017-08-02 Thread Richard Henderson
On 08/02/2017 02:59 AM, James Hogan wrote: DMTC0 CP0_Cause does a redundant gen_io_start() and gen_io_end() pair, even though this is done for all DMTC0 operations outside of the switch statement. Remove these redundant calls. Fixes: 5dc5d9f055c5 ("mips: more fixes to the MIPS interrupt glue log

Re: [Qemu-devel] [PATCH 00/13] instrument: Add basic event instrumentation

2017-08-02 Thread Lluís Vilanova
Stefan Hajnoczi writes: > On Wed, Aug 02, 2017 at 12:10:14PM +0100, Peter Maydell wrote: >> On 2 August 2017 at 12:04, Stefan Hajnoczi wrote: >> > On Tue, Aug 01, 2017 at 02:54:29PM +0100, Peter Maydell wrote: >> >> and I don't need the TCG engine to be a library to do that... >> > >> > You do ne

Re: [Qemu-devel] [PATCH] tests/hmp: Fix typo in the 'chardev-send-break' test

2017-08-02 Thread Peter Maydell
On 27 July 2017 at 10:55, Dr. David Alan Gilbert wrote: > * Thomas Huth (th...@redhat.com) wrote: >> testchardev2 is not a valid chardev id here. Use testchardev1 >> instead which has been created with chardev-add right before >> the 'chardev-send-break' line. >> And while we're at it, add the tes

Re: [Qemu-devel] [PATCH v3 5/5] docs: update documentation considering PCIE-PCI bridge

2017-08-02 Thread Marcel Apfelbaum
On 02/08/2017 17:21, Marcel Apfelbaum wrote: On 02/08/2017 17:16, Laszlo Ersek wrote: On 08/02/17 15:47, Michael S. Tsirkin wrote: On Wed, Aug 02, 2017 at 12:23:46AM +0200, Laszlo Ersek wrote: On 08/01/17 23:39, Michael S. Tsirkin wrote: On Wed, Aug 02, 2017 at 12:33:12AM +0300, Alexander Bez

[Qemu-devel] [PATCH] docs/pcie.txt: Replace ioh3420 with pcie-root-port

2017-08-02 Thread Marcel Apfelbaum
Do not mention ioh3420 in the "how to" doc. The device still works and can be used by already existing setups, but no need to be mentioned. Suggested-by: Andrew Jones Signed-off-by: Marcel Apfelbaum --- docs/pcie.txt | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff -

Re: [Qemu-devel] [PATCH] docs/pcie.txt: Replace ioh3420 with pcie-root-port

2017-08-02 Thread Laszlo Ersek
On 08/02/17 17:51, Marcel Apfelbaum wrote: > Do not mention ioh3420 in the "how to" doc. > The device still works and can be used by already > existing setups, but no need to be mentioned. > > Suggested-by: Andrew Jones > Signed-off-by: Marcel Apfelbaum > --- > docs/pcie.txt | 16 --

Re: [Qemu-devel] [PATCH v3 5/5] docs: update documentation considering PCIE-PCI bridge

2017-08-02 Thread Michael S. Tsirkin
On Wed, Aug 02, 2017 at 06:36:29PM +0300, Marcel Apfelbaum wrote: > > > > > > Can dmi-pci support shpc? why doesn't it? For compatibility? > > > > > > > > > > I don't know why, but the fact that it doesn't is the reason libvirt > > > > > settled on auto-creating a dmi-pci bridge and a pci-pci brid

  1   2   >