Re: [Qemu-devel] [PULL 00/17] Net patches

2016-02-04 Thread Jason Wang
On 02/03/2016 05:09 PM, Samuel Thibault wrote: > Jason Wang, on Wed 03 Feb 2016 12:52:24 +0800, wrote: >>> Hi. I'm afraid this failed to build on w32: >>> >>> declaration specifiers or ‘...’ before ‘sa_family_t’ >> - switch to use unsigned short >> - or typedef sa_family_t as unsigned short for w

[Qemu-devel] [PULL V2 01/17] net/slirp: Tell the users when they are using deprecated options

2016-02-04 Thread Jason Wang
From: Thomas Huth We don't want to support the legacy -tftp, -bootp, -smb and -net channel options forever. So let's start telling the users that they are deprecated and what option should be used instead. Signed-off-by: Thomas Huth Signed-off-by: Jason Wang --- net/slirp.c | 3 +++ os-posix.

[Qemu-devel] [PULL V2 00/17] Net patches

2016-02-04 Thread Jason Wang
The following changes since commit 87574621b18f86eab295a2c207e0b42c77b5dfa0: Merge remote-tracking branch 'remotes/kraxel/tags/pull-vga-20160203-1' into staging (2016-02-03 12:23:48 +) are available in the git repository at: https://github.com/jasowang/qemu.git tags/net-pull-request fo

[Qemu-devel] [PULL V2 05/17] slirp: goto bad in udp_input if sosendto fails

2016-02-04 Thread Jason Wang
From: Guillaume Subiron Before this patch, if sosendto fails, udp_input is executed as if the packet was sent, recording the packet for icmp errors, which does not makes sense since the packet was not actually sent, errors would be related to a previous packet. This patch adds a goto bad to cut

[Qemu-devel] [PULL V2 02/17] qemu-doc: Do not promote deprecated -smb and -redir options

2016-02-04 Thread Jason Wang
From: Thomas Huth Since -smb and -redir are deprecated options, we should not use them as examples in the documentation anymore. Signed-off-by: Thomas Huth Signed-off-by: Jason Wang --- qemu-doc.texi | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/qemu-doc.texi b/

[Qemu-devel] [PULL V2 08/17] slirp: Make Socket structure IPv6 compatible

2016-02-04 Thread Jason Wang
From: Guillaume Subiron This patch replaces foreign and local address/port couples in Socket structure by 2 sockaddr_storage which can be casted in sockaddr_in. Direct access to address and port is still possible thanks to some \#define, so retrocompatibility of the existing code is assured. The

[Qemu-devel] [PULL V2 04/17] cadence_gem: fix buffer overflow

2016-02-04 Thread Jason Wang
From: "Michael S. Tsirkin" gem_transmit copies a packet from guest into an tx_packet[2048] array on stack, with size limited by descriptor length set by guest. If guest is malicious and specifies a descriptor length that is too large, and should packet size exceed array size, this results in a b

[Qemu-devel] [PULL V2 06/17] slirp: Generalizing and neutralizing ARP code

2016-02-04 Thread Jason Wang
From: Guillaume Subiron Basically, this patch replaces "arp" by "resolution" every time "arp" means "mac resolution" and not specifically ARP. This prepares for IPv6 support. Signed-off-by: Guillaume Subiron Signed-off-by: Samuel Thibault Reviewed-by: Thomas Huth Signed-off-by: Jason Wang -

[Qemu-devel] [PULL V2 03/17] net: cadence_gem: check packet size in gem_recieve

2016-02-04 Thread Jason Wang
From: Prasad J Pandit While receiving packets in 'gem_receive' routine, if Frame Check Sequence(FCS) is enabled, it copies the packet into a local buffer without checking its size. Add check to validate packet length against the buffer size to avoid buffer overflow. Reported-by: Ling Liu Signed

[Qemu-devel] [PULL V2 11/17] slirp: Add sockaddr_equal, make solookup family-agnostic

2016-02-04 Thread Jason Wang
From: Guillaume Subiron This patch makes solookup() compatible with varying address families, by using a new sockaddr_equal() function that compares two sockaddr_storage. This prepares for IPv6 support. Signed-off-by: Guillaume Subiron Signed-off-by: Samuel Thibault Reviewed-by: Thomas Huth

[Qemu-devel] [PULL V2 07/17] slirp: Adding address family switch for produced frames

2016-02-04 Thread Jason Wang
From: Guillaume Subiron In if_encap, a switch is added to prepare for the IPv6 case. Some code is factorized. This prepares for IPv6 support. Signed-off-by: Guillaume Subiron Signed-off-by: Samuel Thibault Reviewed-by: Thomas Huth --- slirp/slirp.c | 61 +

[Qemu-devel] [PULL V2 09/17] slirp: Factorizing address translation

2016-02-04 Thread Jason Wang
From: Guillaume Subiron This patch factorizes some duplicate code into a new function, sotranslate_out(). This function perform the address translation when a packet is transmitted to the host network. If the packet is destinated to the host, the loopback address is used, and if the packet is des

[Qemu-devel] [PULL V2 12/17] slirp: Make udp_attach IPv6 compatible

2016-02-04 Thread Jason Wang
From: Guillaume Subiron A unsigned short is now passed in argument to udp_attach instead of using a hardcoded "AF_INET" to call qemu_socket(). This prepares for IPv6 support. Signed-off-by: Guillaume Subiron Signed-off-by: Samuel Thibault Reviewed-by: Thomas Huth Signed-off-by: Jason Wang -

[Qemu-devel] [PULL V2 15/17] net: netmap: use nm_open() to open netmap ports

2016-02-04 Thread Jason Wang
From: Vincenzo Maffione This patch simplifies the netmap backend code by means of the nm_open() helper function provided by netmap_user.h, which hides the details of open(), iotcl() and mmap() carried out on the netmap device. Moreover, the semantic of nm_open() makes it possible to open special

[Qemu-devel] [PULL V2 10/17] slirp: Factorizing and cleaning solookup()

2016-02-04 Thread Jason Wang
From: Guillaume Subiron solookup() was only compatible with TCP. Having the socket list in argument, it is now compatible with UDP too. Some optimization code is factorized inside the function (the function look at the last returned result before browsing the complete socket list). This prepare

[Qemu-devel] [PULL V2 13/17] slirp: Adding family argument to tcp_fconnect()

2016-02-04 Thread Jason Wang
From: Guillaume Subiron This patch simply adds a unsigned short family argument to remove the hardcoded "AF_INET" in the call of qemu_socket(). This prepares for IPv6 support. Signed-off-by: Guillaume Subiron Signed-off-by: Samuel Thibault Reviewed-by: Thomas Huth Signed-off-by: Jason Wang

[Qemu-devel] [PULL V2 14/17] e1000: eliminate infinite loops on out-of-bounds transfer start

2016-02-04 Thread Jason Wang
From: Laszlo Ersek The start_xmit() and e1000_receive_iov() functions implement DMA transfers iterating over a set of descriptors that the guest's e1000 driver prepares: - the TDLEN and RDLEN registers store the total size of the descriptor area, - while the TDH and RDH registers store the of

[Qemu-devel] [PULL V2 16/17] net: always walk through filters in reverse if traffic is egress

2016-02-04 Thread Jason Wang
From: Li Zhijian Previously, if we attach more than one filters for a single netdev, both ingress and egress traffic will go through net filters in same order like: ingress: netdev ->filter1 ->filter2 ->...filter[n] ->emulated device egress: emulated device ->filter1 ->filter2 ->...filter[n] ->n

[Qemu-devel] [PULL V2 17/17] net/filter: Fix the output information for command 'info network'

2016-02-04 Thread Jason Wang
From: zhanghailiang The properties of netfilter object could be changed by 'qom-set' command, but the output of 'info network' command is not updated, because it got the old information through nf->info_str, it will not be updated while we change the value of netfilter's property. Here we split

Re: [Qemu-devel] [PATCH] rng-random: implement request queue

2016-02-04 Thread Pankaj Gupta
Hi Ladi, I think this is fine if we have multiple requests from Guests and depending on entropy pool available we can honour individual requests and return with the entropy. Just one point I have is, Suppose we have multiple requests from Guests and we are returning if request length < 0 for

Re: [Qemu-devel] [PATCH V3 1/2] net/filter-mirror:Add filter-mirror

2016-02-04 Thread Zhang Chen
On 02/04/2016 03:43 PM, Zhang Chen wrote: From: ZhangChen Filter-mirror is a netfilter plugin. It gives qemu the ability to copy and mirror guest's net packet. we output packet to chardev. usage: -netdev tap,id=hn0 -chardev socket,id=mirror0,host=ip_primary,port=X,server,nowait -filter-mirr

Re: [Qemu-devel] [PATCH v13 00/10] Block replication for continuous checkpoints

2016-02-04 Thread Dr. David Alan Gilbert
* Changlong Xie (xiecl.f...@cn.fujitsu.com) wrote: > On 02/01/2016 09:18 AM, Wen Congyang wrote: > >On 01/29/2016 06:47 PM, Dr. David Alan Gilbert wrote: > >>* Wen Congyang (we...@cn.fujitsu.com) wrote: > >>>On 01/29/2016 06:07 PM, Dr. David Alan Gilbert wrote: > * Wen Congyang (we...@cn.fujits

Re: [Qemu-devel] [PATCH v13 00/10] Block replication for continuous checkpoints

2016-02-04 Thread Wen Congyang
On 02/04/2016 05:07 PM, Dr. David Alan Gilbert wrote: > * Changlong Xie (xiecl.f...@cn.fujitsu.com) wrote: >> On 02/01/2016 09:18 AM, Wen Congyang wrote: >>> On 01/29/2016 06:47 PM, Dr. David Alan Gilbert wrote: * Wen Congyang (we...@cn.fujitsu.com) wrote: > On 01/29/2016 06:07 PM, Dr. Dav

Re: [Qemu-devel] [PATCH] hw/arm/virt: fix max-cpus check

2016-02-04 Thread Andrew Jones
On Thu, Feb 04, 2016 at 09:54:45AM +0800, Shannon Zhao wrote: > > > On 2016/2/3 22:59, Andrew Jones wrote: > > mach-virt doesn't yet support hotplug, but command lines specifying > > -smp ,maxcpus= don't fail. Of course specifying > > bigger-num as something bigger than the machine supports, e.g.

[Qemu-devel] [PATCH] migration: fix bad string passed to error_report()

2016-02-04 Thread Greg Kurz
state->name does not contain a terminating '\0' and you may get: Machine type received is 'pseries-2.3y�?' and local is 'pseries-2.4' load of migration failed: Invalid argument Let's add a precision modifier to fix this. Signed-off-by: Greg Kurz --- migration/savevm.c |4 ++-- 1 file chang

Re: [Qemu-devel] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores

2016-02-04 Thread Igor Mammedov
On Wed, 3 Feb 2016 15:38:09 -0200 Eduardo Habkost wrote: > On Mon, Feb 01, 2016 at 10:41:58AM +0100, Igor Mammedov wrote: > [...] > > > > > > How exactly would you migrate a machine today, if you do the > > > following? > > > > > > $ qemu-system-x86_64 -smp 8,sockets=2,cores=2,threads=2,maxcp

Re: [Qemu-devel] [PATCH] migration: fix bad string passed to error_report()

2016-02-04 Thread Amit Shah
On (Thu) 04 Feb 2016 [10:20:07], Greg Kurz wrote: > state->name does not contain a terminating '\0' and you may get: > > Machine type received is 'pseries-2.3y�?' and local is 'pseries-2.4' > load of migration failed: Invalid argument > > Let's add a precision modifier to fix this. > > Signed-of

Re: [Qemu-devel] [PATCH v5 0/7] mips/kvm: Support FPU & SIMD (MSA) in MIPS KVM guests

2016-02-04 Thread Leon Alrae
On 03/02/16 17:16, James Hogan wrote: > Here's a v5 refresh of my FPU/MSA patchset for v2.6. Thanks to all who > have taken the time to review it so far. > > This patchset primarily adds support for FPU and MIPS SIMD Architecture > (MSA) in MIPS KVM guests to QEMU. It depends on Linux v4.1, specif

Re: [Qemu-devel] [PATCH] migration: remove useless code.

2016-02-04 Thread Amit Shah
On (Wed) 27 Jan 2016 [14:11:05], Liang Li wrote: > Since 's->state' will be set in migrate_init(), there is no > need to set it before calling migrate_init(). The code and > the related comments can be removed. > > Signed-off-by: Liang Li > --- > migration/migration.c | 6 -- > 1 file change

Re: [Qemu-devel] [PATCH 0/6] Some improvements and small fixes for migration

2016-02-04 Thread Amit Shah
On (Sat) 30 Jan 2016 [18:32:22], Hailiang Zhang wrote: > Hi Juan & Amit, > > This series is prerequisite of COLO, and all of them have been reviewed by > Dave, > Could you please review and merge them ? Yea, I've been away last couple of weeks. Getting to this now. Amit

Re: [Qemu-devel] [PATCH v13 00/10] Block replication for continuous checkpoints

2016-02-04 Thread Changlong Xie
On 02/04/2016 05:07 PM, Dr. David Alan Gilbert wrote: * Changlong Xie (xiecl.f...@cn.fujitsu.com) wrote: On 02/01/2016 09:18 AM, Wen Congyang wrote: On 01/29/2016 06:47 PM, Dr. David Alan Gilbert wrote: * Wen Congyang (we...@cn.fujitsu.com) wrote: On 01/29/2016 06:07 PM, Dr. David Alan Gilber

Re: [Qemu-devel] [PATCH] migration: fix bad string passed to error_report()

2016-02-04 Thread Greg Kurz
On Thu, 4 Feb 2016 15:30:11 +0530 Amit Shah wrote: > On (Thu) 04 Feb 2016 [10:20:07], Greg Kurz wrote: > > state->name does not contain a terminating '\0' and you may get: > > > > Machine type received is 'pseries-2.3y�?' and local is 'pseries-2.4' > > load of migration failed: Invalid argument

[Qemu-devel] [PATCH] quorum: fix segfault when read fails in fifo mode

2016-02-04 Thread Changlong Xie
Signed-off-by: Wen Congyang Signed-off-by: Changlong Xie --- block/quorum.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/block/quorum.c b/block/quorum.c index a5ae4b8..0965277 100644 --- a/block/quorum.c +++ b/block/quorum.c @@ -295,6 +295,9 @@ static void quorum_aio_cb(void *opaque, i

Re: [Qemu-devel] [PATCH 07/10] virtio: combine the read of a descriptor

2016-02-04 Thread Paolo Bonzini
On 04/02/2016 08:48, Gonglei (Arei) wrote: > 11.44% qemu-kvm [.] memory_region_find > 6.31% qemu-kvm [.] qemu_get_ram_ptr > 4.61% libpthread-2.19.so [.] __pthread_mutex_unlock_usercnt > 3.54% qemu-kvm [.] qemu_ram_addr_from_host >

Re: [Qemu-devel] [PATCH v2 00/10] virtio/vring: optimization patches

2016-02-04 Thread Paolo Bonzini
On 03/02/2016 13:08, Gonglei (Arei) wrote: > 22.56% qemu-kvm [.] address_space_translate > 13.29% qemu-kvm [.] qemu_get_ram_ptr We could get rid of qemu_get_ram_ptr by storing the RAMBlock pointer into the memory region, instead of the ram_addr_t value. I'm ha

Re: [Qemu-devel] [PATCH 3/3] balloon: don't use NVDIMM for ballooning

2016-02-04 Thread Vladimir Sementsov-Ogievskiy
On 04.02.2016 09:20, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: On 03.02.2016 18:42, Markus Armbruster wrote: Eric Blake writes: On 01/27/2016 11:51 PM, Vladimir Sementsov-Ogievskiy wrote: NVDIMM for now is planned to use as a backing store for DAX filesystem in the gue

Re: [Qemu-devel] sda abort with virtio-scsi

2016-02-04 Thread Paolo Bonzini
On 04/02/2016 00:34, Jim Minter wrote: > I was worried there was > some way in which the contention could cause an abort and perhaps thence > the lockup (which does not seem to recover when the host load goes down). I don't know... It's not the most tested code, but it is not very complicated ei

Re: [Qemu-devel] [PATCH] nbd: avoid unaligned uint64_t store

2016-02-04 Thread Paolo Bonzini
On 04/02/2016 00:48, John Snow wrote: > cpu_to_be64w can't be used to make unaligned stores, but stq_be_p can. > The other stores in this routine are left alone, they're aligned already. > > Signed-off-by: John Snow > --- > nbd/server.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >

Re: [Qemu-devel] [PATCH 5/6] qmp-commands.hx: Fix the missing options for migration parameters commands

2016-02-04 Thread Amit Shah
On (Fri) 15 Jan 2016 [11:37:45], zhanghailiang wrote: > We didn't document x-cpu-throttle-initial/x-cpu-throttle-increment for > commands migrate-set-parameters and query-migrate-parameters. > > Here we add the descriptions for these two options and fix the wrong example > for query-migrate-parame

Re: [Qemu-devel] [PATCH 2/6] migration: Rename the'file' member of MigrationState

2016-02-04 Thread Amit Shah
On (Fri) 15 Jan 2016 [11:37:42], zhanghailiang wrote: > Rename the 'file' member of MigrationState to 'to_dst_file'. Why? (Use this space to explain why you're doing it, rather than repeating the first line of the commit. It helps when reviewing the git logs later.) Thanks, Ami

Re: [Qemu-devel] [PATCH 2/6] migration: Rename the'file' member of MigrationState

2016-02-04 Thread Dr. David Alan Gilbert
* Amit Shah (amit.s...@redhat.com) wrote: > On (Fri) 15 Jan 2016 [11:37:42], zhanghailiang wrote: > > Rename the 'file' member of MigrationState to 'to_dst_file'. > > Why? > > (Use this space to explain why you're doing it, rather than repeating > the first line of the commit. It helps when revi

Re: [Qemu-devel] [PATCH 2/6] migration: Rename the'file' member of MigrationState

2016-02-04 Thread Amit Shah
On (Thu) 04 Feb 2016 [10:50:16], Dr. David Alan Gilbert wrote: > * Amit Shah (amit.s...@redhat.com) wrote: > > On (Fri) 15 Jan 2016 [11:37:42], zhanghailiang wrote: > > > Rename the 'file' member of MigrationState to 'to_dst_file'. > > > > Why? > > > > (Use this space to explain why you're doing

Re: [Qemu-devel] sda abort with virtio-scsi

2016-02-04 Thread Denis V. Lunev
On 02/04/2016 01:23 PM, Paolo Bonzini wrote: On 04/02/2016 00:34, Jim Minter wrote: I was worried there was some way in which the contention could cause an abort and perhaps thence the lockup (which does not seem to recover when the host load goes down). I don't know... It's not the most teste

[Qemu-devel] [PATCH] migration: move page_cache.c to migration/

2016-02-04 Thread Paolo Bonzini
page_cache.c is part of the XBZRLE implementation, move it to the right directory. Signed-off-by: Paolo Bonzini --- Makefile.objs | 1 - migration/Makefile.objs| 2 +- page_cache.c => migration/page_cache.c | 0 3 files changed, 1 insertion(+), 2 deletion

Re: [Qemu-devel] [PULL 00/13] Tracing patches

2016-02-04 Thread Peter Maydell
On 3 February 2016 at 18:49, Paolo Bonzini wrote: > > > On 03/02/2016 18:55, Peter Maydell wrote: >> On 3 February 2016 at 15:47, Stefan Hajnoczi wrote: >> I think this is a quirk of this elderly mingw setup that's come up >> before, but I forget what the resolution of it was. >> (I now have a mo

Re: [Qemu-devel] [PATCH 0/6] Some improvements and small fixes for migration

2016-02-04 Thread Amit Shah
On (Fri) 15 Jan 2016 [11:37:40], zhanghailiang wrote: > Patch 1 ~ patch 4 are picked from COLO and live memory snapshot series, > They are just small improvements for migration codes and have been reviewed > by Dave. > > Patch 5, 6 are small fixes for migration releated documention. > > Please r

Re: [Qemu-devel] [PATCH 2/6] migration: Rename the'file' member of MigrationState

2016-02-04 Thread Dr. David Alan Gilbert
* Amit Shah (amit.s...@redhat.com) wrote: > On (Thu) 04 Feb 2016 [10:50:16], Dr. David Alan Gilbert wrote: > > * Amit Shah (amit.s...@redhat.com) wrote: > > > On (Fri) 15 Jan 2016 [11:37:42], zhanghailiang wrote: > > > > Rename the 'file' member of MigrationState to 'to_dst_file'. > > > > > > Why?

Re: [Qemu-devel] [PATCH v16 00/14] vfio-pci: pass the aer error to guest

2016-02-04 Thread Michael S. Tsirkin
On Thu, Feb 04, 2016 at 10:04:01AM +0800, Chen Fan wrote: > > On 02/03/2016 09:57 PM, Michael S. Tsirkin wrote: > >On Wed, Feb 03, 2016 at 04:54:01PM +0800, Chen Fan wrote: > >>On 01/17/2016 02:34 AM, Michael S. Tsirkin wrote: > >>>On Tue, Jan 12, 2016 at 10:43:01AM +0800, Cao jin wrote: > Fro

Re: [Qemu-devel] [RFC PATCH 3/4] tests: Add mingw 32/64 cross compiling

2016-02-04 Thread Paolo Bonzini
On 04/02/2016 03:29, Fam Zheng wrote: >> > I suggest to add a trace backend as well (my tests run with >> > --enable-trace-backend=stderr, so maybe you want to choose >> > a different one). > Will do. > Note that the stderr (now renamed to "log") is now the default. Paolo

[Qemu-devel] [PULL] Update OpenBIOS images

2016-02-04 Thread Mark Cave-Ayland
Hi Peter, This pull request updates the OpenBIOS images to latest SVN trunk, most notably with fixes for Mac machines following more testing on OS X/OS 9. Please pull. ATB, Mark. The following changes since commit 87574621b18f86eab295a2c207e0b42c77b5dfa0: Merge remote-tracking branch 'rem

Re: [Qemu-devel] sda abort with virtio-scsi

2016-02-04 Thread Paolo Bonzini
On 04/02/2016 07:59, Hannes Reinecke wrote: > On 02/04/2016 12:19 AM, Paolo Bonzini wrote: >> >> >> On 03/02/2016 22:46, Jim Minter wrote: >>> I am hitting the following VM lockup issue running a VM with latest >>> RHEL7 kernel on a host also running latest RHEL7 kernel. FWIW I'm using >>> virti

Re: [Qemu-devel] [RFC PATCH 0/4] tests: Introducing docker tests

2016-02-04 Thread Paolo Bonzini
On 04/02/2016 03:43, Fam Zheng wrote: > Non-Linux environments can be sorted out in this framework by pulling > appropriate 3rd party images from docker hub, assuming there isn't too much > copyright hassle for Mac OSX and Windows stuff. This is theoretically possible > because with "--privileged

Re: [Qemu-devel] [PATCH 2/4] vfio: make the 4 bytes aligned for capability size

2016-02-04 Thread Michael S. Tsirkin
On Thu, Feb 04, 2016 at 09:31:06AM +0800, Cao jin wrote: > From: Chen Fan > > this function search the capability from the end, the last > size should 0x100 - pos, not 0xff - pos. > > Signed-off-by: Chen Fan > Reviewed-by: Marcel Apfelbaum Reviewed-by: Michael S. Tsirkin > --- > hw/vfio/pc

Re: [Qemu-devel] [PATCH 0/4] vfio-pci: pass the aer error to guest, part1

2016-02-04 Thread Michael S. Tsirkin
On Thu, Feb 04, 2016 at 09:31:04AM +0800, Cao jin wrote: > From: Chen Fan > > this patchset are splited out from my aer series patches, > this part of aer patches is harmless, and have been reviewed-by. > In order to avoid blocking it to merge, so I send it out independently > as part1. the part2

Re: [Qemu-devel] qdev & hw/core owner? (was Re: [PATCH v19 7/9] machine: add properties to compat_props incrementaly)

2016-02-04 Thread Paolo Bonzini
On 03/02/2016 20:06, Michael S. Tsirkin wrote: > On Wed, Feb 03, 2016 at 03:55:04PM -0200, Eduardo Habkost wrote: >> On Thu, Jan 28, 2016 at 06:00:31PM +0100, Igor Mammedov wrote: >> [...] >>> It looks like this series might go nowhere but this patch >>> is not tied to it and useful to us in gene

[Qemu-devel] [PATCH v5 0/5] don't use NVDIMM for balooning

2016-02-04 Thread Vladimir Sementsov-Ogievskiy
v5: do not use qapi 0002-0004: new patches 0005: white list instead of black list v4: 0001: Reviewed-by: Eric Blake second patch is splitted to 0002 and 0003 0002: Add 'type' field instead of 'balloonable' to PCDIMMDeviceInfo 0003: chec 'type' instead of 'balloonable' v3: - do not use

[Qemu-devel] [PATCH 2/5] pc-dimm: rename pc_dimm_built_list()

2016-02-04 Thread Vladimir Sementsov-Ogievskiy
s/pc_dimm_built_list/pc_dimm_build_list_sorted - need for add pc_dimm_build_list (not sorted) in the next patch - fix typo (built -> build) Signed-off-by: Vladimir Sementsov-Ogievskiy CC: Stefan Hajnoczi CC: Xiao Guangrong CC: "Michael S. Tsirkin" CC: Igor Mammedov CC: Eric Blake CC: Marku

[Qemu-devel] [PATCH 3/5] pc-dimm: add pc_dimm_build_list()

2016-02-04 Thread Vladimir Sementsov-Ogievskiy
Like pc_dimm_build_list_sorted but not sorted - for cases where sorting is not necessary. Signed-off-by: Vladimir Sementsov-Ogievskiy CC: Stefan Hajnoczi CC: Xiao Guangrong CC: "Michael S. Tsirkin" CC: Igor Mammedov CC: Eric Blake CC: Markus Armbruster --- hw/mem/pc-dimm.c | 15 ++

[Qemu-devel] [PATCH 1/5] move get_current_ram_size to virtio-balloon.c

2016-02-04 Thread Vladimir Sementsov-Ogievskiy
get_current_ram_size() is used only in virtio-balloon.c This patch moves it into virtio-balloon and make it static, to allow some balloon-specific tuning. Signed-off-by: Vladimir Sementsov-Ogievskiy Signed-off-by: Denis V. Lunev Reviewed-by: Eric Blake CC: Stefan Hajnoczi CC: Xiao Guangrong

[Qemu-devel] [PATCH 4/5] virtio-balloon: rewrite get_current_ram_size()

2016-02-04 Thread Vladimir Sementsov-Ogievskiy
Use pc_dimm_built_list() instead of qmp_pc_dimm_device_list() Actually, Qapi is not related to this internal helper. Signed-off-by: Vladimir Sementsov-Ogievskiy CC: Stefan Hajnoczi CC: Xiao Guangrong CC: "Michael S. Tsirkin" CC: Igor Mammedov CC: Eric Blake CC: Markus Armbruster --- hw/v

[Qemu-devel] [PATCH 5/5] balloon: Use only 'pc-dimm' type dimm for ballooning

2016-02-04 Thread Vladimir Sementsov-Ogievskiy
For now there are only two dimm's: pc-dimm and nvdimm. This patch is actually needed to disable ballooning on nvdimm. But, to avoid future bugs, instead of disallowing nvdimm, we allow only pc-dimm. So, if someone adds new dimm which should be balloon-able, then this ability should be explicitly sp

Re: [Qemu-devel] qdev & hw/core owner? (was Re: [PATCH v19 7/9] machine: add properties to compat_props incrementaly)

2016-02-04 Thread Andreas Färber
Am 04.02.2016 um 12:31 schrieb Paolo Bonzini: > On 03/02/2016 20:06, Michael S. Tsirkin wrote: >> On Wed, Feb 03, 2016 at 03:55:04PM -0200, Eduardo Habkost wrote: >>> On Thu, Jan 28, 2016 at 06:00:31PM +0100, Igor Mammedov wrote: >>> [...] It looks like this series might go nowhere but this pa

[Qemu-devel] [PATCH 3/9] pc: acpi: cleanup qdev_get_machine() calls

2016-02-04 Thread Igor Mammedov
call qdev_get_machine() once at acpi_build() and pass its result to child functions that need it. Signed-off-by: Igor Mammedov --- Later it will also allow to reduce number of arguments passed around by build_foo() functions called from acpi_build() once guest_info fields are moved into PCMachine

[Qemu-devel] [PATCH 7/9] pc: acpi: drop not needed intermediate bitmap cpu->found_cpus

2016-02-04 Thread Igor Mammedov
cpu->found_cpus bitmap is used for setting present flag in CPON AML package at start up. But it takes a bunch of code to fill bitmap and cloud be simplified by calling qemu_get_cpu_by_arch_id(apic_id) directly. Hence do so and remove not used anymore bitmap with related utilities, which saves us ~

[Qemu-devel] [PATCH 0/9] pc: do not create invalid MADT.LAPIC/Processor entries

2016-02-04 Thread Igor Mammedov
It's mostly clean up series that removes invalid CPU entries from MADT/DSDT/SRAT tables when APIC IDs are sparse distributed*. Series also removes intermediate present CPUs bitmap in ACPI tables generation code, replacing it with machine reported presence status or if not possible* with directly qu

[Qemu-devel] [PATCH 4/9] pc: acpi: SRAT: create only valid processor lapic entries

2016-02-04 Thread Igor Mammedov
When APIC IDs are sparse*, in addition to valid LAPIC antries the SRAT is also filled invalid ones for non posiible APIC IDs. Fix it by asking machine for all possible APIC IDs instead of wrongly assuming that all APIC IDs in range 0..apic_id_limit are possible. * sparse lapic topology CLI: -

[Qemu-devel] [PATCH 9/9] pc: acpi: clarify why possible LAPIC entries must be present in MADT

2016-02-04 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- hw/i386/acpi-build.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c index d6cd06a..2cc3fff 100644 --- a/hw/i386/acpi-build.c +++ b/hw/i386/acpi-build.c @@ -361,6 +361,12 @@ build_madt(GArray *table_data, GArra

[Qemu-devel] [PATCH 8/9] pc: move apic_id_limit to PCMachineState

2016-02-04 Thread Igor Mammedov
yet another cleanup that replaces multiple apic_id_limit variables that were initialized at differnt places with a one initialization at pc_cpus_init() time and letting other code to just read it. That also allows to reduce number of a function arguments where it takes MachineState as an argument.

[Qemu-devel] [PATCH 5/9] pc: acpi: create Processor and Notify objects only for valid lapics

2016-02-04 Thread Igor Mammedov
do not assume that all lapics in range 0..apic_id_limit are valid and do not create Processor and Notify objects for not possible lapics. Signed-off-by: Igor Mammedov --- hw/i386/acpi-build.c | 33 +++-- 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/

[Qemu-devel] [PATCH 2/9] machine: introduce MachineClass.possible_cpu_arch_ids() hook

2016-02-04 Thread Igor Mammedov
on x86 currently range 0..max_cpus is used to generate architecture-dependent CPU ID (APIC Id) for each present and possible CPUs. However architecture-dependent CPU IDs list could be sparse and code that needs to enumerate all IDs (ACPI) ended up doing guess work enumerating all possible and impos

[Qemu-devel] [PATCH 6/9] pc: acpi: create MADT.lapic entries only for valid lapics

2016-02-04 Thread Igor Mammedov
do not assume that all lapics in range 0..apic_id_limit are valid and do not create lapic entries for not possible lapics in MADT. Signed-off-by: Igor Mammedov --- hw/i386/acpi-build.c | 21 ++--- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/hw/i386/acpi-build.c

[Qemu-devel] [PATCH 1/9] cpu: rename cpu_exists() to qemu_get_cpu_by_arch_id()

2016-02-04 Thread Igor Mammedov
cpu_exists() already does CPU lookup but discards found CPU and returns boolean instead. Make it more useful by returning a found CPU and also rename it more descriptive name. Signed-off-by: Igor Mammedov --- hw/i386/pc.c | 2 +- include/qom/cpu.h | 10 +- qom/cpu.c | 6 ++

Re: [Qemu-devel] qdev & hw/core owner? (was Re: [PATCH v19 7/9] machine: add properties to compat_props incrementaly)

2016-02-04 Thread Paolo Bonzini
On 04/02/2016 12:41, Andreas Färber wrote: > You're talking about machine, right? Some time ago I had proposed Marcel > who initially worked on it, but I'm fine with anyone taking it. Yes. > For some (but not all) core qdev parts related to the (stalled) QOM > migration I've been taking care of

Re: [Qemu-devel] [PATCH v5 0/5] don't use NVDIMM for balooning

2016-02-04 Thread Igor Mammedov
On Thu, 4 Feb 2016 14:37:18 +0300 Vladimir Sementsov-Ogievskiy wrote: CCing Luiz as he might be interested in balloon stuff. > v5: do not use qapi > 0002-0004: new patches > 0005: white list instead of black list > > v4: > 0001: Reviewed-by: Eric Blake > second patch is splitted to 0002 a

Re: [Qemu-devel] [RFC PATCH 1/4] tests: Introduce Docker based tests

2016-02-04 Thread Daniel P. Berrange
On Wed, Feb 03, 2016 at 10:36:01PM +0800, Fam Zheng wrote: > diff --git a/tests/docker/fedora22.docker b/tests/docker/fedora22.docker > new file mode 100644 > index 000..5fd48d6 > --- /dev/null > +++ b/tests/docker/fedora22.docker Fedora 22 will go end of life in June. I think we should at le

Re: [Qemu-devel] [PATCH 06/12] 4byte address mode support added.

2016-02-04 Thread Krzeminski, Marcin (Nokia - PL/Wroclaw)
> -Original Message- > From: EXT Peter Crosthwaite [mailto:crosthwaitepe...@gmail.com] > Sent: Tuesday, December 22, 2015 10:29 PM > To: Cédric Le Goater; g...@xilinx.com > Cc: Krzeminski, Marcin (Nokia - PL/Wroclaw); qemu-devel@nongnu.org > Developers; Lenkow, Pawel (Nokia - PL/Wroclaw)

Re: [Qemu-devel] [PATCH 2/2] qapi: Allow blockdev-add for NBD

2016-02-04 Thread Paolo Bonzini
On 03/02/2016 17:48, Eric Blake wrote: > On 02/03/2016 09:33 AM, Max Reitz wrote: >> We have to introduce a new object (BlockdevOptionsNbd) for >> several reasons: - Neither of InetSocketAddress nor >> UnixSocketAddress alone is sufficient, because both are >> supported - We cannot use SocketAddr

Re: [Qemu-devel] [RFC PATCH 3/4] tests: Add mingw 32/64 cross compiling

2016-02-04 Thread Daniel P. Berrange
On Wed, Feb 03, 2016 at 10:36:03PM +0800, Fam Zheng wrote: > Only fedora22 has the required toolchain so it's not run elsewhere. > > Signed-off-by: Fam Zheng > --- > tests/docker/mingw.sh | 14 ++ > 1 file changed, 14 insertions(+) > create mode 100755 tests/docker/mingw.sh > > dif

Re: [Qemu-devel] [PATCH 0/6] Some improvements and small fixes for migration

2016-02-04 Thread Hailiang Zhang
On 2016/2/4 19:08, Amit Shah wrote: On (Fri) 15 Jan 2016 [11:37:40], zhanghailiang wrote: Patch 1 ~ patch 4 are picked from COLO and live memory snapshot series, They are just small improvements for migration codes and have been reviewed by Dave. Patch 5, 6 are small fixes for migration releate

Re: [Qemu-devel] [PATCH 2/2] qapi: Allow blockdev-add for NBD

2016-02-04 Thread Paolo Bonzini
On 03/02/2016 18:16, Max Reitz wrote: > However, the issue remains that the NBD block driver expects > flattened options which is syntactically incompatible to > SocketAddress. Maybe the best way to address this would be to just > make block/nbd.c directly accept a SocketAddress and keep the old

Re: [Qemu-devel] [PATCH 2/6] migration: Rename the'file' member of MigrationState

2016-02-04 Thread Hailiang Zhang
On 2016/2/4 19:10, Dr. David Alan Gilbert wrote: * Amit Shah (amit.s...@redhat.com) wrote: On (Thu) 04 Feb 2016 [10:50:16], Dr. David Alan Gilbert wrote: * Amit Shah (amit.s...@redhat.com) wrote: On (Fri) 15 Jan 2016 [11:37:42], zhanghailiang wrote: Rename the 'file' member of MigrationState

Re: [Qemu-devel] qdev & hw/core owner? (was Re: [PATCH v19 7/9] machine: add properties to compat_props incrementaly)

2016-02-04 Thread Michael S. Tsirkin
On Thu, Feb 04, 2016 at 12:41:39PM +0100, Andreas Färber wrote: > Am 04.02.2016 um 12:31 schrieb Paolo Bonzini: > > On 03/02/2016 20:06, Michael S. Tsirkin wrote: > >> On Wed, Feb 03, 2016 at 03:55:04PM -0200, Eduardo Habkost wrote: > >>> On Thu, Jan 28, 2016 at 06:00:31PM +0100, Igor Mammedov wrot

Re: [Qemu-devel] qdev & hw/core owner? (was Re: [PATCH v19 7/9] machine: add properties to compat_props incrementaly)

2016-02-04 Thread Michael S. Tsirkin
On Thu, Feb 04, 2016 at 12:55:22PM +0100, Paolo Bonzini wrote: > > > On 04/02/2016 12:41, Andreas Färber wrote: > > You're talking about machine, right? Some time ago I had proposed Marcel > > who initially worked on it, but I'm fine with anyone taking it. > > Yes. > > > For some (but not all)

Re: [Qemu-devel] qdev & hw/core owner? (was Re: [PATCH v19 7/9] machine: add properties to compat_props incrementaly)

2016-02-04 Thread Marcel Apfelbaum
On 02/04/2016 01:41 PM, Andreas Färber wrote: Am 04.02.2016 um 12:31 schrieb Paolo Bonzini: On 03/02/2016 20:06, Michael S. Tsirkin wrote: On Wed, Feb 03, 2016 at 03:55:04PM -0200, Eduardo Habkost wrote: On Thu, Jan 28, 2016 at 06:00:31PM +0100, Igor Mammedov wrote: [...] It looks like this s

Re: [Qemu-devel] [PATCH] kvm-all: trace: strerror fixup

2016-02-04 Thread Paolo Bonzini
On 01/02/2016 20:37, Andrew Jones wrote: > Signed-off-by: Andrew Jones > --- > kvm-all.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/kvm-all.c b/kvm-all.c > index 9148889921197..330f509a0da84 100644 > --- a/kvm-all.c > +++ b/kvm-all.c > @@ -2362,7 +2362,7 @@ in

Re: [Qemu-devel] [PATCH 2/9] machine: introduce MachineClass.possible_cpu_arch_ids() hook

2016-02-04 Thread Marcel Apfelbaum
On 02/04/2016 01:47 PM, Igor Mammedov wrote: on x86 currently range 0..max_cpus is used to generate architecture-dependent CPU ID (APIC Id) for each present and possible CPUs. However architecture-dependent CPU IDs list could be sparse and code that needs to enumerate all IDs (ACPI) ended up doin

[Qemu-devel] [PATCH v2 5/6] qmp-commands.hx: Fix the missing options for migration parameters commands

2016-02-04 Thread zhanghailiang
We didn't document x-cpu-throttle-initial/x-cpu-throttle-increment for commands migrate-set-parameters and query-migrate-parameters. Here we add the descriptions for these two options and fix the wrong example for query-migrate-parameters qmp commands. Besides, this will also fix the bug that we c

[Qemu-devel] [PATCH v2 6/6] qmp-commands.hx: Document the missing options for migration capability commands

2016-02-04 Thread zhanghailiang
Add the missing descriptions for the options of migration capability commands, and fix the example for query-migrate-capabilities command. Signed-off-by: zhanghailiang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Amit Shah --- qmp-commands.hx | 15 ++- 1 file changed, 14 insert

[Qemu-devel] [PATCH v2 4/6] migration/ram: Fix some helper functions' parameter to use PageSearchStatus

2016-02-04 Thread zhanghailiang
Some helper functions use parameters 'RAMBlock *block' and 'ram_addr_t *offset', We can use 'PageSearchStatus *pss' directly instead, with this change, we can reduce the number of parameters for these helper function, also it is easily to add new parameters for these helper functions. Signed-off-b

[Qemu-devel] [PATCH v2 2/6] migration: Rename the'file' member of MigrationState

2016-02-04 Thread zhanghailiang
Rename the 'file' memory of MigrationState to 'to_dst_file' to be consistent with to_src_file, from_src_file and from_dst_file. Signed-off-by: zhanghailiang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Amit Shah --- include/migration/migration.h | 2 +- migration/exec.c | 4

[Qemu-devel] [PATCH v2 1/6] ram: Split host_from_stream_offset() into two helper functions

2016-02-04 Thread zhanghailiang
Split host_from_stream_offset() into two parts: One is to get ram block, which the block idstr may be get from migration stream, the other is to get hva (host) address from block and the offset. Besides, we will do the check working in a new helper offset_in_ramblock(). Signed-off-by: zhanghailian

[Qemu-devel] [PATCH v2 0/6] Some improvments and small fixes for migration

2016-02-04 Thread zhanghailiang
Patch 1 ~ patch 4 are picked from COLO and live memory snapshot series, They are just small improvements for migration codes. Patch 5, 6 are small fixes for migration releated documention. v2: - Fix a typo (Amit) - A better commit description from Dave for patch 2 zhanghailiang (6): ram: Sp

[Qemu-devel] [PATCH v2 01/11] block: m25p80: Removed unused variable

2016-02-04 Thread marcin . krzeminski
From: Marcin Krzeminski Signed-off-by: Marcin Krzeminski Reviewed-by: Peter Crosthwaite --- hw/block/m25p80.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c index de24f42..124 100644 --- a/hw/block/m25p80.c +++ b/hw/block/m25p80.c @@ -246,8 +246,

Re: [Qemu-devel] [PATCH 3/9] pc: acpi: cleanup qdev_get_machine() calls

2016-02-04 Thread Marcel Apfelbaum
On 02/04/2016 01:47 PM, Igor Mammedov wrote: call qdev_get_machine() once at acpi_build() and pass its result to child functions that need it. Signed-off-by: Igor Mammedov --- Later it will also allow to reduce number of arguments passed around by build_foo() functions called from acpi_build()

[Qemu-devel] [PATCH v2 03/11] block: m25p80: Widen flags variable

2016-02-04 Thread marcin . krzeminski
From: Marcin Krzeminski Extend the width of the flags variable to support the already existing (but unused) WR_1 flag, which is above the range of 8 bits. This allows support of EEPROM emulation which requires the WR_1 feature. Signed-off-by: Marcin Krzeminski Reviewed-by: Peter Crosthwaite --

[Qemu-devel] [PATCH v2 00/11] Support for N25Q256/512 and AT25128/256

2016-02-04 Thread marcin . krzeminski
From: Marcin Krzeminski V2: - Removed support for mx66u51235 and s25fl512s from this series - Corrected/implemented dummy cycles - rebased to master Model was tested on u-boot and kernel using custom qemu machine. Marcin Krzeminski (11): block: m25p80: Removed unused variable block: m25p80:

[Qemu-devel] [PATCH v2 06/11] block: m25p80: Add configuration registers

2016-02-04 Thread marcin . krzeminski
From: Marcin Krzeminski This patch adds both volatile and non volatile configuration registers and commands to allow modify them. It is needed for proper handling dummy cycles. Power-on initialization of those registers and flash state has been included as well. Some of this registers are used by

[Qemu-devel] [PATCH v2 04/11] block: m25p80: Extend address mode

2016-02-04 Thread marcin . krzeminski
From: Marcin Krzeminski Extend address mode allows to switch flash 16 MiB banks, allowing user to access all flash sectors. This access mode is used by u-boot. Signed-off-by: Marcin Krzeminski Reviewed-by: Peter Crosthwaite --- hw/block/m25p80.c | 27 +++ 1 file change

[Qemu-devel] [PATCH v2 3/6] savevm: Split load vm state function qemu_loadvm_state

2016-02-04 Thread zhanghailiang
qemu_loadvm_state is too long, and we can simplify it by splitting up with three helper functions. Signed-off-by: zhanghailiang Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Amit Shah --- migration/savevm.c | 156 +++-- 1 file changed, 92 inse

[Qemu-devel] [PATCH v2 05/11] block: m25p80: 4byte address mode

2016-02-04 Thread marcin . krzeminski
From: Marcin Krzeminski This patch adds only 4byte address mode (does not cover dummy cycles). This mode is needed to access more than 16 MiB of flash. Signed-off-by: Marcin Krzeminski --- hw/block/m25p80.c | 40 +++- 1 file changed, 35 insertions(+), 5 dele

  1   2   3   4   >