Re: [Qemu-devel] ISA BIOS mapping for system flash emulation

2012-10-31 Thread Jan Kiszka
On 2012-11-01 03:55, Jordan Justen wrote: > On Tue, Oct 30, 2012 at 11:14 PM, Jan Kiszka wrote: >> Hi Jordan, >> >> I was starring at pc_isa_bios_init and wondering why you are creating a >> copy of the system flash for the low ISA range instead of using an alias >> here as well, just like old_pc_

Re: [Qemu-devel] spidev with omap3 running on qemu

2012-10-31 Thread Peter Crosthwaite
On Sat, Oct 27, 2012 at 7:24 PM, johan marx wrote: > Hi Peter, > > Thanks for the quick reply. I'm building with qemu-linaro Hi Johan, Sorry about the delay. Ive had a quick browse of this tree. The OMAP spi work there is ahead of whats in mainline, but is still divergent from the the ssi based

[Qemu-devel] buildbot failure in qemu on default_i386_debian_6_0

2012-10-31 Thread qemu
The Buildbot has detected a new failure on builder default_i386_debian_6_0 while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/default_i386_debian_6_0/builds/436 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: yuzuki Buil

Re: [Qemu-devel] ISA BIOS mapping for system flash emulation

2012-10-31 Thread Jordan Justen
On Tue, Oct 30, 2012 at 11:14 PM, Jan Kiszka wrote: > Hi Jordan, > > I was starring at pc_isa_bios_init and wondering why you are creating a > copy of the system flash for the low ISA range instead of using an alias > here as well, just like old_pc_system_rom_init does. That means the ISA > BIOS r

Re: [Qemu-devel] [patch v5 6/8] memory: make mmio dispatch able to be out of biglock

2012-10-31 Thread liu ping fan
On Tue, Oct 30, 2012 at 3:06 PM, liu ping fan wrote: > On Mon, Oct 29, 2012 at 5:41 PM, Avi Kivity wrote: >> On 10/29/2012 01:48 AM, Liu Ping Fan wrote: >>> Without biglock, we try to protect the mr by increase refcnt. >>> If we can inc refcnt, go backward and resort to biglock. >>> >>> Another p

[Qemu-devel] buildbot failure in qemu on default_x86_64_debian_6_0

2012-10-31 Thread qemu
The Buildbot has detected a new failure on builder default_x86_64_debian_6_0 while building qemu. Full details are available at: http://buildbot.b1-systems.de/qemu/builders/default_x86_64_debian_6_0/builds/436 Buildbot URL: http://buildbot.b1-systems.de/qemu/ Buildslave for this Build: yuzuki

Re: [Qemu-devel] [PATCH v12 09/14] target-mips: Add ASE DSP bit/manipulation instructions

2012-10-31 Thread Jia Liu
Hi Aurelien, On Thu, Nov 1, 2012 at 3:20 AM, Aurelien Jarno wrote: > On Wed, Oct 31, 2012 at 09:29:30PM +0800, Jia Liu wrote: >> >> Is this time OK? > > As said by Peter, I don't think the code should be modified, the > previous code was fine. > You mean my v12 09/14 is OK? It is a good news to

Re: [Qemu-devel] [PATCH v11] kvm: notify host when the guest is panicked

2012-10-31 Thread Marcelo Tosatti
On Tue, Oct 30, 2012 at 10:30:02PM -0400, Sasha Levin wrote: > On Tue, Oct 30, 2012 at 9:48 PM, Wen Congyang wrote: > > At 10/31/2012 09:12 AM, Marcelo Tosatti Wrote: > >> It has been asked earlier why a simple virtio device is not usable > >> for this (with no response IIRC). > > > > 1. We can't

[Qemu-devel] [PATCH 08/28] qapi: qapi_visit.py, support for q_string annotations

2012-10-31 Thread Michael Roth
Signed-off-by: Michael Roth --- scripts/qapi_visit.py | 13 - 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/scripts/qapi_visit.py b/scripts/qapi_visit.py index c531a5a..b3c6bfe 100644 --- a/scripts/qapi_visit.py +++ b/scripts/qapi_visit.py @@ -18,6 +18,14 @@ import

[Qemu-devel] [PATCH 05/28] qapi: qapi_visit.py, support arrays and complex qapi definitions

2012-10-31 Thread Michael Roth
Add support for arrays in the code generators. Complex field descriptions can now be used to provide additional information to the visitor generators, such as the max size of an array, or the field within a struct to use to determine how many elements are present in the array to avoid serializing

[Qemu-devel] [PATCH 17/28] qapi: add open-coded visitors for struct tm/Int128 types

2012-10-31 Thread Michael Roth
Reviewed-by: Anthony Liguori Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- qapi/Makefile.objs |1 + qapi/misc-qapi-visit.c | 37 + qapi/misc-qapi-visit.h | 16 3 files changed, 54 insertions(+) create mode 100644 qap

[Qemu-devel] [PATCH 03/28] qapi: qapi-commands.py -> qapi_commands.py

2012-10-31 Thread Michael Roth
Python doesn't allow "-" in module names, so we need to rename the file so we can re-use bits of the codegen. Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- Makefile |8 scripts/{qapi-commands.py => qapi_commands.py} |0 tests/M

[Qemu-devel] [PATCH 24/28] qidl: add lexer library (based on QC parser)

2012-10-31 Thread Michael Roth
Adds an abstract Lexer class to handle tokenizer via a peek/pop/peekline/popline interface, along with an implementation for C based on the lexer from qc.git Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- scripts/lexer.py | 325 ++

[Qemu-devel] [PATCH 04/28] qapi: qapi_visit.py, make code useable as module

2012-10-31 Thread Michael Roth
Reviewed-by: Anthony Liguori Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- scripts/qapi_visit.py | 157 + 1 file changed, 81 insertions(+), 76 deletions(-) diff --git a/scripts/qapi_visit.py b/scripts/qapi_visit.py index a360de7..f9

[Qemu-devel] [PATCH 25/28] qidl: add C parser (based on QC parser)

2012-10-31 Thread Michael Roth
This introduces the QIDL parser to process QIDL annotations in C files. This code is mostly a straight import from qc.git, with some reworking to handle the declaration/annotation format and lexer we're using for QEMU. Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- scripts/qidl_pars

[Qemu-devel] [PATCH 16/28] qapi: qapi.py, make json parser more robust

2012-10-31 Thread Michael Roth
Currently the QAPI JSON parser expects a very particular style of code indentation, the major one being that terminating curly/square brackets are not on placed on a seperate line. This is incompatible with most pretty-print formats, so make it a little more robust by supporting these cases. Also

[Qemu-devel] [PATCH 11/28] qapi: QmpInputVisitor, implement array handling

2012-10-31 Thread Michael Roth
Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- qapi/qmp-input-visitor.c | 30 ++ 1 file changed, 30 insertions(+) diff --git a/qapi/qmp-input-visitor.c b/qapi/qmp-input-visitor.c index 107d8d3..635106e 100644 --- a/qapi/qmp-input-visitor.c +++ b/qapi/qm

[Qemu-devel] [PATCH 18/28] qapi: Improve existing docs and document annotated QAPI types

2012-10-31 Thread Michael Roth
Signed-off-by: Michael Roth --- docs/qapi-code-gen.txt | 264 +--- 1 file changed, 250 insertions(+), 14 deletions(-) diff --git a/docs/qapi-code-gen.txt b/docs/qapi-code-gen.txt index cccb11e..ad4f929 100644 --- a/docs/qapi-code-gen.txt +++ b/docs/q

[Qemu-devel] [PATCH 20/28] qom-fuse: workaround for truncated properties > 4096

2012-10-31 Thread Michael Roth
We currently hard-code property size at 4096 for the purposes of getattr()/stat()/etc. For 'state' properties we can exceed this easily, leading to truncated responses. Instead, for a particular property, make it max(4096, most_recent_property_size * 2). This allows some head-room for properties t

[Qemu-devel] [PATCH 15/28] qapi: ordereddict, add to_json() method

2012-10-31 Thread Michael Roth
This allows OrderedDict() instances to be [pretty-]printed to QAPI-compatible JSON structures with field ordering preserved. This is useful for QIDL, which generates schemas programatically and exposes them to users in various ways. Signed-off-by: Michael Roth --- scripts/ordereddict.py | 51 +

[Qemu-devel] [PATCH 13/28] qapi: fix potential segfault for visit_type_size()

2012-10-31 Thread Michael Roth
visit_type_size() was added for use-cases currently only encountered by OptsVisitor users, which implements a specific handler for visit_type_size(). For Visitor implementations that don't implement the handler, we fallback to using v->type_uint64(). However, some visitor implementations, such as

[Qemu-devel] [PATCH 27/28] qidl: qidl.h, definitions for qidl annotations

2012-10-31 Thread Michael Roth
Signed-off-by: Michael Roth --- qidl.h | 162 1 file changed, 162 insertions(+) create mode 100644 qidl.h diff --git a/qidl.h b/qidl.h new file mode 100644 index 000..8d8dd7b --- /dev/null +++ b/qidl.h @@ -0,0 +1,162 @@ +/*

[Qemu-devel] [PATCH 26/28] qidl: add QAPI-based code generator

2012-10-31 Thread Michael Roth
This takes the declarations generated by the QIDL parser and converts them to QAPI schemas to generate the visitor routines and other supporting code for QIDL. Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- scripts/qidl.py | 328 +

[Qemu-devel] [PATCH 06/28] qapi: qapi_visit.py, support generating static functions

2012-10-31 Thread Michael Roth
qidl embeds visitor code into object files rather than linking against seperate files, so allow for static declarations when we're using qapi_visit.py as a library as we do with qidl.py Reviewed-by: Anthony Liguori Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- scripts/qapi_visit.p

[Qemu-devel] [PATCH 2/8] object: add object_property_add_bool (v2)

2012-10-31 Thread Anthony Liguori
Signed-off-by: Anthony Liguori --- v1 -> v2 - Fix whitespace (Andreas Faerber) --- include/qemu/object.h | 16 +++ qom/object.c | 56 +++ 2 files changed, 72 insertions(+) diff --git a/include/qemu/object.h b/include/qemu/obje

[Qemu-devel] [PATCH 09/28] qapi: add visitor interfaces for C arrays

2012-10-31 Thread Michael Roth
Generally these will be serialized into lists, but the representation can be of any form so long as it can be deserialized into a single-dimension C array. Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- qapi/qapi-visit-core.c | 25 + qapi/qapi-visit-core.h

[Qemu-devel] [PATCH 02/28] qapi: qapi-types.py -> qapi_types.py

2012-10-31 Thread Michael Roth
Python doesn't allow "-" in module names, so we need to rename the file so we can re-use bits of the codegen Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- Makefile |8 scripts/{qapi-types.py => qapi_types.py} |0 tests/Makefile

[Qemu-devel] [PATCH 23/28] qidl: add documentation

2012-10-31 Thread Michael Roth
Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- docs/qidl.txt | 347 + 1 file changed, 347 insertions(+) create mode 100644 docs/qidl.txt diff --git a/docs/qidl.txt b/docs/qidl.txt new file mode 100644 index 000..7d17cdc -

[Qemu-devel] [PATCH 28/28] qidl: unit tests and build infrastructure

2012-10-31 Thread Michael Roth
Signed-off-by: Michael Roth --- Makefile |3 + configure|1 + rules.mak| 42 - tests/Makefile |8 +- tests/test-qidl-included.h | 25 +++ tests/test-qidl-linked.c | 101 +++ tests/test-qi

[Qemu-devel] [PATCH 21/28] module additions for schema registration

2012-10-31 Thread Michael Roth
Reviewed-by: Anthony Liguori Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- module.h |2 ++ vl.c |1 + 2 files changed, 3 insertions(+) diff --git a/module.h b/module.h index c4ccd57..cb81aa2 100644 --- a/module.h +++ b/module.h @@ -25,6 +25,7 @@ typedef enum { MOD

[Qemu-devel] [PATCH 22/28] qdev: move Property-related declarations to qdev-properties.h

2012-10-31 Thread Michael Roth
Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- hw/qdev-properties.h | 151 ++ hw/qdev.h| 126 + 2 files changed, 152 insertions(+), 125 deletions(-) create mode 100644 hw/qdev-prope

[Qemu-devel] [PATCH 19/28] qom-fuse: force single-threaded mode to avoid QMP races

2012-10-31 Thread Michael Roth
python-fuse defaults to multi-threaded handling of filesystem calls. In the case of QOM this can lead to threads reading QMP responses to requests executed by other threads, causing all sorts of strangeness when interacting with QOM mounts. For instance: mdroth@loki:~/w/qom$ ls -l machine | grep

[Qemu-devel] [PATCH 10/28] qapi: QmpOutputVisitor, implement array handling

2012-10-31 Thread Michael Roth
Signed-off-by: Michael Roth --- qapi/qmp-output-visitor.c | 19 +++ 1 file changed, 19 insertions(+) diff --git a/qapi/qmp-output-visitor.c b/qapi/qmp-output-visitor.c index 2bce9d5..83cf0dc 100644 --- a/qapi/qmp-output-visitor.c +++ b/qapi/qmp-output-visitor.c @@ -181,6 +181,

[Qemu-devel] [PATCH 14/28] qapi: add visit_type_long()

2012-10-31 Thread Michael Roth
Signed-off-by: Michael Roth --- qapi/qapi-visit-core.c | 18 ++ qapi/qapi-visit-core.h |3 +++ 2 files changed, 21 insertions(+) diff --git a/qapi/qapi-visit-core.c b/qapi/qapi-visit-core.c index dd28cb9..274361f 100644 --- a/qapi/qapi-visit-core.c +++ b/qapi/qapi-visit-co

[Qemu-devel] [PATCH 12/28] qapi: QmpInputVisitor, don't re-allocate memory in start_struct

2012-10-31 Thread Michael Roth
If we're given a pointer that has already be initialized to a non-NULL value, don't attempt to allocate memory for the object as we'll likely clobber something we weren't supposed to. Also, fix up a check in the unit test that may fail as a result of this change do to it not initializing the objec

[Qemu-devel] [PATCH 01/28] qapi: qapi-visit.py -> qapi_visit.py so we can import

2012-10-31 Thread Michael Roth
Python doesn't allow "-" in module names, so we need to rename the file so we can re-use bits of the codegen Reviewed-by: Anthony Liguori Reviewed-by: Paolo Bonzini Signed-off-by: Michael Roth --- Makefile |8 scripts/{qapi-visit.py => qapi_visit.py

[Qemu-devel] [PATCH 07/28] qapi: qapi_visit.py, support for visiting non-pointer/embedded structs

2012-10-31 Thread Michael Roth
Reviewed-by: Anthony Liguori Signed-off-by: Michael Roth --- scripts/qapi_visit.py |9 + 1 file changed, 9 insertions(+) diff --git a/scripts/qapi_visit.py b/scripts/qapi_visit.py index 856df5e..c531a5a 100644 --- a/scripts/qapi_visit.py +++ b/scripts/qapi_visit.py @@ -145,6 +145,15

[Qemu-devel] [PATCH v6 00/28] Add infrastructure for QIDL-based device serialization (Happy Halloween Edition)

2012-10-31 Thread Michael Roth
These patches are based are origin/master, and can also be obtained from: git://github.com/mdroth/qemu.git qidl-base-v6 ___ .' `"-._ / ,`'-.-. / /`'. ,' _ \ `-'`-. ,' ,'\\/ \, ,' ee`-. / ./ ,(_ \ , (_/\\\ \__|`--

[Qemu-devel] [PATCH 5/8] rng-egd: introduce EGD compliant RNG backend

2012-10-31 Thread Anthony Liguori
This backend talks EGD to a CharDriverState. A typical way to invoke this would be: qemu -chardev socket,host=localhost,port=1024,id=chr0 \ -object rng-egd,chardev=chr0,id=egd0 \ -device virtio-rng-pci,rng=egd0 Signed-off-by: Anthony Liguori --- backends/Makefile.objs | 2 +- backe

[Qemu-devel] [PATCH 8/8] virtio-rng-pci: create a default backend if none exists

2012-10-31 Thread Anthony Liguori
This allows you to specify: $ qemu -device virtio-rng-pci And things will Just Work with a reasonable default. Signed-off-by: Anthony Liguori --- hw/virtio-pci.c | 13 + hw/virtio-rng.h | 2 ++ 2 files changed, 15 insertions(+) diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c ind

[Qemu-devel] [PATCH 6/8] virtio-rng: hardware random number generator device

2012-10-31 Thread Anthony Liguori
From: Amit Shah The Linux kernel already has a virtio-rng driver, this is the device implementation. When the guest asks for entropy from the virtio hwrng, it puts a buffer in the vq. We then put entropy into that buffer, and push it back to the guest. Signed-off-by: Amit Shah Signed-off-by:

[Qemu-devel] [PATCH 7/8] virtio-rng: add rate limiting support

2012-10-31 Thread Anthony Liguori
This adds parameters to virtio-rng-pci to allow rate limiting the entropy a guest receives. An example command line: $ qemu -device virtio-rng-pci,max-bytes=1024,period=1000 Would limit entropy collection to 1Kb/s. Signed-off-by: Anthony Liguori --- hw/virtio-pci.c | 7 +++ hw/virtio-rng

[Qemu-devel] [PATCH 0/8] add paravirtualization hwrng support (v3)

2012-10-31 Thread Anthony Liguori
Hi, This series implements the backend and frontend infrastructure for virtio-rng. This is similar to previous series sent out by both Amit and myself although it has been trimmed down considerably. In terms of backends, a file and EGD backend are supported. The file defaults to /dev/random base

[Qemu-devel] [Bug 1071149] Re: target-mips: special3 instruction dinsm translation error

2012-10-31 Thread Aurelien Jarno
Fixed in commit e0d002f17d1db1ade2b8d24b4a7c7ab361256726 ** Changed in: qemu Status: Confirmed => Fix Committed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1071149 Title: target-mips: spe

[Qemu-devel] [PATCH 4/8] rng-random: add an RNG backend that uses /dev/random (v3)

2012-10-31 Thread Anthony Liguori
The filename can be overridden but it expects a non-blocking source of entropy. A typical invocation would be: qemu -object rng-random,id=rng0 -device virtio-rng-pci,rng=rng0 This can also be used with /dev/urandom by using the command line: qemu -object rng-random,filename=/dev/urandom,id=rng0

[Qemu-devel] [PATCH 3/8] rng: add RndBackend abstract object class

2012-10-31 Thread Anthony Liguori
This is the backend used by devices that need to request entropy. Signed-off-by: Anthony Liguori --- Makefile.objs | 2 ++ backends/Makefile.objs | 1 + backends/rng.c | 93 ++ include/qemu/rng.h | 93

[Qemu-devel] [PATCH 1/8] vl: add -object option to create QOM objects from the command line

2012-10-31 Thread Anthony Liguori
This will create a new QOM object in the '/objects' path. Note that properties are set in order which allows for simple objects to be initialized entirely with this option and then realized. This option is roughly equivalent to -device but for things that are not devices. Signed-off-by: Anthony

Re: [Qemu-devel] [PATCH v2] chardev: Use timer instead of bottom-half to postpone open event

2012-10-31 Thread Aurelien Jarno
On Wed, Oct 31, 2012 at 02:23:15PM +0100, Jan Kiszka wrote: > On 2012-10-12 09:52, Jan Kiszka wrote: > > As the block layer may decide to flush bottom-halfs while the machine is > > still initializing (e.g. to read geometry data from the disk), our > > postponed open event may be processed before t

Re: [Qemu-devel] 64-on-32 TCG broken

2012-10-31 Thread Aurelien Jarno
On Wed, Oct 31, 2012 at 06:05:57PM +0100, Stefan Weil wrote: > Am 31.10.2012 00:56, schrieb Aurelien Jarno: > >On Tue, Oct 30, 2012 at 11:24:34PM +0100, Stefan Weil wrote: > >>Am 30.10.2012 09:15, schrieb Paolo Bonzini: > >>>Il 29/10/2012 19:29, Aurelien Jarno ha scritto: > On Mon, Oct 29, 2012

Re: [Qemu-devel] [PATCH 29/35] cpus: Pass CPUState to [qemu_]cpu_has_work()

2012-10-31 Thread Aurelien Jarno
On Wed, Oct 31, 2012 at 10:37:41PM +0100, Andreas Färber wrote: > Am 31.10.2012 22:05, schrieb Aurelien Jarno: > > On Wed, Oct 31, 2012 at 02:00:00AM +0100, Andreas Färber wrote: > >> For target-mips also change the return type to bool. > >> > >> Make include paths for cpu-qom.h consistent for alph

Re: [Qemu-devel] [PATCH 29/35] cpus: Pass CPUState to [qemu_]cpu_has_work()

2012-10-31 Thread Andreas Färber
Am 31.10.2012 22:05, schrieb Aurelien Jarno: > On Wed, Oct 31, 2012 at 02:00:00AM +0100, Andreas Färber wrote: >> For target-mips also change the return type to bool. >> >> Make include paths for cpu-qom.h consistent for alpha and unicore32. >> >> Signed-off-by: Andreas Färber >> [AF: Updated new

Re: [Qemu-devel] [PATCH 29/35] cpus: Pass CPUState to [qemu_]cpu_has_work()

2012-10-31 Thread Aurelien Jarno
On Wed, Oct 31, 2012 at 02:00:00AM +0100, Andreas Färber wrote: > For target-mips also change the return type to bool. > > Make include paths for cpu-qom.h consistent for alpha and unicore32. > > Signed-off-by: Andreas Färber > [AF: Updated new target-openrisc function accordingly] > --- > cpu-

Re: [Qemu-devel] [PATCH] target-alpha: Use TCG_CALL_NO_WG

2012-10-31 Thread Aurelien Jarno
On Wed, Oct 31, 2012 at 10:30:55AM +1100, Richard Henderson wrote: > Mark helper functions that raise exceptions, but otherwise do not > change TCG register state, with TCG_CALL_NO_WG. > > Signed-off-by: Richard Henderson > --- > target-alpha/helper.h | 20 ++-- > 1 file changed,

Re: [Qemu-devel] [PATCH v12 07/14] target-mips: Add ASE DSP GPR-based shift instructions

2012-10-31 Thread Aurelien Jarno
On Wed, Oct 31, 2012 at 09:26:08PM +0800, Jia Liu wrote: > Hi Aurelien, > > Is this time OK? Yes, the explanation is fine, though it means the generated code is then not really optimal. On the other hand it means the op is doing what it is supposed to do. > static void gen_mipsdsp_shift(DisasCon

[Qemu-devel] [Bug 1073585] [NEW] Deleting UDP socket in monitor mode

2012-10-31 Thread Vincent Autefage
Public bug reported: Hi, Here is the problem. I start an empty QEMU in monitor mode : QEMU 1.1.2 monitor - type 'help' for more information Warning: vlan 0 is not connected to host network (qemu) info network VLAN 0 devices: e1000.0: type=nic,model=e1000,macaddr=a2:00:00:00:00:01 Devices not o

Re: [Qemu-devel] [PATCH v12 09/14] target-mips: Add ASE DSP bit/manipulation instructions

2012-10-31 Thread Aurelien Jarno
On Wed, Oct 31, 2012 at 09:29:30PM +0800, Jia Liu wrote: > Hi Richard Peter Jovanovic and Aurelien, > > On Wed, Oct 31, 2012 at 1:26 PM, Richard Henderson wrote: > > On 2012-10-31 01:44, Peter Maydell wrote: > >> On 30 October 2012 15:34, Jia Liu wrote: > >>> On Mon, Oct 29, 2012 at 9:40 PM, Jov

Re: [Qemu-devel] [PATCH v2 1/3] tcg/arm: fix TLB access in qemu-ld/st ops

2012-10-31 Thread Aurelien Jarno
On Wed, Oct 31, 2012 at 02:54:38PM +0100, Laurent Desnogues wrote: > On Tue, Oct 30, 2012 at 1:18 AM, wrote: > > From: Aurelien Jarno > > > > The TCG arm backend considers likely that the offset to the TLB > > entries does not exceed 12 bits for mem_index = 0. In practice this is > > not true fo

Re: [Qemu-devel] [PATCH v4 0/7] TCG global variables clean-up

2012-10-31 Thread Richard Henderson
On 2012-10-31 16:19, Evgeny Voevodin wrote: > Evgeny (2): > tcg/tcg.h: Duplicate global TCG variables in TCGContext > TCG: Remove unused global variables > > Evgeny Voevodin (5): > target-cris/translate.c: Code style clean-up > TCG: Use gen_opc_ptr from context instead of global variable.

Re: [Qemu-devel] [PATCH v2 3/7] memory: iommu support

2012-10-31 Thread Benjamin Herrenschmidt
On Wed, 2012-10-31 at 12:32 +0200, Avi Kivity wrote: > This has nothing to do with device endianness; we're translating from a > byte buffer (address_space_rw()) to a uint64_t > (MemoryRegionOps::read/write()) so we need to take host endianess into > account. > > This code cleverly makes use of me

[Qemu-devel] [PATCH v2 2/3] aio: use g_slice_alloc() for AIOCB pooling

2012-10-31 Thread Stefan Hajnoczi
AIO control blocks are frequently acquired and released because each aio request involves at least one AIOCB. Therefore, we pool them to avoid heap allocation overhead. The problem with the freelist approach in AIOPool is thread-safety. If we want BlockDriverStates to associate with AioContexts

[Qemu-devel] [PATCH v2 3/3] aio: rename AIOPool to AIOCBInfo

2012-10-31 Thread Stefan Hajnoczi
Now that AIOPool no longer keeps a freelist, it isn't really a "pool" anymore. Rename it to AIOCBInfo and make it const since it no longer needs to be modified. Signed-off-by: Stefan Hajnoczi --- block.c | 22 +++--- block/blkdebug.c | 4 ++-- block/blkverify.c | 4

[Qemu-devel] [PATCH v2 1/3] aio: switch aiocb_size type int -> size_t

2012-10-31 Thread Stefan Hajnoczi
Using appropriate types for variables is a good thing :). All users simply do sizeof(MyType) and the value is passed to a memory allocator, it should be size_t. Signed-off-by: Stefan Hajnoczi --- qemu-aio.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qemu-aio.h b/qemu-ai

Re: [Qemu-devel] On block interface types in general, IF_AHCI in particular

2012-10-31 Thread Anthony Liguori
Alexander Graf writes: > On 31.10.2012, at 17:46, Anthony Liguori wrote: > >> Alexander Graf writes: >> >> >> We had 11,286 hits from WinXP last month on qemu.org >> >> Compare that to 16,716 hits for 64-bit Linux and a mere 9,516 hits for >> 32-bit Linux. > > So how many hits is that for Mac

[Qemu-devel] [PATCH v2] e1000: pre-initialize RAH/RAL registers

2012-10-31 Thread Gabriel L. Somlo
Some guest operating systems' drivers (Mac OS X in particular) fail to properly initialize the Receive Address registers (probably expecting them to be pre-initialized by an earlier component, such as a specific proprietary BIOS). This patch pre-initializes the RA registers, allowing OS X networkin

[Qemu-devel] [PATCH v2 27/39] main-loop: use GSource to poll AIO file descriptors

2012-10-31 Thread Paolo Bonzini
This lets us remove the hooks for the main loop in async.c. Reviewed-by: Anthony Liguori Signed-off-by: Paolo Bonzini --- main-loop.c | 23 ++- main-loop.h | 1 - 2 file modificati, 6 inserzioni(+), 18 rimozioni(-) diff --git a/main-loop.c b/main-loop.c index a86c275..365c

[Qemu-devel] [PATCH v2 06/39] iohandler: add weak alias in qemu-sockets.c, for qemu-ga

2012-10-31 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- qemu-sockets.c | 11 +++ 1 file modificato, 11 inserzioni(+) diff --git a/qemu-sockets.c b/qemu-sockets.c index 225cd0c..f2a6371 100644 --- a/qemu-sockets.c +++ b/qemu-sockets.c @@ -974,3 +974,14 @@ static int default_monitor_get_fd(Monitor *mon, const ch

[Qemu-devel] [PATCH v2 18/39] aio: introduce AioContext, move bottom halves there

2012-10-31 Thread Paolo Bonzini
Start introducing AioContext, which will let us remove globals from aio.c/async.c, and introduce multiple I/O threads. The bottom half functions now take an additional AioContext argument. A bottom half is created with a specific AioContext that remains the same throughout the lifetime. qemu_bh_n

[Qemu-devel] [PATCH 4/5] KVM: s390: Base infrastructure for enabling capabilities.

2012-10-31 Thread Cornelia Huck
Signed-off-by: Cornelia Huck --- Documentation/virtual/kvm/api.txt | 2 +- arch/s390/kvm/kvm-s390.c | 26 ++ 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/Documentation/virtual/kvm/api.txt b/Documentation/virtual/kvm/api.txt index 5d09948..a0408

[Qemu-devel] [PATCH v2 38/39] raw-posix: move linux-aio.c to block/

2012-10-31 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- Makefile.objs| 1 - block/Makefile.objs | 1 + linux-aio.c => block/linux-aio.c | 0 3 file modificati, 1 inserzione(+). 1 rimozione(-) rename linux-aio.c => block/linux-aio.c (100%) diff --git a/Makefile.objs b/Makefile.objs ind

[Qemu-devel] [PATCH v2 03/39] compiler: use weak aliases to provide default definitions

2012-10-31 Thread Paolo Bonzini
This is simpler and more portable. Signed-off-by: Paolo Bonzini --- arch_init.h | 2 +- compiler.h | 11 --- qmp.c | 3 ++- 3 file modificati, 7 inserzioni(+), 9 rimozioni(-) diff --git a/arch_init.h b/arch_init.h index d9c572a..5fc780c 100644 --- a/arch_init.h +++ b/arch_init.

[Qemu-devel] [PATCH 4/5] qemu-ga: win32: isolate virtio-serial specific code

2012-10-31 Thread Luiz Capitulino
This commit prepares ga_channel_new(), ga_channel_read() and ga_channel_open() for isa-serial support. Signed-off-by: Luiz Capitulino --- qga/channel-win32.c | 75 ++--- 1 file changed, 42 insertions(+), 33 deletions(-) diff --git a/qga/channel-wi

[Qemu-devel] [PATCH 5/5] qemu-ga: win32: add isa-serial support

2012-10-31 Thread Luiz Capitulino
It's implemented by opening the serial port in "non-blocking" mode and using the GSourceFuncs API in the following way: o prepare(): issue a read request. If something has been read, it's stored in rs->buf and rs->pending will store the number of bytes read

[Qemu-devel] [PATCH v2 33/39] threadpool: do not take lock in event_notifier_ready

2012-10-31 Thread Paolo Bonzini
The ordering is: worker thread consumer thread --- write ret event_notifier_test_and_clear wmb() read state write state

[Qemu-devel] [PATCH 3/5] KVM: s390: In-kernel handling of I/O instructions.

2012-10-31 Thread Cornelia Huck
Explicitely catch all channel I/O related instructions intercepts in the kernel and set condition code 3 for them. This paws the way for properly handling these instructions later on. Note: This is not architecture compliant (the previous code wasn't either) since setting cc 3 is not the correct

[Qemu-devel] [PATCH 2/5] qemu-ga: win32: add _ov suffix to current GSource functions

2012-10-31 Thread Luiz Capitulino
They are specific to virtio-serial code, which implements win32 overlaped I/O. A future commit will add a different kind of I/O. Signed-off-by: Luiz Capitulino --- qga/channel-win32.c | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/qga/channel-win32

[Qemu-devel] [PATCH 1/5] configure: link qemu-ga.exe in default make target

2012-10-31 Thread Luiz Capitulino
Avoids having to type "make qemu-ga.exe" after build is complete and also cleanups qemu-ga.exe in make clean. Signed-off-by: Luiz Capitulino --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 3685020..d15bf5b 100755 --- a/configure +++ b

[Qemu-devel] [PATCH v2 10/39] qemu-tool: do not depend on qemu-timer.c

2012-10-31 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- qemu-tool.c | 2 +- 1 file modificato, 1 inserzione(+). 1 rimozione(-) diff --git a/qemu-tool.c b/qemu-tool.c index 28a4e8d..b46631e 100644 --- a/qemu-tool.c +++ b/qemu-tool.c @@ -70,7 +70,7 @@ void monitor_protocol_event(MonitorEvent event, QObject *data) int

[Qemu-devel] [PATCH 0/5] qemu-ga: add isa-serial support to win32

2012-10-31 Thread Luiz Capitulino
Hi, This series adds isa-serial support to qemu-ga. This is done by opening the serial port in "non-blocking" mode and using the GSourceFuncs API (full details in patch 5/5). I've tried two other simpler ways of implementing this w/o success: 1. By more or less doing what we do in qemu-ga POSIX

[Qemu-devel] [PATCH 3/5] qemu-ga: win32: GAChannel: store GAChannelMethod being used

2012-10-31 Thread Luiz Capitulino
Next commit wants this. Signed-off-by: Luiz Capitulino --- qga/channel-win32.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/qga/channel-win32.c b/qga/channel-win32.c index c0e19a8..8e259c3 100644 --- a/qga/channel-win32.c +++ b/qga/channel-win32.c @@ -25,6 +25,7 @@ struct GAChannel {

[Qemu-devel] [PATCH 1/3] Update linux headers.

2012-10-31 Thread Cornelia Huck
Signed-off-by: Cornelia Huck --- linux-headers/asm-generic/kvm_para.h | 5 +++ linux-headers/asm-powerpc/kvm.h | 59 ++ linux-headers/asm-powerpc/kvm_para.h | 7 +++-- linux-headers/asm-x86/kvm.h | 17 ++ linux-headers/linux/kvm.h

[Qemu-devel] [PATCH v2 25/39] aio: add aio_notify

2012-10-31 Thread Paolo Bonzini
With this change async.c does not rely anymore on any service from main-loop.c, i.e. it is completely self-contained. Reviewed-by: Anthony Liguori Signed-off-by: Paolo Bonzini --- async.c| 30 ++ qemu-aio.h | 18 ++ 2 file modificati, 44 inserzion

[Qemu-devel] [PATCH v2 39/39] raw-win32: implement native asynchronous I/O

2012-10-31 Thread Paolo Bonzini
With the new support for EventNotifiers in the AIO event loop, we can hook a completion port to every opened file and use asynchronous I/O on them. Wine's support is extremely inefficient, also because it really does the I/O synchronously on regular files. (!) But it works, and it is good to keep

Re: [Qemu-devel] On block interface types in general, IF_AHCI in particular

2012-10-31 Thread Anthony Liguori
Alexander Graf writes: > On 31.10.2012, at 15:40, Paolo Bonzini wrote: > >> Il 31/10/2012 15:20, Markus Armbruster ha scritto: >>> One more thing: on a *major* upgrade, I'd rather deal with immediately >>> obvious breakage (does not boot) than rotten performance. >>> >>> If we make "q35 with com

[Qemu-devel] [PATCH v2 19/39] aio: add I/O handlers to the AioContext interface

2012-10-31 Thread Paolo Bonzini
With this patch, I/O handlers (including event notifier handlers) can be attached to a single AioContext. Signed-off-by: Paolo Bonzini --- aio.c | 68 - async.c | 6 ++ main-loop.c | 33 ++ qem

[Qemu-devel] [PATCH 3/3] s390: Add new channel I/O based virtio transport.

2012-10-31 Thread Cornelia Huck
Add a new virtio transport that uses channel commands to perform virtio operations. Add a new machine type s390-ccw that uses this virtio-ccw transport and make it the default machine for s390. Signed-off-by: Cornelia Huck --- hw/s390-virtio.c | 282 +++ hw/s390x/Makefile.objs

[Qemu-devel] [PATCH v2 32/39] aio: add generic thread-pool facility

2012-10-31 Thread Paolo Bonzini
Add a generic thread-pool. The code is roughly based on posix-aio-compat.c, with some changes, especially the following: - use QemuSemaphore instead of QemuCond; - separate the state of the thread from the return code of the worker function. The return code is totally opaque for the thread pool

[Qemu-devel] [PATCH v2 01/39] janitor: move iovector functions out of cutils.c

2012-10-31 Thread Paolo Bonzini
This removes the dependency of cutils.c on iov.c, and lets us remove iov.o from several builds. Signed-off-by: Paolo Bonzini --- Makefile | 2 +- Makefile.objs | 4 +-- cutils.c | 103 - iov.c | 103 +++

[Qemu-devel] [RFC PATCH v3 0/5] s390: Host support for channel I/O.

2012-10-31 Thread Cornelia Huck
Hi, here's the latest incarnation of my host patches to support channel I/O on s390. Most patches have only seen minor fixes, but patch 5 is completely different since the kvm <-> user space interface has been reworked. We now handle only interrupt-related operations in kvm. This includes two ch

[Qemu-devel] [PATCH v2 26/39] aio: call aio_notify after setting I/O handlers

2012-10-31 Thread Paolo Bonzini
In the current code, this is done by qemu_set_fd_handler2, which is called by qemu_aio_set_fd_handler. We need to keep the same behavior even after removing the call to qemu_set_fd_handler2. Reviewed-by: Anthony Liguori Signed-off-by: Paolo Bonzini --- aio-posix.c | 2 ++ aio-win32.c | 2 ++ 2

[Qemu-devel] [RFC PATCH v3 0/3] s390: channel I/O support in qemu.

2012-10-31 Thread Cornelia Huck
Hi, here's the latest version of my patchset introducing virtio-ccw. This has been reworked with the changed kernel interface: qemu will now handle all channel I/O requests (except the I/O interrupt related ones that are handled in-kernel in the kvm case). This avoids duplicating code in qemu and

[Qemu-devel] [PATCH v2 16/39] aio: change qemu_aio_set_fd_handler to return void

2012-10-31 Thread Paolo Bonzini
Reviewed-by: Anthony Liguori Signed-off-by: Paolo Bonzini --- aio.c | 12 +--- qemu-aio.h | 10 +- 2 file modificati, 10 inserzioni(+), 12 rimozioni(-) diff --git a/aio.c b/aio.c index c738a4e..e062aab 100644 --- a/aio.c +++ b/aio.c @@ -53,11 +53,11 @@ static AioHandler *fi

Re: [Qemu-devel] [PATCH 20/27] target-i386: do not call x86_cpu_realize() on cpu_x86_init()

2012-10-31 Thread Eduardo Habkost
On Wed, Oct 31, 2012 at 05:43:48PM +0100, Andreas Färber wrote: > Am 31.10.2012 17:32, schrieb Igor Mammedov: > > On Wed, 24 Oct 2012 15:49:54 -0200 > > Eduardo Habkost wrote: > > > >> The PC code will need to run additional steps when initializing the CPU > >> object, before x86_cpu_realize(). S

[Qemu-devel] [PATCH v2 04/39] sockets: use weak aliases instead of qemu-tool.c

2012-10-31 Thread Paolo Bonzini
qemu-tool.c has its own (largeish) set of dependencies. Weak aliases can be placed directly where people use them, and do not contribute to increasing the dependencies of generic utility files. Signed-off-by: Paolo Bonzini --- qemu-sockets.c | 7 +++ qemu-tool.c| 6 -- 2 file modifi

Re: [Qemu-devel] 64-on-32 TCG broken

2012-10-31 Thread Stefan Weil
Am 31.10.2012 00:56, schrieb Aurelien Jarno: On Tue, Oct 30, 2012 at 11:24:34PM +0100, Stefan Weil wrote: Am 30.10.2012 09:15, schrieb Paolo Bonzini: Il 29/10/2012 19:29, Aurelien Jarno ha scritto: On Mon, Oct 29, 2012 at 06:53:14PM +0100, Paolo Bonzini wrote: Known-good commit: 8473f37739321

[Qemu-devel] [PATCH v2 07/39] win32: add weak version of qemu_fd_register

2012-10-31 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- oslib-win32.c | 5 + 1 file modificato, 5 inserzioni(+) diff --git a/oslib-win32.c b/oslib-win32.c index 51b33e8..9ca83df 100644 --- a/oslib-win32.c +++ b/oslib-win32.c @@ -150,3 +150,8 @@ int qemu_get_thread_id(void) { return GetCurrentThreadId(); } +

Re: [Qemu-devel] [PATCH 20/27] target-i386: do not call x86_cpu_realize() on cpu_x86_init()

2012-10-31 Thread Eduardo Habkost
On Wed, Oct 31, 2012 at 05:32:33PM +0100, Igor Mammedov wrote: > On Wed, 24 Oct 2012 15:49:54 -0200 > Eduardo Habkost wrote: > > > The PC code will need to run additional steps when initializing the CPU > > object, before x86_cpu_realize(). So, make cpu_x86_init() not call > Killing cpu_x86_init(

Re: [Qemu-devel] On block interface types in general, IF_AHCI in particular

2012-10-31 Thread Alexander Graf
On 31.10.2012, at 17:46, Anthony Liguori wrote: > Alexander Graf writes: > >> On 31.10.2012, at 17:00, Anthony Liguori wrote: >> >>> Alexander Graf writes: >>> On 31.10.2012, at 15:40, Paolo Bonzini wrote: > Il 31/10/2012 15:20, Markus Armbruster ha scritto: >> One more th

[Qemu-devel] [PATCH v2 28/39] main-loop: use aio_notify for qemu_notify_event

2012-10-31 Thread Paolo Bonzini
Reviewed-by: Anthony Liguori Signed-off-by: Paolo Bonzini --- main-loop.c | 106 +--- 1 file modificato, 8 inserzioni(+), 98 rimozioni(-) diff --git a/main-loop.c b/main-loop.c index 365c9d3..e43c7c8 100644 --- a/main-loop.c +++ b/main-loo

[Qemu-devel] [PATCH] usb-redir: Fix usb errors when a combined input packet is pending on migrate

2012-10-31 Thread Hans de Goede
Without this the destination usb-redir device will be confused about in-flight packets after the migration, and eventually an usb transfer in the guest will timeout because of this. Signed-off-by: Hans de Goede --- hw/usb/redirect.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/usb/

Re: [Qemu-devel] On block interface types in general, IF_AHCI in particular

2012-10-31 Thread Paolo Bonzini
Il 31/10/2012 17:35, Alexander Graf ha scritto: >>> My Paul is Windows XP. I'm not sure about 2k3. Older Windows >>> versions are probably not relevant any more in practice and >>> requiring an explicit option may be reasonable. >> >> 2k3 doesn't do AHCI, either. There may be drivers around for >

  1   2   3   >