[Qemu-devel] [PATCH 2.1 18/36] qapi event: convert WATCHDOG

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 19 --- hw/watchdog/watchdog.c | 23 +++ monitor.c | 2 +- qapi-event.json | 15 +++ qapi-schema.json| 24

[Qemu-devel] [PATCH 2.1 16/36] qapi event: convert WAKEUP

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 12 qapi-event.json | 9 + vl.c| 2 +- 3 files changed, 10 insertions(+), 13 deletions(-) diff --git a/docs/qmp/qmp-events.txt b/docs/qmp/

[Qemu-devel] [PATCH 2.1 34/36] qemu-char: make writes thread-safe

2014-06-17 Thread Paolo Bonzini
This will let threads other than the I/O thread raise QMP events. GIOChannel is thread-safe, and send and receive state is usually well-separated. The only driver that requires some care is the pty driver, where some of the state is shared by the read and write sides. That state is protected wit

[Qemu-devel] [PATCH 2.1 32/36] qemu-char: do not call chr_write directly

2014-06-17 Thread Paolo Bonzini
Make the mux always go through qemu_chr_fe_write, so that we'll get the mutex for the underlying chardev. Reviewed-by: Fam Zheng Signed-off-by: Paolo Bonzini --- qemu-char.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/qemu-char.c b/qemu-char.c index 56a0a9

[Qemu-devel] [PATCH 2.1 25/36] qapi event: convert VNC events

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Since VNC_CONNECTED, VNC_DISCONNECTED, VNC_INITIALIZED share some common functions, convert them in one patch. Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 90 --- qapi-event.json | 49 +++

[Qemu-devel] [PATCH 2.1 35/36] monitor: protect outbuf and mux_out with mutex

2014-06-17 Thread Paolo Bonzini
This lets the block layer emit QMP events from outside the I/O thread. Reviewed-by: Luiz Capitulino Signed-off-by: Paolo Bonzini --- monitor.c | 45 - 1 file changed, 36 insertions(+), 9 deletions(-) diff --git a/monitor.c b/monitor.c index 66a1db7..

[Qemu-devel] [PATCH 2.1 29/36] qapi event: convert QUORUM events

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- block/quorum.c | 25 - docs/qmp/qmp-events.txt | 41 - monitor.c | 6 +++--- qapi-event.json | 38 ++

[Qemu-devel] [PATCH 2.1 07/36] monitor: add an implemention of qapi event emit method

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia The monitor is now hooked on the new event mechanism, so that later patches can convert event callers one by one. Most code are copied from old monitor_protocol_* functions with some modification. Note that two build time warnings will be raised after this patch. One is caused

[Qemu-devel] [PATCH 2.1 24/36] qapi event: convert NIC_RX_FILTER_CHANGED

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Param name is declared as optional, since in code it is an optional one. Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 17 - hw/net/virtio-net.c | 13 +++-- qapi-event.json | 15 +++ 3 fi

[Qemu-devel] [PATCH 2.1 08/36] qapi: add new schema file qapi-event.json

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- Makefile | 3 ++- qapi-event.json | 0 qapi-schema.json | 2 ++ 3 files changed, 4 insertions(+), 1 deletion(-) create mode 100644 qapi-event.json diff --git a/Makefile b/Makefile index f473cf5..7d0c8ec 10

[Qemu-devel] [PATCH 2.1 11/36] qapi event: convert RESET

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 12 qapi-event.json | 9 + vl.c| 2 +- 3 files changed, 10 insertions(+), 13 deletions(-) diff --git a/docs/qmp/qmp-events.txt b/docs/qmp/

[Qemu-devel] [PATCH 2.1 23/36] qapi event: convert other BLOCK_JOB events

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Since BLOCK_JOB_COMPLETED, BLOCK_JOB_CANCELLED, BLOCK_JOB_READY are related, convert them in one patch. The block_job_event_* functions are used to keep encapsulation of BlockJob structure. Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- block/mirror.c

[Qemu-devel] [PATCH 2.1 17/36] qapi event: convert RTC_CHANGE

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia This patch also eliminates build time warning caused by no caller of monitor_qapi_event_throttle(). Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 16 hw/ppc/spapr_rtas.c | 3 ++- hw/timer/mc146818rtc.c | 3 ++-

[Qemu-devel] [PATCH 2.1 15/36] qapi event: convert SUSPEND_DISK

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 14 -- hw/acpi/core.c | 4 ++-- qapi-event.json | 12 3 files changed, 14 insertions(+), 16 deletions(-) diff --git a/docs/qmp/qmp-events.txt b/do

[Qemu-devel] [PATCH 2.1 10/36] qapi event: convert POWERDOWN

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia There is no existing comments for POWERDOWN in doc/qmp/qmp-events.txt, so no change on it like other conversion patch. Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- qapi-event.json | 10 ++ vl.c| 2 +- 2 files changed, 11 insertions(+), 1 d

[Qemu-devel] [PATCH 2.1 13/36] qapi event: convert RESUME

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 12 qapi-event.json | 9 + vl.c| 2 +- 3 files changed, 10 insertions(+), 13 deletions(-) diff --git a/docs/qmp/qmp-events.txt b/docs/qmp/

[Qemu-devel] [PATCH 2.1 04/36] qapi script: add event support

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia qapi-event.py will parse the schema and generate qapi-event.c, then the API in qapi-event.c can be used to handle events in qemu code. All API have prefix "qapi_event". The script mainly includes two parts: generate API for each event define, generate an enum type for all defin

[Qemu-devel] [PATCH 2.1 03/36] qapi: add event helper functions

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia This file holds some functions that do not need to be generated. Signed-off-by: Wenchao Xia Reviewed-by: Eric Blake Signed-off-by: Paolo Bonzini --- include/qapi/qmp-event.h | 27 ++ qapi/Makefile.objs | 1 + qapi/qmp-event.c | 74

[Qemu-devel] [PATCH 2.1 09/36] qapi event: convert SHUTDOWN

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia This patch also eliminates build time warning caused by QAPI_EVENT_MAX = 0. Signed-off-by: Wenchao Xia Signed-off-by: Paolo Bonzini --- docs/qmp/qmp-events.txt | 15 --- qapi-event.json | 12 vl.c| 3 ++- 3 files changed,

[Qemu-devel] [PATCH 2.1 02/36] qapi: Add includes from qapi/ as dependencies

2014-06-17 Thread Paolo Bonzini
From: Max Reitz qapi-schema.json has been split into three smaller JSON files in qapi/. Add them as dependencies for the code generation in the Makefile, so changes to them will result in a rebuilt of all QAPI-dependent code. Signed-off-by: Max Reitz Signed-off-by: Paolo Bonzini --- Makefile

[Qemu-devel] [PATCH 2.1 00/36] Pending monitor patches for 2.1

2014-06-17 Thread Paolo Bonzini
This includes: - Max's dependency fixes for QAPI scripts - Wenchao's QAPI event series - my thread-safety fixes, rebased onto QAPI events Paolo Max Reitz (1): qapi: Add includes from qapi/ as dependencies Paolo Bonzini (6): qemu-char: introduce qemu_chr_alloc qemu-char: do not call chr_

[Qemu-devel] [PATCH 2.1 01/36] os-posix: include sys/time.h

2014-06-17 Thread Paolo Bonzini
From: Wenchao Xia Since gettimeofday() is used in this header file as a macro define, include the function's define header file, to avoid compile warning when other file include os-posix.h. Signed-off-by: Wenchao Xia Reviewed-by: Eric Blake Signed-off-by: Paolo Bonzini --- include/sysemu/os-

Re: [Qemu-devel] [PATCH v4 3/4] virtio-blk-test.c: add hotplug subtest

2014-06-17 Thread Amos Kong
On Tue, Jun 17, 2014 at 03:25:34PM +0200, Andreas Färber wrote: > Am 06.06.2014 16:33, schrieb Amos Kong: > > This patch adds a new subtest, it hotplugs 29 * 8 = 232 virtio-blk > > devices to guest, and try to hot-unplug them. > > > > Note: the hot-unplug can't work without cooperation of guest OS

Re: [Qemu-devel] [PATCH v4 2/4] qtest: introduce qmp_exec_hmp_cmd()

2014-06-17 Thread Amos Kong
On Tue, Jun 17, 2014 at 07:37:06PM +0200, Paolo Bonzini wrote: > Il 06/06/2014 16:33, Amos Kong ha scritto: > >+va_end(ap); > >+ > >+escaped_cmd = g_strescape(cmd, NULL); > >+response = qmp("{\"execute\": \"human-monitor-command\"," > >+ " \"arguments\": {" > >+

Re: [Qemu-devel] [PATCH V6 03/29] qapi script: add event support

2014-06-17 Thread Paolo Bonzini
Il 18/06/2014 05:33, Eric Blake ha scritto: > +# This work is licensed under the terms of the GNU GPL, version 2. > +# See the COPYING file in the top-level directory. Any reason this can't be GPLv2+ instead of GPLv2-only? I suppose because it copies parts of other qapi-* scripts. :( Paolo

Re: [Qemu-devel] [PATCH V6 00/29] add direct support of event in qapi schema

2014-06-17 Thread Paolo Bonzini
Il 18/06/2014 06:00, Eric Blake ha scritto: > -typedef void (*QMPEventFuncEmit)(int event_kind, QDict *dict, Error **errp); > +typedef void (*QMPEventFuncEmit)(unsigned event, QDict *dict, Error **errp); It looks like you have some churn on this definition; patch 4/29 in your qapi-event branch d

Re: [Qemu-devel] [PATCH] json-lexer: fix escaped backslash in single-quoted string

2014-06-17 Thread Amos Kong
On Fri, Jun 13, 2014 at 10:13:02AM +0200, Paolo Bonzini wrote: > This made the lexer wait for a closing *double* quote. > > Signed-off-by: Paolo Bonzini Reviewed-by: Amos Kong > --- > qobject/json-lexer.c | 4 ++-- > tests/check-qjson.c | 7 +++ > 2 files changed, 9 insertions(+), 2 del

Re: [Qemu-devel] [PATCH v4 0/4] test virtio-blk hotplug

2014-06-17 Thread Amos Kong
On Wed, Jun 18, 2014 at 10:58:52AM +0800, Amos Kong wrote: > On Tue, Jun 17, 2014 at 03:37:08PM +0200, Andreas Färber wrote: > > -BEGIN PGP SIGNED MESSAGE- > > Hash: SHA1 > > > > Hi Amos, > > > > Am 17.06.2014 14:54, schrieb Amos Kong: > > > On Mon, Jun 09, 2014 at 03:22:51PM +0200, Stefa

Re: [Qemu-devel] [PATCH 3/7] spapr: Refactor spapr_populate_memory()

2014-06-17 Thread Alexey Kardashevskiy
On 06/16/2014 05:53 PM, Alexey Kardashevskiy wrote: > Current QEMU does not support memoryless NUMA nodes. > This prepares SPAPR for that. > > This moves 2 calls of spapr_populate_memory_node() into > the existing loop which handles nodes other than than > the first one. > > Signed-off-by: Alexey

Re: [Qemu-devel] [PATCH] libvixl: Add gcc format attribute

2014-06-17 Thread Stefan Weil
Am 18.06.2014 06:31, schrieb Stefan Weil: > Am 18.06.2014 06:28, schrieb Richard Henderson: >>> I don't know the reason, because all locations seem to have arguments >>> which are function calls, and the called function returns Instr which >>> is uint32_t, not int64_t. >> ... >>> + void GCC_FMT_AT

Re: [Qemu-devel] [PATCH 3/3 v2] ppc debug: Add debug stub support

2014-06-17 Thread bharat.bhus...@freescale.com
> -Original Message- > From: Alexander Graf [mailto:ag...@suse.de] > Sent: Tuesday, June 17, 2014 4:14 PM > To: Bhushan Bharat-R65777; qemu-...@nongnu.org; qemu-devel@nongnu.org > Subject: Re: [PATCH 3/3 v2] ppc debug: Add debug stub support > > > On 17.06.14 12:40, bharat.bhus...@frees

Re: [Qemu-devel] [PATCH] libvixl: Add gcc format attribute

2014-06-17 Thread Stefan Weil
Am 18.06.2014 06:28, schrieb Richard Henderson: >> I don't know the reason, because all locations seem to have arguments >> which are function calls, and the called function returns Instr which >> is uint32_t, not int64_t. > ... >> + void GCC_FMT_ATTR(2, 3) AppendToOutput(const char* string, ...);

Re: [Qemu-devel] [PATCH] libvixl: Add gcc format attribute

2014-06-17 Thread Richard Henderson
> I don't know the reason, because all locations seem to have arguments > which are function calls, and the called function returns Instr which > is uint32_t, not int64_t. ... > + void GCC_FMT_ATTR(2, 3) AppendToOutput(const char* string, ...); It "helps" because 2,3 is wrong. Correct would be 1

Re: [Qemu-devel] [PATCH] libvixl: Add gcc format attribute

2014-06-17 Thread Stefan Weil
Am 18.06.2014 00:09, schrieb Peter Maydell: > On 17 June 2014 22:07, Stefan Weil wrote: >> This helps detecting wrong format strings. >> >> Signed-off-by: Stefan Weil >> --- >> >> This patch is not intended to be applied before fixing some potential errors. >> >> Addings the GNU gcc format attrib

Re: [Qemu-devel] [PATCH] check NULL opts in qemu_opt_get functions

2014-06-17 Thread Eric Blake
On 06/17/2014 08:47 PM, Chunyan Liu wrote: > Some places will call bdrv_create_file(filename, NULL, &local_err), where > opts is NULL. Check NULL in qemu_opt_get and qemu_opt_get_*_del functions, > to avoid extra effort of checking opts before calling them every time. > > Signed-off-by: Chunyan Li

Re: [Qemu-devel] [PATCH V6 00/29] add direct support of event in qapi schema

2014-06-17 Thread Eric Blake
On 06/17/2014 04:57 AM, Paolo Bonzini wrote: > Il 15/06/2014 02:52, Wenchao Xia ha scritto: >>> Unfortunately, this already does not apply anymore. >>> >>> I've placed the rebase on branch qapi-event of my github repository. The >>> resolutions are trivial, so perhaps Luiz or Michael can pull from

[Qemu-devel] [Bug 1308341] Re: Multiple CPUs causes blue screen on Windows guest (14.04 regression)

2014-06-17 Thread Serge Hallyn
-smp 4 -realtime mlock=off -rtc base=localtime does not seem to help me reproduce this. Does the system have to be under stress? Can you reproduce this without virtio? -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.lau

Re: [Qemu-devel] [PATCH v6 2/3] qapi: add const prefix to 'char *' insider c_type()

2014-06-17 Thread Eric Blake
On 06/10/2014 05:25 AM, Amos Kong wrote: > It's ugly to add const prefix for parameter type by an if statement > outside c_type(). This patch adds a parameter to do it. > > Signed-off-by: Amos Kong > Suggested-by: Markus Armbruster > Reviewed-by: Eric Blake > Reviewed-by: Paolo Bonzini > Revie

Re: [Qemu-devel] [PATCH V6 03/29] qapi script: add event support

2014-06-17 Thread Eric Blake
On 06/05/2014 06:21 AM, Wenchao Xia wrote: > qapi-event.py will parse the schema and generate qapi-event.c, then > the API in qapi-event.c can be used to handle event in qemu code. > All API have prefix "qapi_event". > > The script mainly includes two parts: generate API for each event > define, g

Re: [Qemu-devel] [PATCH V6 03/29] qapi script: add event support

2014-06-17 Thread Eric Blake
On 06/05/2014 06:21 AM, Wenchao Xia wrote: > qapi-event.py will parse the schema and generate qapi-event.c, then > the API in qapi-event.c can be used to handle event in qemu code. > All API have prefix "qapi_event". > > The script mainly includes two parts: generate API for each event > define, g

Re: [Qemu-devel] [PULL 091/103] qapi: make string input visitor parse int list

2014-06-17 Thread Michael S. Tsirkin
On Tue, Jun 17, 2014 at 03:36:35PM -0600, Eric Blake wrote: > On 06/17/2014 11:41 AM, Michael S. Tsirkin wrote: > > From: Hu Tao > > > > Signed-off-by: Hu Tao > > Acked-by: Michael S. Tsirkin > > Tested-by: Michael S. Tsirkin > > Signed-off-by: Michael S. Tsirkin > > > > MST: split up patch

Re: [Qemu-devel] [PATCH v4 0/4] test virtio-blk hotplug

2014-06-17 Thread Stefan Hajnoczi
On Wed, Jun 18, 2014 at 10:58 AM, Amos Kong wrote: > On Tue, Jun 17, 2014 at 03:37:08PM +0200, Andreas Färber wrote: >> That said, I've reviewed the generic qtest part OK, and would assume >> virtio-blk-test (you can drop the .c in the topic please) to go >> through the same tree virtio-blk does,

Re: [Qemu-devel] [PATCH v4 0/4] test virtio-blk hotplug

2014-06-17 Thread Amos Kong
On Tue, Jun 17, 2014 at 03:37:08PM +0200, Andreas Färber wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Hi Amos, > > Am 17.06.2014 14:54, schrieb Amos Kong: > > On Mon, Jun 09, 2014 at 03:22:51PM +0200, Stefan Hajnoczi wrote: > >> On Fri, Jun 06, 2014 at 10:33:49PM +0800, Amos Kong

Re: [Qemu-devel] qemu-img segfault on latest git

2014-06-17 Thread Chun Yan Liu
Fixed by adding NULL opts check in qemu_opt_get functions. Patch is here: http://comments.gmane.org/gmane.comp.emulators.qemu/280916 Regards, Chunyan >>> On 6/17/2014 at 11:08 PM, in message , Milos Vyletel wrote: > Hi, > > I hope this is the right place to report this. I've noticed that I

[Qemu-devel] [PATCH] check NULL opts in qemu_opt_get functions

2014-06-17 Thread Chunyan Liu
Some places will call bdrv_create_file(filename, NULL, &local_err), where opts is NULL. Check NULL in qemu_opt_get and qemu_opt_get_*_del functions, to avoid extra effort of checking opts before calling them every time. Signed-off-by: Chunyan Liu --- Fix reported bugs: http://lists.gnu.org/archi

Re: [Qemu-devel] [PATCH 6/6] kvm_stat: Add powerpc support

2014-06-17 Thread Alexander Graf
On 18.06.14 03:37, Michael Ellerman wrote: On Wed, 2014-06-18 at 02:59 +0200, Alexander Graf wrote: On 18.06.14 02:50, Michael Ellerman wrote: On Tue, 2014-06-17 at 10:27 +0200, Alexander Graf wrote: On 17.06.14 09:54, Michael Ellerman wrote: Add support for powerpc platforms. We use uname -

Re: [Qemu-devel] [PATCH 6/6] kvm_stat: Add powerpc support

2014-06-17 Thread Michael Ellerman
On Wed, 2014-06-18 at 02:59 +0200, Alexander Graf wrote: > On 18.06.14 02:50, Michael Ellerman wrote: > > On Tue, 2014-06-17 at 10:27 +0200, Alexander Graf wrote: > >> On 17.06.14 09:54, Michael Ellerman wrote: > >>> Add support for powerpc platforms. We use uname -m, which allows us to > >>> detec

Re: [Qemu-devel] [PATCH 6/6] kvm_stat: Add powerpc support

2014-06-17 Thread Alexander Graf
On 18.06.14 02:50, Michael Ellerman wrote: On Tue, 2014-06-17 at 10:27 +0200, Alexander Graf wrote: On 17.06.14 09:54, Michael Ellerman wrote: Add support for powerpc platforms. We use uname -m, which allows us to detect ppc, ppc64 and ppc64le/el. Signed-off-by: Michael Ellerman Could you p

Re: [Qemu-devel] [PATCH 6/6] kvm_stat: Add powerpc support

2014-06-17 Thread Michael Ellerman
On Tue, 2014-06-17 at 10:27 +0200, Alexander Graf wrote: > On 17.06.14 09:54, Michael Ellerman wrote: > > Add support for powerpc platforms. We use uname -m, which allows us to > > detect ppc, ppc64 and ppc64le/el. > > > > Signed-off-by: Michael Ellerman > > Could you please add support for PR KV

Re: [Qemu-devel] [PATCH] target-i386: Fix indentation of CPU model definitions

2014-06-17 Thread Andreas Färber
Am 18.06.2014 01:05, schrieb Eduardo Habkost: > Signed-off-by: Eduardo Habkost > --- > target-i386/cpu.c | 204 > +++--- > 1 file changed, 102 insertions(+), 102 deletions(-) Thanks, applied to qom-cpu. Andreas -- SUSE LINUX Products GmbH, Maxf

Re: [Qemu-devel] [qom/qom-cpu PATCH] i386: improve invtsc migration blocker error message

2014-06-17 Thread Andreas Färber
Am 29.05.2014 18:55, schrieb Marcelo Tosatti: > > Improve migration blocker error message. > > Signed-off-by: Marcelo Tosatti > > diff --git a/target-i386/kvm.c b/target-i386/kvm.c > index f9ffa4b..cfe1271 100644 > --- a/target-i386/kvm.c > +++ b/target-i386/kvm.c > @@ -711,7 +711,8 @@ int kvm_

Re: [Qemu-devel] [RFC v1 1/2] arm: Add the cortex-a9 CPU to the a9mpcore device

2014-06-17 Thread Alistair Francis
On Tue, Jun 17, 2014 at 8:12 PM, Peter Crosthwaite wrote: > On Tue, Jun 17, 2014 at 6:05 PM, Paolo Bonzini wrote: >> Il 17/06/2014 09:16, Stefan Hajnoczi ha scritto: >> >>> > The bigger issue though is how do you do an N:1 mapping. The container >>> > should only have 1 "midr" prop, but it should

[Qemu-devel] [PATCHv2] usb: Fix usb-bt-dongle initialization.

2014-06-17 Thread Hani Benhabiles
Due to an incomplete initialization, adding a usb-bt-dongle device through HMP or QMP will cause a segmentation fault. Signed-off-by: Hani Benhabiles Suggested-by: Paolo Bonzini --- Compared to v1: * Remove duplicate code from usb_bt_init() and inline usb_create_simple() call. * usb_bt_initfn()

Re: [Qemu-devel] [RFC] qemu VGA endian swap low level drawing changes

2014-06-17 Thread Benjamin Herrenschmidt
On Wed, 2014-06-18 at 01:05 +0200, Alexander Graf wrote: > Given that, the prerequisite to that interface is to have a guest > exposed register to flip the endianness in the first place. I think it > makes most sense to settle on that register first, then talk about > potential backwards compat

[Qemu-devel] [PATCH v2] hw/mips: gt64xxx_pci: Add VMStateDescription

2014-06-17 Thread James Hogan
From: Sanjay Lal Add VMStateDescription for GT64120 PCI emulation used by the Malta platform, to allow it to work with savevm/loadvm and live migration. Signed-off-by: Sanjay Lal [james.ho...@imgtec.com: Convert to VMState] Signed-off-by: James Hogan Cc: Aurelien Jarno --- This is based on "[

Re: [Qemu-devel] [RFC] qemu VGA endian swap low level drawing changes

2014-06-17 Thread Alexander Graf
On 18.06.14 00:55, Benjamin Herrenschmidt wrote: On Tue, 2014-06-17 at 23:12 +0100, Peter Maydell wrote: On 17 June 2014 22:32, Benjamin Herrenschmidt wrote: Additionally, I wouldn't mind of we did a quick "trick" equivalent (but cleaner) to what I did in my patch which is when the pseries gu

[Qemu-devel] [PATCH] target-i386: Fix indentation of CPU model definitions

2014-06-17 Thread Eduardo Habkost
Signed-off-by: Eduardo Habkost --- target-i386/cpu.c | 204 +++--- 1 file changed, 102 insertions(+), 102 deletions(-) diff --git a/target-i386/cpu.c b/target-i386/cpu.c index 8983457..830c3c6 100644 --- a/target-i386/cpu.c +++ b/target-i386/cpu.c

[Qemu-devel] [PATCH 0/2] block: Fix unset "filename" for certain drivers

2014-06-17 Thread Max Reitz
For some protocol block drivers, the "filename" attribute in their BDSs is unset due to bdrv_file_open() removing it from the options QDict before bdrv_open_common() is able to copy it into the BDS. Fix this by not removing it until until bdrv_open_common() has indeed copied it. Max Reitz (2):

Re: [Qemu-devel] [PATCH] taget-i386: Broadwell CPU model

2014-06-17 Thread Eduardo Habkost
On Tue, Jun 17, 2014 at 10:34:16PM +0200, Andreas Färber wrote: [...] > > +.features[FEAT_1_EDX] = > > +CPUID_SSE2 | CPUID_SSE | CPUID_FXSR | CPUID_MMX | > > + CPUID_CLFLUSH | CPUID_PSE36 | CPUID_PAT | CPUID_CMOV | > > CPUID_MCA | > > + CPUID_PGE | CPUID

Re: [Qemu-devel] [RFC] qemu VGA endian swap low level drawing changes

2014-06-17 Thread Benjamin Herrenschmidt
On Tue, 2014-06-17 at 23:12 +0100, Peter Maydell wrote: > On 17 June 2014 22:32, Benjamin Herrenschmidt > wrote: > > Additionally, I wouldn't mind of we did a quick "trick" equivalent (but > > cleaner) to what I did in my patch which is when the pseries guest calls > > the hypervisor call to chan

Re: [Qemu-devel] [PATCH] usb: Fix usb-bt-dongle segfault.

2014-06-17 Thread Hani Benhabiles
On Mon, Jun 16, 2014 at 11:00:42AM +0200, Paolo Bonzini wrote: > Il 15/06/2014 23:37, Hani Benhabiles ha scritto: > >>>diff --git a/hw/usb/dev-bluetooth.c b/hw/usb/dev-bluetooth.c > >>>index a9661d2..6d02343 100644 > >>>--- a/hw/usb/dev-bluetooth.c > >>>+++ b/hw/usb/dev-bluetooth.c > >>>@@ -506,6 +

[Qemu-devel] [PATCH v5 00/12] KVM Support for MIPS32 Processors

2014-06-17 Thread James Hogan
The patchset depends on v4 of "target-mips: implement UserLocal Register". I'm aiming for QEMU 2.1, hopefully it isn't too late to get some final review. Thanks to everybody who has already taken part in review. This patchset implements KVM support for MIPS32 processors, using Trap & Emulation.

[Qemu-devel] [PATCH v5 12/12] MAINTAINERS: Add entry for MIPS KVM

2014-06-17 Thread James Hogan
Add MAINTAINERS entry for MIPS KVM. Signed-off-by: James Hogan --- Changes in v4: - Add MAINTAINERS entry for MIPS KVM. --- MAINTAINERS | 5 + 1 file changed, 5 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 51a6f51842be..0a637c90c679 100644 --- a/MAINTAINERS +++ b/MAINTAINERS

[Qemu-devel] [PATCH v6 for 2.1 00/10] Modify block jobs to use node-names

2014-06-17 Thread Jeff Cody
Changes from v5->v6: * Check for attempt to commit an image to itself (Eric) * Add a comment to the bdrv_find for block-commit, indicating that libvirt uses the error case for probing (Eric) * Added Benoit's R-b's Changes from v4->v5: * Rebased on master * Fixed commit log typos / stale paragr

Re: [Qemu-devel] [PATCH v6 for 2.1 04/10] block: make 'top' argument to block-commit optional

2014-06-17 Thread Eric Blake
On 06/17/2014 03:53 PM, Jeff Cody wrote: > Now that active layer block-commit is supported, the 'top' argument > no longer needs to be mandatory. > > Change it to optional, with the default being the active layer in the > device chain. > > Reviewed-by: Eric Blake > Reviewed-by: Benoit Canet > S

[Qemu-devel] [PATCH v5 04/12] target-mips: get_physical_address: Add defines for segment bases

2014-06-17 Thread James Hogan
Add preprocessor definitions for 32bit segment bases for use in get_physical_address(). These will also be taken advantage of in the next patch which adds KVM awareness. Signed-off-by: James Hogan Reviewed-by: Aurelien Jarno --- target-mips/helper.c | 18 -- 1 file changed, 12 i

[Qemu-devel] [PATCH v5 09/12] hw/mips: In KVM mode, inject IRQ2 (I/O) interrupts via ioctls

2014-06-17 Thread James Hogan
From: Sanjay Lal COP0 emulation is in-kernel for KVM, so inject IRQ2 (I/O) interrupts via ioctls. Signed-off-by: Sanjay Lal Signed-off-by: James Hogan Reviewed-by: Aurelien Jarno Reviewed-by: Andreas Färber --- Changes in v5: - Fix typo in subject (s/interupts/interrupts/) Changes in v3:

[Qemu-devel] [PATCH v5 10/12] hw/mips: malta: Add KVM support

2014-06-17 Thread James Hogan
In KVM mode the bootrom is loaded and executed from the last 1MB of DRAM. Based on "[PATCH 12/12] KVM/MIPS: General KVM support and support for SMP Guests" by Sanjay Lal . Signed-off-by: James Hogan Reviewed-by: Aurelien Jarno Cc: Peter Maydell Cc: Sanjay Lal --- Changes in v5: - Kseg0 doesn

[Qemu-devel] [PATCH v5 06/12] kvm: Allow arch to set sigmask length

2014-06-17 Thread James Hogan
MIPS/Linux is unusual in having 128 signals rather than just 64 like most other architectures. This means its sigmask is 16 bytes instead of 8, so allow arches to override the sigmask->len value passed to the KVM_SET_SIGNAL_MASK ioctl in kvm_set_signal_mask() by calling kvm_set_sigmask_len() from k

[Qemu-devel] [PATCH v5 05/12] target-mips: get_physical_address: Add KVM awareness

2014-06-17 Thread James Hogan
MIPS KVM trap & emulate mode (which is currently the only supported mode) has to add an extra kseg0/kseg1 at 0x4000 and an extra kseg2/kseg3 at 0x6000. Take this into account in get_physical_address() so that debug memory access works. This is done by translating the address to a standard

[Qemu-devel] [PATCH 1/2] block: Do not prematurely remove "filename"

2014-06-17 Thread Max Reitz
If "filename" is removed from the options QDict before entering bdrv_open_common(), it cannot be stored in the BDS. Therefore, wait until it has been copied there and remove it from the options only afterwards. This fixes "filename" in the BDS being empty for block drivers which do not need the fi

[Qemu-devel] [PATCH v5 11/12] target-mips: Enable KVM support in build system

2014-06-17 Thread James Hogan
From: Sanjay Lal Enable KVM support for MIPS in the build system. Signed-off-by: Sanjay Lal Signed-off-by: James Hogan Reviewed-by: Aurelien Jarno --- Changes in v2: - Expand commit message - Remove GIC code - Create asm-mips symlink using generic code and move above default case (Peter

[Qemu-devel] [PATCH v5 01/12] target-mips: Reset CPU timer consistently

2014-06-17 Thread James Hogan
The MIPS CPU timer (CP0 Count/Compare registers & QEMU timer) is reset at machine initialisation, including starting the timeout. Both registers however are placed before mvp in CPUMIPSState so they will both be zeroed on reset by the memset in mips_cpu_reset() including soon after init. This doesn

[Qemu-devel] [PATCH v5 08/12] target-mips: Call kvm_mips_reset_vcpu() from mips_cpu_reset()

2014-06-17 Thread James Hogan
When KVM is enabled call kvm_mips_reset_vcpu() from mips_cpu_reset() as done for other targets since commit 50a2c6e55fa2 (kvm: reset state from the CPU's reset method). Signed-off-by: James Hogan Cc: Aurelien Jarno Cc: Paolo Bonzini Cc: Gleb Natapov --- Changes in v5: - New patch, based on co

[Qemu-devel] [PATCH v5 03/12] hw/mips: Add API to convert KVM guest KSEG0 <-> GPA

2014-06-17 Thread James Hogan
From: Sanjay Lal Add API for converting physical addresses to KVM guest KSEG0 addresses, and fix the existing API for converting KSEG0 addresses to physical addresses to work in the KVM case. Both have the same sized KSEG0, so it's just a case of fixing the mask. In KVM trap and emulate mode bot

[Qemu-devel] [PATCH 2/2] iotests: Add test for set "filename" for NBD

2014-06-17 Thread Max Reitz
Add a new test for qemu-iotests which checks whether the "filename" (and consequently the "file") attribute is set for images which are opened over NBD. Signed-off-by: Max Reitz --- tests/qemu-iotests/097 | 72 ++ tests/qemu-iotests/097.out | 13 ++

[Qemu-devel] [PATCH v5 02/12] hw/mips/cputimer: Don't start periodic timer in KVM mode

2014-06-17 Thread James Hogan
From: Sanjay Lal Compare/Count timer interrupts are handled in-kernel for KVM. Therefore don't bother creating the timer at init time if KVM is enabled. This will conveniently avoid attempts to set the timeout when cpu_mips_store_count() is called at reset with KVM enabled, treating the timer as

[Qemu-devel] [PATCH v5 07/12] target-mips: kvm: Add main KVM support for MIPS

2014-06-17 Thread James Hogan
From: Sanjay Lal Implement the main KVM arch API for MIPS. Signed-off-by: Sanjay Lal Signed-off-by: James Hogan Cc: Aurelien Jarno Cc: Gleb Natapov Cc: Paolo Bonzini Cc: Andreas Färber Cc: Peter Maydell --- Changes in v5: - Rename kvm_arch_reset_vcpu to kvm_mips_reset_vcpu based on commi

Re: [Qemu-devel] [RFC] qemu VGA endian swap low level drawing changes

2014-06-17 Thread Peter Maydell
On 17 June 2014 22:32, Benjamin Herrenschmidt wrote: > Additionally, I wouldn't mind of we did a quick "trick" equivalent (but > cleaner) to what I did in my patch which is when the pseries guest calls > the hypervisor call to change the interrupt endian mode, we notify VGA > and switch its endian

Re: [Qemu-devel] [PATCH V6 00/29] add direct support of event in qapi schema

2014-06-17 Thread Wenchao Xia
于 2014/6/18 0:30, Paolo Bonzini 写道: Il 17/06/2014 18:05, Eric Blake ha scritto: diff --git a/Makefile b/Makefile index 3e65525..f473cf5 100644 --- a/Makefile +++ b/Makefile @@ -246,8 +246,7 @@ $(SRC_PATH)/qga/qapi-schema.json $(SRC_PATH)/scripts/qapi-commands.py $(qapi-py) $(gen-out-typ

Re: [Qemu-devel] [PATCH] libvixl: Add gcc format attribute

2014-06-17 Thread Peter Maydell
On 17 June 2014 22:07, Stefan Weil wrote: > This helps detecting wrong format strings. > > Signed-off-by: Stefan Weil > --- > > This patch is not intended to be applied before fixing some potential errors. > > Addings the GNU gcc format attribute results in lots of compiler errors like > these o

[Qemu-devel] [PATCH v6 for 2.1 07/10] block: add ability for block-stream to use node-name

2014-06-17 Thread Jeff Cody
This adds the ability for block-stream to use node-name arguments for base, to specify the backing image to stream from. Both 'base' and 'base-node-name' are optional, but mutually exclusive. Either can be specified, but not both together. Reviewed-by: Eric Blake Signed-off-by: Jeff Cody --- b

Re: [Qemu-devel] [PATCH v5 00/10] Modify block jobs to use node-names

2014-06-17 Thread Jeff Cody
On Tue, Jun 17, 2014 at 06:19:13AM -0600, Eric Blake wrote: > On 06/13/2014 12:52 PM, Jeff Cody wrote: > > Changes from v4->v5: > > > > * Rebased on master > > * Fixed commit log typos / stale paragraphs (Eric) > > * Fixed comment typo (Eric) > > * Added Eric's remaining R-b's > > > > On IRC, we

[Qemu-devel] [PATCH v6 for 2.1 10/10] block: add QAPI command to allow live backing file change

2014-06-17 Thread Jeff Cody
This allows a user to make a live change to the backing file recorded in an open image. The image file to modify can be specified 2 ways: 1) image filename 2) image node-name Note: this does not cause the backing file itself to be reopened; it merely changes the backing filename in the image fil

[Qemu-devel] [PATCH v6 for 2.1 03/10] block: simplify bdrv_find_base() and bdrv_find_overlay()

2014-06-17 Thread Jeff Cody
This simplifies the function bdrv_find_overlay(). With this change, bdrv_find_base() is just a subset of usage of bdrv_find_overlay(), so this also takes advantage of that. Reviewed-by: Eric Blake Reviewed-by: Benoit Canet Signed-off-by: Jeff Cody --- block.c | 45 ++--

[Qemu-devel] [PATCH v6 for 2.1 08/10] block: add backing-file option to block-stream

2014-06-17 Thread Jeff Cody
On some image chains, QEMU may not always be able to resolve the filenames properly, when updating the backing file of an image after a block job. For instance, certain relative pathnames may fail, or drives may have been specified originally by file descriptor (e.g. /dev/fd/???), or a relative pr

[Qemu-devel] [PATCH v6 for 2.1 09/10] block: Add QMP documentation for block-stream

2014-06-17 Thread Jeff Cody
The QMP command 'block-stream' was missing QMP documentation. Add that documentation. Reviewed-by: Eric Blake Reviewed-by: Benoit Canet Signed-off-by: Jeff Cody --- qmp-commands.hx | 58 + 1 file changed, 58 insertions(+) diff --git a/q

[Qemu-devel] [PATCH v6 for 2.1 06/10] block: extend block-commit to accept a string for the backing file

2014-06-17 Thread Jeff Cody
On some image chains, QEMU may not always be able to resolve the filenames properly, when updating the backing file of an image after a block commit. For instance, certain relative pathnames may fail, or drives may have been specified originally by file descriptor (e.g. /dev/fd/???), or a relative

[Qemu-devel] [PATCH v6 for 2.1 05/10] block: Accept node-name arguments for block-commit

2014-06-17 Thread Jeff Cody
This modifies the block operation block-commit so that it will accept node-name arguments for either 'top' or 'base' BDS. The filename and node-name are mutually exclusive to each other; i.e.: "top" and "top-node-name" are mutually exclusive (enforced) "base" and "base-node-name" are mutua

[Qemu-devel] [PATCH v6 for 2.1 04/10] block: make 'top' argument to block-commit optional

2014-06-17 Thread Jeff Cody
Now that active layer block-commit is supported, the 'top' argument no longer needs to be mandatory. Change it to optional, with the default being the active layer in the device chain. Reviewed-by: Eric Blake Reviewed-by: Benoit Canet Signed-off-by: Jeff Cody --- blockdev.c | 16 +

[Qemu-devel] [PATCH v6 for 2.1 02/10] block: add helper function to determine if a BDS is in a chain

2014-06-17 Thread Jeff Cody
This is a small helper function, to determine if 'base' is in the chain of BlockDriverState 'top'. It returns true if it is in the chain, and false otherwise. If either argument is NULL, it will also return false. Reviewed-by: Benoit Canet Reviewed-by: Eric Blake Signed-off-by: Jeff Cody ---

[Qemu-devel] [PATCH v6 for 2.1 01/10] block: Auto-generate node_names for each BDS entry

2014-06-17 Thread Jeff Cody
Currently, node_name is only filled in when done so explicitly by the user. If no node_name is specified, then the node name field is not populated. If node_names are automatically generated when not specified, that means that all block job operations can be done by reference to the unique node_n

Re: [Qemu-devel] [PULL 092/103] qapi: make string output visitor parse int list

2014-06-17 Thread Eric Blake
On 06/17/2014 11:41 AM, Michael S. Tsirkin wrote: > From: Hu Tao > > Signed-off-by: Hu Tao > Acked-by: Michael S. Tsirkin > Tested-by: Michael S. Tsirkin > Signed-off-by: Michael S. Tsirkin > > MST: split up patch > --- > qapi/string-output-visitor.c | 229 > +

Re: [Qemu-devel] [PULL 091/103] qapi: make string input visitor parse int list

2014-06-17 Thread Eric Blake
On 06/17/2014 11:41 AM, Michael S. Tsirkin wrote: > From: Hu Tao > > Signed-off-by: Hu Tao > Acked-by: Michael S. Tsirkin > Tested-by: Michael S. Tsirkin > Signed-off-by: Michael S. Tsirkin > > MST: split up patch > --- > qapi/string-input-visitor.c | 195 > ++

Re: [Qemu-devel] [RFC] qemu VGA endian swap low level drawing changes

2014-06-17 Thread Benjamin Herrenschmidt
On Tue, 2014-06-17 at 13:57 +0200, Gerd Hoffmann wrote: > Ok, it is supposed to work this way: > > The virtual graphics card creates a DisplaySurface, which is a pixman > image under the hood. There are basically two ways to do that: > > (1) Use qemu_create_displaysurface(). Allocates host m

Re: [Qemu-devel] [PATCH] linux-user: added fake open() for /proc/self/cmdline

2014-06-17 Thread Eric Blake
On 06/16/2014 09:16 PM, li...@fixnum.org wrote: > From: Wim Vander Schelden > > --- Missing a Signed-off-by declaration; without that legal hurdle, we are unwilling to take the patch. For more details: http://wiki.qemu.org/Contribute/SubmitAPatch > linux-user/syscall.c | 49 ++

[Qemu-devel] [PULL 039/103] ich: get rid of spaces in type name

2014-06-17 Thread Michael S. Tsirkin
Names with spaces in them are nasty, let's not go there. Signed-off-by: Michael S. Tsirkin --- include/hw/i386/ich9.h | 2 +- include/hw/i386/pc.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/hw/i386/ich9.h b/include/hw/i386/ich9.h index e191435..59ea25b 10064

[Qemu-devel] [PULL 101/103] acpi: implement ospm_status() method for PIIX4/ICH9_LPC devices

2014-06-17 Thread Michael S. Tsirkin
From: Igor Mammedov ... using TYPE_ACPI_DEVICE_IF interface. Which provides status reporting of ACPI declared memory devices Signed-off-by: Igor Mammedov Reviewed-by: Eric Blake Acked-by: Michael S. Tsirkin --- include/hw/acpi/ich9.h | 3 +++ include/hw/acpi/memory_hotplug.h | 1

[Qemu-devel] [PATCH] libvixl: Add gcc format attribute

2014-06-17 Thread Stefan Weil
This helps detecting wrong format strings. Signed-off-by: Stefan Weil --- This patch is not intended to be applied before fixing some potential errors. Addings the GNU gcc format attribute results in lots of compiler errors like these ones: CXX disas/libvixl/a64/disasm-a64.o disas/libvixl

[Qemu-devel] [PULL 103/103] qmp: add ACPI_DEVICE_OST event handling

2014-06-17 Thread Michael S. Tsirkin
From: Igor Mammedov emits event when ACPI OSPM evaluates _OST method of ACPI device. Signed-off-by: Igor Mammedov Reviewed-by: Eric Blake Acked-by: Michael S. Tsirkin --- include/monitor/monitor.h | 1 + hw/acpi/memory_hotplug.c | 29 - monitor.c

  1   2   3   4   5   6   >