Re: [Qemu-devel] [PATCH v4 1/8] bootindex: add modify_boot_device_path function

2014-08-04 Thread Gonglei (Arei)
Hi, > > > On Thu, Jul 31, 2014 at 05:47:26PM +0800, arei.gong...@huawei.com wrote: > > [...] > > > +void modify_boot_device_path(int32_t bootindex, DeviceState *dev, > > > + const char *suffix) > > > +{ > > > +FWBootEntry *i, *old_entry = NULL; > > > + > > > +a

Re: [Qemu-devel] [v2][PATCH 2/5] hw:pci-host:piix: split i440fx_init

2014-08-04 Thread Chen, Tiejun
On 2014/7/31 17:53, Michael S. Tsirkin wrote: On Thu, Jul 31, 2014 at 05:26:41PM +0800, Chen, Tiejun wrote: On 2014/7/31 17:10, Michael S. Tsirkin wrote: On Thu, Jul 31, 2014 at 02:31:36PM +0800, Tiejun Chen wrote: We'd like to split i440fx_init and then we can share something with other stuff

[Qemu-devel] [PATCH] configure: replace \n with space in optarg

2014-08-04 Thread Hu Tao
When optarg happens to contain \n like: ../configure --target-list='i386-softmmu x86_64-softmmu' make will fail with message: config-host.mak:45: *** missing separator. Stop. This patch fix this problem by replacing \n with space in optarg. Signed-off-by: Hu Tao --- configure | 4 ++-- 1 f

Re: [Qemu-devel] [v2 1/3] query-memdev: fix potential memory leaks

2014-08-04 Thread Hu Tao
On Mon, Aug 04, 2014 at 12:21:17PM +0800, Chen Fan wrote: > Signed-off-by: Chen Fan > Reviewed-by: Peter Crosthwaite Reviewed-by: Hu Tao > --- > numa.c | 6 +- > 1 file changed, 5 insertions(+), 1 deletion(-) > > diff --git a/numa.c b/numa.c > index 7bf7834..a2b4bca 100644 > --- a/numa.c

Re: [Qemu-devel] [v2 2/3] qom/object.c: fix string_output_get_string() memory leak

2014-08-04 Thread Hu Tao
On Mon, Aug 04, 2014 at 12:21:18PM +0800, Chen Fan wrote: > string_output_get_string() uses g_string_free(str, false) to > transfer the 'str' pointer to callers and never free it. > > Signed-off-by: Chen Fan Reviewed-by: Hu Tao > --- > hmp.c| 6 -- > qom/object.c | 12 ++-

Re: [Qemu-devel] [v2 3/3] hmp: fix MemdevList memory leak

2014-08-04 Thread Hu Tao
On Mon, Aug 04, 2014 at 12:21:19PM +0800, Chen Fan wrote: > the memdev_list in hmp_info_memdev() is never freed. > so we use existent method qapi_free_MemdevList() to free it. > and also we can use qapi_free_MemdevList() to replace list loops > to clean up the memdev list in error path. > > Signed

Re: [Qemu-devel] [PATCH v4 1/8] bootindex: add modify_boot_device_path function

2014-08-04 Thread Markus Armbruster
"Gonglei (Arei)" writes: > Hi, > >> >> > On Thu, Jul 31, 2014 at 05:47:26PM +0800, arei.gong...@huawei.com wrote: >> > [...] >> > > +void modify_boot_device_path(int32_t bootindex, DeviceState *dev, >> > > + const char *suffix) >> > > +{ >> > > +FWBootEntry *i, *o

[Qemu-devel] Cc'ing emails [was: [PATCH] dump.c: Fix memory leak issue in cleanup processing for dump_init()]

2014-08-04 Thread Michael Tokarev
Please stop Cc'ing me emails sent to, at least, qemu-trivial@. I'm about to filter personal emails which are also sent to some mailinglists I receive. I'd not do that, because this is a good practice to Cc someone like that for various really important or urgent emails, and if I to apply such a f

Re: [Qemu-devel] [PATCH v4 1/8] bootindex: add modify_boot_device_path function

2014-08-04 Thread Gonglei (Arei)
Hi, > >> > >> > On Thu, Jul 31, 2014 at 05:47:26PM +0800, arei.gong...@huawei.com > wrote: > >> > [...] > >> > > +void modify_boot_device_path(int32_t bootindex, DeviceState *dev, > >> > > + const char *suffix) > >> > > +{ > >> > > +FWBootEntry *i, *old_entry = NULL

[Qemu-devel] [PATCH 2/3] pc-dimm: check if the value of node property

2014-08-04 Thread Hu Tao
If user specifies a node number that exceeds the available numa nodes in emulated system for pc-dimm device, the device will reports an invalid _PXM to OSPM. Fix it by checking the node value. Signed-off-by: Hu Tao --- hw/mem/pc-dimm.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/

[Qemu-devel] [PATCH 1/3] hw:i386: typo fix: MEMORY_HOPTLUG_DEVICE -> MEMORY_HOTPLUG_DEVICE

2014-08-04 Thread Hu Tao
Signed-off-by: Hu Tao --- hw/i386/acpi-dsdt.dsl | 4 ++-- hw/i386/acpi-dsdt.hex.generated | 8 hw/i386/q35-acpi-dsdt.dsl | 4 ++-- hw/i386/ssdt-mem.dsl| 16 hw/i386/ssdt-misc.dsl | 2 +- include/hw/acpi/pc-hotplug.h| 2 +- 6

[Qemu-devel] [PATCH 3/3] numa: show hex number in error message for consistency and prefix them with 0x

2014-08-04 Thread Hu Tao
The error messages before and after patch are: before: qemu-system-x86_64: total memory for NUMA nodes (134217728) should equal RAM size (2000) after: qemu-system-x86_64: total memory for NUMA nodes (0x800) should equal RAM size (0x2000) Signed-off-by: Hu Tao --- numa.c | 4 ++--

[Qemu-devel] [PATCH 0/3] some numa & memory related fixes

2014-08-04 Thread Hu Tao
See each patch for the detail. Hu Tao (3): hw:i386: typo fix: MEMORY_HOPTLUG_DEVICE -> MEMORY_HOTPLUG_DEVICE pc-dimm: check if node property exceeds available numa nodes numa: show hex number in error message for consistency and prefix them with 0x hw/i386/acpi-dsdt.dsl | 4

Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command

2014-08-04 Thread Markus Armbruster
"Gonglei (Arei)" writes: > Hi, > >> Subject: Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command >> >> On Fri, Jul 25, 2014 at 02:52:50PM +0800, arei.gong...@huawei.com wrote: >> > From: Gonglei >> > >> > Adds "set-bootindex id=xx,bootindex=xx,suffix=xx" QMP command. >> > >> > Exampl

Re: [Qemu-devel] [PATCH 3/4] libqos: add a simple first-fit memory allocator

2014-08-04 Thread Markus Armbruster
Stefan Hajnoczi writes: > On Thu, Jul 31, 2014 at 05:14:12PM -0400, John Snow wrote: >> >> On 07/31/2014 06:13 AM, Stefan Hajnoczi wrote: >> >On Wed, Jul 30, 2014 at 06:28:28PM -0400, John Snow wrote: >> >>-static uint64_t pc_alloc(QGuestAllocator *allocator, size_t size) >> >>+static inline voi

[Qemu-devel] [PATCH 3/4] virtio-blk: fix reference a pointer which might be freed

2014-08-04 Thread zhanghailiang
In function virtio_blk_handle_request, it may freed memory pointed by req, So do not access member of req after calling this function. Signed-off-by: zhanghailiang --- hw/block/virtio-blk.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hw/block/virtio-blk.c b/hw/block/

[Qemu-devel] [PATCH 2/4] monitor: fix access freed memory

2014-08-04 Thread zhanghailiang
The function monitor_fdset_dup_fd_find_remove() references member of 'mon_fdset' which may be freed in function monitor_fdset_cleanup() Signed-off-by: zhanghailiang --- monitor.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/monitor.c b/monitor.c index 5bc70a6..41e46a6 1

[Qemu-devel] [PATCH 1/4] l2cap: fix access freed memory

2014-08-04 Thread zhanghailiang
Pointer 'ch' will be used in function 'l2cap_channel_open_req_msg' after it was previously freed in 'l2cap_channel_open'. Assigned it to NULL after it is freed. Signed-off-by: zhanghailiang --- hw/bt/l2cap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/bt/l2cap.c b/hw/b

[Qemu-devel] [PATCH 4/4] ivshmem: check the value returned by fstat()

2014-08-04 Thread zhanghailiang
The function fstat() may fail, so check its return value. Signed-off-by: zhanghailiang --- hw/misc/ivshmem.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hw/misc/ivshmem.c b/hw/misc/ivshmem.c index 768e528..2667e9f 100644 --- a/hw/misc/ivshmem.c +++ b/hw/misc/ivshmem.c

[Qemu-devel] [PATCH 0/4] fix several bugs about use-after-free and an api abuse

2014-08-04 Thread zhanghailiang
zhanghailiang (4): l2cap: fix access freed memory monitor: fix access freed memory virtio-blk: fix reference a pointer which might be freed ivshmem: check the value returned by fstat() hw/block/virtio-blk.c | 5 +++-- hw/bt/l2cap.c | 2 +- hw/misc/ivshmem.c | 5 - monitor.

Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command

2014-08-04 Thread Gonglei (Arei)
Hi, > >> Subject: Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command > >> > >> On Fri, Jul 25, 2014 at 02:52:50PM +0800, arei.gong...@huawei.com wrote: > >> > From: Gonglei > >> > > >> > Adds "set-bootindex id=xx,bootindex=xx,suffix=xx" QMP command. > >> > > >> > Example QMP command:

[Qemu-devel] Question of emulation on MSR's in KVM-mode

2014-08-04 Thread Morty Andersen
Hi I'm working on an extension to QEMU (target i386). This involves adding new MSR's. I've got it working in non-KVM mode by adding these MSR's to the state and adding extra cases to helper_wrmsr(), helper_rdmsr(). The guest can now read/write these MSR's as expected. However, it fails when runnin

Re: [Qemu-devel] fpu/softfloat.c licensing

2014-08-04 Thread Peter Maydell
On 4 August 2014 05:55, Alexey Kardashevskiy wrote: > Our lawyers refused to provide any public advise on this :-/ > > Is that it, end of story? :) Well, I 'd still like to get the license fixed to at least my personal satisfaction, but if your lawyers won't confirm whether what we propose will w

Re: [Qemu-devel] [PATCH v4] aarch64: Allow -kernel option to take a gzip-compressed kernel.

2014-08-04 Thread Richard W.M. Jones
On Mon, Aug 04, 2014 at 09:05:39AM +1000, Peter Crosthwaite wrote: > On Sun, Aug 3, 2014 at 1:45 AM, Richard W.M. Jones wrote: > > +max_bytes = UBOOT_MAX_GUNZIP_BYTES; > > Why does u-boot's maximum size limit apply here? We need some maximum to prevent people uploading a kernel (perhaps from

Re: [Qemu-devel] [PATCH 1/4] l2cap: fix access freed memory

2014-08-04 Thread Alex Bennée
zhanghailiang writes: > Pointer 'ch' will be used in function 'l2cap_channel_open_req_msg' after > it was previously freed in 'l2cap_channel_open'. > Assigned it to NULL after it is freed. > > Signed-off-by: zhanghailiang > --- > hw/bt/l2cap.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletio

Re: [Qemu-devel] [PATCH] configure: replace \n with space in optarg

2014-08-04 Thread Peter Maydell
On 4 August 2014 08:12, Hu Tao wrote: > When optarg happens to contain \n like: > > ../configure --target-list='i386-softmmu > x86_64-softmmu' > > make will fail with message: > > config-host.mak:45: *** missing separator. Stop. Why would you put newlines in the option string? This is likely to

Re: [Qemu-devel] [PATCH v4] aarch64: Allow -kernel option to take a gzip-compressed kernel.

2014-08-04 Thread Peter Maydell
On 4 August 2014 09:48, Richard W.M. Jones wrote: > On Mon, Aug 04, 2014 at 09:05:39AM +1000, Peter Crosthwaite wrote: >> On Sun, Aug 3, 2014 at 1:45 AM, Richard W.M. Jones wrote: >> > +max_bytes = UBOOT_MAX_GUNZIP_BYTES; >> >> Why does u-boot's maximum size limit apply here? > > We need some

Re: [Qemu-devel] [PATCH 2/4] monitor: fix access freed memory

2014-08-04 Thread Alex Bennée
zhanghailiang writes: > The function monitor_fdset_dup_fd_find_remove() references member of > 'mon_fdset' > which may be freed in function monitor_fdset_cleanup() > > Signed-off-by: zhanghailiang > --- > monitor.c | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/mon

Re: [Qemu-devel] [PATCH v4] aarch64: Allow -kernel option to take a gzip-compressed kernel.

2014-08-04 Thread Peter Crosthwaite
On Mon, Aug 4, 2014 at 6:48 PM, Richard W.M. Jones wrote: > On Mon, Aug 04, 2014 at 09:05:39AM +1000, Peter Crosthwaite wrote: >> On Sun, Aug 3, 2014 at 1:45 AM, Richard W.M. Jones wrote: >> > +max_bytes = UBOOT_MAX_GUNZIP_BYTES; >> >> Why does u-boot's maximum size limit apply here? > > We n

Re: [Qemu-devel] [v2 2/3] qom/object.c: fix string_output_get_string() memory leak

2014-08-04 Thread Peter Crosthwaite
On Mon, Aug 4, 2014 at 2:21 PM, Chen Fan wrote: > string_output_get_string() uses g_string_free(str, false) to > transfer the 'str' pointer to callers and never free it. > > Signed-off-by: Chen Fan Reviewed-by: Peter Crosthwaite > --- > hmp.c| 6 -- > qom/object.c | 12 ++

Re: [Qemu-devel] [PATCH v2 1/7] block: Add status callback to bdrv_amend_options()

2014-08-04 Thread Benoît Canet
The Saturday 02 Aug 2014 à 01:49:15 (+0200), Max Reitz wrote : > Depending on the changed options and the image format, > bdrv_amend_options() may take a significant amount of time. In these > cases, a way to be informed about the operation's status is desirable. > > Since the operation is rather

[Qemu-devel] [PATCH v4 6/8] spice: don't use 'Yoda conditions'

2014-08-04 Thread arei.gonglei
From: Gonglei imitate nearby code about using '!value' or 'value == NULL' Signed-off-by: Gonglei --- ui/spice-core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/spice-core.c b/ui/spice-core.c index 7bb91e6..1a2fb4b 100644 --- a/ui/spice-core.c +++ b/ui/spice-core

[Qemu-devel] [PATCH v4 7/8] vl: don't use 'Yoda conditions'

2014-08-04 Thread arei.gonglei
From: Gonglei imitate nearby code about using '!value' or 'value == NULL' Signed-off-by: Gonglei --- vl.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/vl.c b/vl.c index fe451aa..04c5abd 100644 --- a/vl.c +++ b/vl.c @@ -1136,7 +1136,7 @@ static int drive_init_func(Qe

[Qemu-devel] [PATCH v4 5/8] don't use 'Yoda conditions'

2014-08-04 Thread arei.gonglei
From: Gonglei imitate nearby code about using '!value' or 'value == NULL' Signed-off-by: Gonglei --- qdev-monitor.c | 2 +- qemu-char.c | 2 +- util/qemu-sockets.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/qdev-monitor.c b/qdev-monitor.c index f87f3d8.

[Qemu-devel] [PATCH v4 3/8] audio: don't use 'Yoda conditions'

2014-08-04 Thread arei.gonglei
From: Gonglei imitate nearby code about using '!value' or 'value == NULL' Signed-off-by: Gonglei --- hw/audio/gus.c | 2 +- hw/audio/hda-codec.c | 3 ++- hw/audio/sb16.c | 6 +++--- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/hw/audio/gus.c b/hw/audio/gus.c index

[Qemu-devel] [PATCH v4 8/8] vmxnet3: don't use 'Yoda conditions'

2014-08-04 Thread arei.gonglei
From: Gonglei imitate nearby code about using '!value' or 'value == NULL' Signed-off-by: Gonglei --- hw/net/vmxnet3.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/hw/net/vmxnet3.c b/hw/net/vmxnet3.c index 77bea6f..588149d 100644 --- a/hw/net/vmxnet3.c ++

[Qemu-devel] [PATCH v4 1/8] CODING_STYLE: Section about conditional statement

2014-08-04 Thread arei.gonglei
From: Gonglei Yoda conditions lack readability, and QEMU has a strict compiler configuration for checking a common mistake like "if (dev = NULL)". Make it a written rule. Signed-off-by: Gonglei Reviewed-by: Eric Blake --- CODING_STYLE | 14 ++ 1 file changed, 14 insertions(+) dif

[Qemu-devel] [PATCH v4 0/8] don't use Yoda conditions

2014-08-04 Thread arei.gonglei
From: Gonglei $WHATEVER: don't use 'Yoda conditions' 'Yoda conditions' are not part of idiomatic QEMU coding style, so rewrite them in the more usual order. v4: - trivial typo for patch 1/8 suggested by Eric, thanks. v3: - rewrite CODINT_STYLE file suggested by Eric, thanks. - rename the pa

[Qemu-devel] [PATCH v4 4/8] isa-bus: don't use 'Yoda conditions'

2014-08-04 Thread arei.gonglei
From: Gonglei imitate nearby code about using '!value' or 'value == NULL' Signed-off-by: Gonglei --- hw/isa/isa-bus.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/isa/isa-bus.c b/hw/isa/isa-bus.c index b28981b..cc85e53 100644 --- a/hw/isa/isa-bus.c +++ b/hw/isa/isa-bu

[Qemu-devel] [PATCH v4 2/8] usb: don't use 'Yoda conditions'

2014-08-04 Thread arei.gonglei
From: Gonglei imitate nearby code about using '!value' or 'value == NULL' Signed-off-by: Gonglei --- hw/usb/dev-audio.c | 2 +- hw/usb/dev-mtp.c | 4 ++-- hw/usb/hcd-ehci.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/hw/usb/dev-audio.c b/hw/usb/dev-audio.c index b

Re: [Qemu-devel] [PATCH v2 2/7] qemu-img: Add progress output for amend

2014-08-04 Thread Benoît Canet
The Saturday 02 Aug 2014 à 01:49:16 (+0200), Max Reitz wrote : > Now that bdrv_amend_options() supports a status callback, use it to > display a progress report. > > Signed-off-by: Max Reitz > --- > qemu-img-cmds.hx | 4 ++-- > qemu-img.c | 25 ++--- > qemu-img.texi

[Qemu-devel] [PULL] virtio-rng: fix memleak, use error_setg

2014-08-04 Thread Amit Shah
Hi, This patchset fixes a memleak in virtio-rng init and moves from error_set to error_setg. Please pull. The following changes since commit c79805802ba0463713c253307d99ebef56436b8c: Open 2.2 development tree (2014-08-01 18:30:08 +0100) are available in the git repository at: git://git.ke

Re: [Qemu-devel] [PATCH V4 2/5] runner: Tool for fuzz tests execution

2014-08-04 Thread M.Kustova
On Fri, Aug 1, 2014 at 9:46 AM, Stefan Hajnoczi wrote: > On Mon, Jul 21, 2014 at 02:18:09PM +0400, Maria Kustova wrote: >> +def execute(self, input_commands=None, fuzz_config=None): >> +""" Execute a test. >> + >> +The method creates backing and test images, runs test app and

Re: [Qemu-devel] [PATCH v2 4/7] block/qcow2: Implement status CB for amend

2014-08-04 Thread Benoît Canet
The Saturday 02 Aug 2014 à 01:49:18 (+0200), Max Reitz wrote : > The only really time-consuming operation potentially performed by > qcow2_amend_options() is zero cluster expansion when downgrading qcow2 > images from compat=1.1 to compat=0.10, so report status of that > operation and that operatio

Re: [Qemu-devel] [PATCH] configure: replace \n with space in optarg

2014-08-04 Thread Hu Tao
On Mon, Aug 04, 2014 at 09:50:20AM +0100, Peter Maydell wrote: > On 4 August 2014 08:12, Hu Tao wrote: > > When optarg happens to contain \n like: > > > > ../configure --target-list='i386-softmmu > > x86_64-softmmu' > > > > make will fail with message: > > > > config-host.mak:45: *** missing sepa

Re: [Qemu-devel] [PATCH v2 5/7] block/qcow2: Make get_refcount() global

2014-08-04 Thread Benoît Canet
The Saturday 02 Aug 2014 à 01:49:19 (+0200), Max Reitz wrote : > Reading the refcount of a cluster is an operation which can be useful in > all of the qcow2 code, so make that function globally available. > > While touching this function, amend the comment describing the "addend" > parameter: It i

Re: [Qemu-devel] [PATCH v2 6/7] block/qcow2: Simplify shared L2 handling in amend

2014-08-04 Thread Benoît Canet
The Saturday 02 Aug 2014 à 01:49:20 (+0200), Max Reitz wrote : > Currently, we have a bitmap for keeping track of which clusters have > been created during the zero cluster expansion process. This was > necessary because we need to properly increase the refcount for shared > L2 tables. > > However

[Qemu-devel] [PULL] migration: static checker: handle 'unused' fields, whitelist update

2014-08-04 Thread Amit Shah
Hello, This patchset updates the vmstate static checker to handle fields that got marked 'unused' in qemu versions. Also update the whitelist based on a few false-positives. The following changes since commit 35858955e6c6f9ef41c199d15457c13426ac6434: Merge remote-tracking branch 'remotes/afae

Re: [Qemu-devel] [PULL] migration: static checker: handle 'unused' fields, whitelist update

2014-08-04 Thread Amit Shah
On (Mon) 04 Aug 2014 [15:06:05], Amit Shah wrote: > Hello, > > This patchset updates the vmstate static checker to handle fields that > got marked 'unused' in qemu versions. Also update the whitelist based > on a few false-positives. > > The following changes since commit 35858955e6c6f9ef41c199d

Re: [Qemu-devel] [ANNOUNCE] QEMU 2.1.0 is now available

2014-08-04 Thread Kevin Wolf
Am 02.08.2014 um 00:33 hat Peter Maydell geschrieben: > On 1 August 2014 17:41, Michael Roth wrote: > > On behalf of the QEMU Team, I'd like to announce the availability of > > the QEMU 2.1.0 release. This release contains 2200+ commits from 180 > > authors. > > > Thank you to everyone involved!

Re: [Qemu-devel] [PATCH 26/28] ahci: Add test_hba_spec to ahci-test.

2014-08-04 Thread Stefan Hajnoczi
On Fri, Aug 01, 2014 at 07:27:57PM -0400, John Snow wrote: > > On 07/31/2014 10:01 AM, Stefan Hajnoczi wrote: > >On Mon, Jul 07, 2014 at 02:18:07PM -0400, John Snow wrote: > >>+/*** IO macros for the AHCI memory registers. ***/ > >>+#define void_incr(vptr, OFST) ((void *)((char *)(vptr) + (OFST)))

Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command

2014-08-04 Thread Markus Armbruster
"Gonglei (Arei)" writes: > Hi, > >> >> Subject: Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command >> >> >> >> On Fri, Jul 25, 2014 at 02:52:50PM +0800, arei.gong...@huawei.com wrote: >> >> > From: Gonglei >> >> > >> >> > Adds "set-bootindex id=xx,bootindex=xx,suffix=xx" QMP command.

Re: [Qemu-devel] [PATCH 00/14] dataplane: optimization and multi virtqueue support

2014-08-04 Thread Stefan Hajnoczi
On Wed, Jul 30, 2014 at 07:39:33PM +0800, Ming Lei wrote: > These patches bring up below 4 changes: > > - introduce selective coroutine bypass mechanism > for improving performance of virtio-blk dataplane with > raw format image > > - introduce object allocation po

Re: [Qemu-devel] [PATCH 07/15] dataplane: use object pool to speed up allocation for virtio blk request

2014-08-04 Thread Stefan Hajnoczi
On Fri, Aug 01, 2014 at 03:42:05PM +0800, Ming Lei wrote: > On Thu, Jul 31, 2014 at 5:18 PM, Paolo Bonzini wrote: > > Il 31/07/2014 05:22, Ming Lei ha scritto: > >>> > > >>> > The problem is that g_slice here is not using the slab-style allocator > >>> > because the object is larger than roughly 5

Re: [Qemu-devel] [PATCH 10/15] linux-aio: increase max event to 256

2014-08-04 Thread Stefan Hajnoczi
On Thu, Jul 31, 2014 at 01:20:22AM +0800, Ming Lei wrote: > On Wed, Jul 30, 2014 at 10:00 PM, Paolo Bonzini wrote: > > Il 30/07/2014 13:39, Ming Lei ha scritto: > >> This patch increases max event to 256 for the comming > >> virtio-blk multi virtqueue support. > >> > >> Signed-off-by: Ming Lei >

Re: [Qemu-devel] [PATCH RFC 0/3] dataplane: dataplane: more graceful error handling

2014-08-04 Thread Cornelia Huck
On Fri, 25 Jul 2014 14:10:45 +0200 Cornelia Huck wrote: > Currently, qemu will take a hard exit if it fails to set up guest or > host notifiers, giving no real clue as to what went wrong (e.g., when > out of file descriptors). > > This patchset tries to make this more manageable: Both by improvi

Re: [Qemu-devel] [PATCH v2 0/5] AArch64 TLB performance improvements

2014-08-04 Thread Alex Bennée
Peter Maydell writes: > On 1 August 2014 17:06, Peter Maydell wrote: >> I'm taking the first two of these into target-arm.next because >> they're obvious standalone bugfixes. I need to think about the >> last three a bit more: I dislike just dropping the ARMv5 CPUs >> from qemu-system-aarch64, i

Re: [Qemu-devel] [PATCH v2 0/5] AArch64 TLB performance improvements

2014-08-04 Thread Alex Bennée
Paolo Bonzini writes: > Il 30/07/2014 17:20, Alex Bennée ha scritto: >> Hi, >> >> The most important thing is I've measured a 25-30% improvement in >> kernel and android boot time. >> > Hi Alex, have you seen this patch? Perhaps you're interested in > reviving it. > > http://article.gmane.or

Re: [Qemu-devel] fpu/softfloat.c licensing

2014-08-04 Thread Alexey Kardashevskiy
On 08/04/2014 06:48 PM, Peter Maydell wrote: > On 4 August 2014 05:55, Alexey Kardashevskiy wrote: >> Our lawyers refused to provide any public advise on this :-/ >> >> Is that it, end of story? :) > > Well, I 'd still like to get the license fixed to at least my > personal satisfaction, but if y

Re: [Qemu-devel] [PATCH 00/14] dataplane: optimization and multi virtqueue support

2014-08-04 Thread Ming Lei
On Mon, Aug 4, 2014 at 6:16 PM, Stefan Hajnoczi wrote: > On Wed, Jul 30, 2014 at 07:39:33PM +0800, Ming Lei wrote: >> These patches bring up below 4 changes: >> >> - introduce selective coroutine bypass mechanism >> for improving performance of virtio-blk dataplane with >>

Re: [Qemu-devel] [PATCH v2 0/5] AArch64 TLB performance improvements

2014-08-04 Thread Peter Maydell
On 4 August 2014 11:23, Alex Bennée wrote: > Peter Maydell writes: >> So: >> * there's clearly a big perf win to be had here >> * this patchset gives us that for 4K pages on AArch64 >> * but it doesn't help for 4K pages on AArch32 (really >> common) > > Well for the AArch32 profile if you r

[Qemu-devel] [PATCH v2 1/1] virtio-rng: add some trace events

2014-08-04 Thread Amit Shah
Add some trace events to virtio-rng for easier debugging Signed-off-by: Amit Shah --- v2: - requested_size trace event now shows proper values --- hw/virtio/virtio-rng.c | 6 ++ trace-events | 5 + 2 files changed, 11 insertions(+) diff --git a/hw/virtio/virtio-rng.c b/hw/vi

Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command

2014-08-04 Thread Gonglei (Arei)
Hi, Markus > >> >> Subject: Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex > command > >> >> > >> >> On Fri, Jul 25, 2014 at 02:52:50PM +0800, arei.gong...@huawei.com > wrote: > >> >> > From: Gonglei > >> >> > > >> >> > Adds "set-bootindex id=xx,bootindex=xx,suffix=xx" QMP command. > >> >

Re: [Qemu-devel] [PATCH 7/7] vmxnet3: a trivial code change for more idiomatic writing style

2014-08-04 Thread Stefan Hajnoczi
On Thu, Jul 31, 2014 at 08:29:00PM +0800, arei.gong...@huawei.com wrote: > From: Gonglei > > Signed-off-by: Gonglei > --- > hw/net/vmxnet3.c | 16 > 1 file changed, 8 insertions(+), 8 deletions(-) Reviewed-by: Stefan Hajnoczi pgpK5f516P9nj.pgp Description: PGP signature

Re: [Qemu-devel] fpu/softfloat.c licensing

2014-08-04 Thread Markus Armbruster
Alexey Kardashevskiy writes: > On 08/04/2014 06:48 PM, Peter Maydell wrote: >> On 4 August 2014 05:55, Alexey Kardashevskiy wrote: >>> Our lawyers refused to provide any public advise on this :-/ >>> >>> Is that it, end of story? :) >> >> Well, I 'd still like to get the license fixed to at lea

Re: [Qemu-devel] [PATCH 3/4] virtio-blk: fix reference a pointer which might be freed

2014-08-04 Thread Stefan Hajnoczi
On Mon, Aug 04, 2014 at 04:25:43PM +0800, zhanghailiang wrote: > In function virtio_blk_handle_request, it may freed memory pointed by req, > So do not access member of req after calling this function. > > Signed-off-by: zhanghailiang > --- > hw/block/virtio-blk.c | 5 +++-- > 1 file changed, 3

Re: [Qemu-devel] fpu/softfloat.c licensing

2014-08-04 Thread Peter Maydell
On 4 August 2014 12:12, Markus Armbruster wrote: > I'm afraid we need rip out the problematic patches. Here's Paolo's > list: > > Fabrice Bellard > 1d6bda356153c82e100680d9f2165e32c8fb1330 > 750afe93fd15fafc20b6c34d30f339547d15c2d1 > > Jocelyn Mayer > 75d62a585629cdc1ae0d

Re: [Qemu-devel] [PATCH 1/2] virtio-serial: create a linked list of all active devices

2014-08-04 Thread Markus Armbruster
Amit Shah writes: > To ensure two virtserialports don't get added to the system with the > same 'name' parameter, we need to access all the ports on all the > devices added, and compare the names. > > We currently don't have a list of all VirtIOSerial devices added to the > system. This commit a

Re: [Qemu-devel] [PATCH v2 0/5] AArch64 TLB performance improvements

2014-08-04 Thread Alex Bennée
Alex Bennée writes: > Paolo Bonzini writes: > >> Il 30/07/2014 17:20, Alex Bennée ha scritto: >>> Hi, >>> > >>> The most important thing is I've measured a 25-30% improvement in >>> kernel and android boot time. >>> > >> Hi Alex, have you seen this patch? Perhaps you're interested in >> revi

Re: [Qemu-devel] [PATCH 07/15] dataplane: use object pool to speed up allocation for virtio blk request

2014-08-04 Thread Ming Lei
On Mon, Aug 4, 2014 at 6:21 PM, Stefan Hajnoczi wrote: > On Fri, Aug 01, 2014 at 03:42:05PM +0800, Ming Lei wrote: >> On Thu, Jul 31, 2014 at 5:18 PM, Paolo Bonzini wrote: >> > Il 31/07/2014 05:22, Ming Lei ha scritto: >> >>> > >> >>> > The problem is that g_slice here is not using the slab-style

Re: [Qemu-devel] [PATCH 1/2] virtio-serial: create a linked list of all active devices

2014-08-04 Thread Amit Shah
On (Mon) 04 Aug 2014 [13:33:56], Markus Armbruster wrote: > Amit Shah writes: > > > To ensure two virtserialports don't get added to the system with the > > same 'name' parameter, we need to access all the ports on all the > > devices added, and compare the names. > > > > We currently don't have

Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command

2014-08-04 Thread Markus Armbruster
"Gonglei (Arei)" writes: > Hi, Markus > >> >> >> Subject: Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex >> command >> >> >> >> >> >> On Fri, Jul 25, 2014 at 02:52:50PM +0800, arei.gong...@huawei.com >> wrote: >> >> >> > From: Gonglei >> >> >> > >> >> >> > Adds "set-bootindex id=xx,booti

[Qemu-devel] [PATCH v5 1/2] loader: Add load_image_gzipped function.

2014-08-04 Thread Richard W.M. Jones
As the name suggests this lets you load a ROM/disk image that is gzipped. It is uncompressed before storing it in guest memory. Signed-off-by: Richard W.M. Jones --- hw/core/loader.c| 48 include/hw/loader.h | 1 + 2 files changed, 49 insert

[Qemu-devel] [PATCH v5 2/2] aarch64: Allow -kernel option to take a gzip-compressed kernel.

2014-08-04 Thread Richard W.M. Jones
On aarch64 it is the bootloader's job to uncompress the kernel. UEFI and u-boot bootloaders do this automatically when the kernel is gzip-compressed. However the qemu -kernel option does not do this. The following command does not work: qemu-system-aarch64 [...] -kernel /boot/vmlinuz because

[Qemu-devel] [PATCH v5 0/2] aarch64: Allow -kernel option to take a gzip-compressed kernel.

2014-08-04 Thread Richard W.M. Jones
Changes since v4: - Split the patch into a generic loader part, and specific arm64 support. - There is now a specific limit for the gzip loader, plus a comment to indicate that it's just there to stop an excessive malloc. The limit is now decoupled (and larger) than the u-boot limit,

Re: [Qemu-devel] [PULL 0/3] Xen tree 2014-08-01

2014-08-04 Thread Peter Maydell
On 1 August 2014 17:00, Stefano Stabellini wrote: > The following changes since commit 541bbb07eb197a870661ed702ae1f15c7d46aea6: > > Update version for v2.1.0 release (2014-08-01 13:31:29 +0100) > > are available in the git repository at: > > git://xenbits.xen.org/people/sstabellini/qemu-dm.gi

[Qemu-devel] [PATCH] vhost_net: cleanup start/stop condition

2014-08-04 Thread Michael S. Tsirkin
Checking vhost device internal state in vhost_net looks like a layering violation since vhost_net does not set this flag: it is set and tested by vhost.c. There seems to be no reason to check this: caller in virtio net uses its own flag, vhost_started, to ensure vhost is started/stopped as appropri

[Qemu-devel] [PATCH] vhost_net: stop guest notifiers after backend

2014-08-04 Thread Michael S. Tsirkin
commit a9f98bb5ebe6fb1869321dcc58e72041ae626ad8 vhost: multiqueue support changed the order of stopping the device. Previously vhost_dev_stop would disable backend and only afterwards, unset guest notifiers. We now unset guest notifiers while vhost is still active. This can lose interrupts cau

Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex command

2014-08-04 Thread Gonglei (Arei)
Hi, Markus > > > >> >> >> Subject: Re: [Qemu-devel] [PATCH v2 5/7] qmp: add set-bootindex > >> command > >> >> >> > >> >> >> On Fri, Jul 25, 2014 at 02:52:50PM +0800, arei.gong...@huawei.com > >> wrote: > >> >> >> > From: Gonglei > >> >> >> > > >> >> >> > Adds "set-bootindex id=xx,bootindex=xx,suf

Re: [Qemu-devel] Question of emulation on MSR's in KVM-mode

2014-08-04 Thread Paolo Bonzini
Il 04/08/2014 10:37, Morty Andersen ha scritto: > Hi > > I'm working on an extension to QEMU (target i386). This involves adding > new MSR's. I've got it working in non-KVM mode by adding these MSR's to > the state and adding extra cases to helper_wrmsr(), helper_rdmsr(). The > guest can now read/

Re: [Qemu-devel] [PATCH 0/3] some numa & memory related fixes

2014-08-04 Thread Michael S. Tsirkin
On Mon, Aug 04, 2014 at 04:16:06PM +0800, Hu Tao wrote: > See each patch for the detail. > > Hu Tao (3): > hw:i386: typo fix: MEMORY_HOPTLUG_DEVICE -> MEMORY_HOTPLUG_DEVICE > pc-dimm: check if node property exceeds available numa nodes > numa: show hex number in error message for consistency

Re: [Qemu-devel] [PATCH 2/3] pc-dimm: check if the value of node property

2014-08-04 Thread Michael S. Tsirkin
On Mon, Aug 04, 2014 at 04:16:08PM +0800, Hu Tao wrote: > If user specifies a node number that exceeds the available numa nodes in > emulated system for pc-dimm device, the device will reports an invalid _PXM > to OSPM. Fix it by checking the node value. > > Signed-off-by: Hu Tao > --- > hw/mem/

Re: [Qemu-devel] [PATCH target-arm] arm: armv7m: Respect elf entry point

2014-08-04 Thread Peter Maydell
On 2 August 2014 00:41, Peter Crosthwaite wrote: > ARMv7M has it's own bootloader (separate from the regular ARM > bootloader) that is elf aware. It is able to load elfs but it does > not set the program counter to the elf entry point. Make it more > consistent with the regular ARM bootloader by s

Re: [Qemu-devel] [PATCH v2 01/10] target-arm/cpu.h: document various program state functions

2014-08-04 Thread Peter Maydell
On 10 July 2014 16:49, Alex Bennée wrote: > We have a number of program state saving functions (pstate, cpsr, xpsr) > which are dependant on the mode the CPU is in. This commit adds a little > documentation to each function and asserts to defend against incorrect > use. > > Signed-off-by: Alex Ben

Re: [Qemu-devel] [PATCH 4/4] ivshmem: check the value returned by fstat()

2014-08-04 Thread Michael S. Tsirkin
On Mon, Aug 04, 2014 at 04:25:44PM +0800, zhanghailiang wrote: > The function fstat() may fail, so check its return value. > > Signed-off-by: zhanghailiang > --- > hw/misc/ivshmem.c | 5 - > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/hw/misc/ivshmem.c b/hw/misc/ivshmem.

Re: [Qemu-devel] vfio in the guest: no available reset mechanism

2014-08-04 Thread Michael S. Tsirkin
On Sat, Aug 02, 2014 at 07:54:30AM +0200, Jan Kiszka wrote: > On 2014-08-01 19:16, Alex Williamson wrote: > >> Also, it may let some of our device > >> models deviate from their real versions (I suppose, e.g., none of the > >> e1000 devices we currently emulate exposed FLR). > > > > Of course, bu

Re: [Qemu-devel] [PATCH v2 02/10] target-arm/cpu.h: common pstate save/restore

2014-08-04 Thread Peter Maydell
On 10 July 2014 16:49, Alex Bennée wrote: > This adds a universal program state save and restore function. This is > intended to simplify the migration serialisation functionality and avoid > special casing depending on the mode of the CPU at serialisation time. > > Signed-off-by: Alex Bennée > >

[Qemu-devel] [PATCH v5 1/8] bootindex: add modify_boot_device_path function

2014-08-04 Thread arei.gonglei
From: Gonglei When we want to change one device's bootindex, we should lookup the device and change the bootindex. it is simply that remove it from the global boot list, then re-add it, sorted by new bootindex. If the new bootindex has already used by another device just throw an error. Allow c

[Qemu-devel] [PATCH v5 2/8] bootindex: add del_boot_device_path function

2014-08-04 Thread arei.gonglei
From: Gonglei Introduce del_boot_device_path() to clean up fw_cfg content when hot-unplugging a device that refers to a bootindex. Signed-off-by: Gonglei Signed-off-by: Chenliang --- include/sysemu/sysemu.h | 1 + vl.c| 20 2 files changed, 21 inserti

[Qemu-devel] [PATCH v5 5/8] qmp: add set-bootindex command

2014-08-04 Thread arei.gonglei
From: Gonglei Adds "set-bootindex id=xx,bootindex=xx,suffix=xx" QMP command. Example QMP command: -> { "execute": "set-bootindex", "arguments": { "id": "ide0-0-1", "bootindex": 1, "suffix": "/disk@0"}} <- { "return": {} } Signed-off-by: Gonglei Signed-off-by: Chenliang --- qapi-schema.j

[Qemu-devel] [PATCH v5 4/8] bootindex: delete bootindex when device is removed

2014-08-04 Thread arei.gonglei
From: Gonglei Device should be removed from global boot list when it is hot-unplugged. Signed-off-by: Gonglei Signed-off-by: Chenliang --- hw/core/qdev.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/core/qdev.c b/hw/core/qdev.c index da1ba48..70294ad 100644 --- a/hw/core/qdev.c

[Qemu-devel] [PATCH v5 3/8] fw_cfg: add fw_cfg_machine_reset function

2014-08-04 Thread arei.gonglei
From: Gonglei We must assure that the changed bootindex can take effect when guest is rebooted. So we introduce fw_cfg_machine_reset(), which change the fw_cfg file's bootindex data using the new global fw_boot_order list. Signed-off-by: Chenliang Signed-off-by: Gonglei --- hw/nvram/fw_cfg.c

[Qemu-devel] [PATCH v5 0/8] modify boot order of guest, and take effect after rebooting

2014-08-04 Thread arei.gonglei
From: Gonglei Sometimes, we want to modify boot order of a guest, but no need to shutdown it. We can call dynamic changing bootindex of a guest, which can be assured taking effect just after the guest rebooting. For example, in P2V scene, we boot a guest and then attach a new system disk, for co

Re: [Qemu-devel] [PATCH v2 03/10] target-arm: Support save/load for 64 bit CPUs

2014-08-04 Thread Peter Maydell
On 10 July 2014 16:50, Alex Bennée wrote: > This enables the saving and restoring of machine state by including the > current program state (*psr) and xregs. The save_state_to_spsr hides the > details of if the processor is in 32 or 64 bit mode at the time. > > Signed-off-by: Alex Bennée > > ---

[Qemu-devel] [PATCH v5 7/8] qmp: add query-bootindex command

2014-08-04 Thread arei.gonglei
From: Gonglei Adds "query-bootindex" QMP command. Example QMP command: -> { "execute": "query-bootindex"} <- { "return":[ { "id":"ide0-0-0", "bootindex":1, "suffix":"/disk@0" }, { "id":"nic1", "bootinde

Re: [Qemu-devel] [PATCH v5 0/8] modify boot order of guest, and take effect after rebooting

2014-08-04 Thread Gonglei (Arei)
Hi, I' am so sorry for missing cc'ed Eduardo. Best regards, -Gonglei > -Original Message- > From: Gonglei (Arei) > Sent: Monday, August 04, 2014 8:46 PM > To: qemu-devel@nongnu.org > Subject: [PATCH v5 0/8] modify boot order of guest, and take effect after > rebooting > > From: Gonglei

[Qemu-devel] [PATCH v5 8/8] qemu-monitor: add HMP "info-bootindex" command

2014-08-04 Thread arei.gonglei
From: Gonglei Add HMP info-bootindex command to getting devcie's bootindex via monitor. Signed-off-by: Gonglei Signed-off-by: Chenliang --- hmp-commands.hx | 2 ++ hmp.c | 20 hmp.h | 1 + monitor.c | 7 +++ 4 files changed, 30 insertions(

[Qemu-devel] [PATCH v5 6/8] qemu-monitor: HMP set-bootindex wrapper

2014-08-04 Thread arei.gonglei
From: Gonglei Add HMP set-bootindex wrapper to allow setting devcie's bootindex via monitor. Signed-off-by: Gonglei Signed-off-by: Chenliang --- hmp-commands.hx | 15 +++ hmp.c | 13 + hmp.h | 1 + 3 files changed, 29 insertions(+) diff --git a/hm

Re: [Qemu-devel] [ANNOUNCE] QEMU 2.1.0 is now available

2014-08-04 Thread Michael S. Tsirkin
On Fri, Aug 01, 2014 at 11:33:28PM +0100, Peter Maydell wrote: > On 1 August 2014 17:41, Michael Roth wrote: > > On behalf of the QEMU Team, I'd like to announce the availability of > > the QEMU 2.1.0 release. This release contains 2200+ commits from 180 > > authors. > > > Thank you to everyone i

Re: [Qemu-devel] [PATCH v2 04/10] target-arm: replace cpsr/xpsr/pstate_read calls

2014-08-04 Thread Peter Maydell
On 10 July 2014 16:50, Alex Bennée wrote: > Use the unified save_state_to_spsr. I've also updated the interrupt > helpers to restore via the restore_state_from_spsr() functions. In the > aarch32 case this also needs to call switch_mode() to do the appropriate > fiddling. > > Signed-off-by: Alex Be

  1   2   3   4   >