[Qemu-devel] [PATCH v3 0/4] char: write callback, virtio-console: flow control

2010-04-15 Thread Amit Shah
Hello, This series lets interested callers ask for an -EAGAIN return from the chardev backends (only unix and tcp sockets as of now) to implement their own flow control. Support for other backend types is easy to add, I'll do that in a separate series if this is acceptable. Amit Shah (4): char

[Qemu-devel] [PATCH v3 1/4] char: Let writers know how much data was written in case of errors

2010-04-15 Thread Amit Shah
On writing errors, we just returned -1 even if some bytes were already written out. Ensure we return the number of bytes written before we return the error (on a subsequent call to qemu_chr_write()). Signed-off-by: Amit Shah --- qemu-char.c |9 +++-- 1 files changed, 7 insertions(+), 2 d

[Qemu-devel] [PATCH v3 3/4] virtio-console: Factor out common init between console and generic ports

2010-04-15 Thread Amit Shah
The initialisation for generic ports and console ports is similar. Factor out the parts that are the same in a different function that can be called from each of the initfns. Signed-off-by: Amit Shah --- hw/virtio-console.c | 31 ++- 1 files changed, 14 insertions(+

[Qemu-devel] [PATCH v3 2/4] char: Add ability to provide a callback when write won't return -EAGAIN

2010-04-15 Thread Amit Shah
For nonblocking chardevs, we can return -EAGAIN to callers of qemu_chr_write() and let the caller know that the backend is ready to accept more data via a callback. Currently only unix and tcp sockets have the ability to return -EAGAIN and to provide such a callback. Update all callers of qemu ch

[Qemu-devel] [PATCH v3 4/4] virtio-console: Throttle virtio-serial-bus if we can't consume any more guest data

2010-04-15 Thread Amit Shah
If the char device we're connected to is overwhelmed with data and it can't accept any more, signal to the virtio-serial-bus to stop sending us more data till we tell otherwise. If the current buffer being processed hasn't been completely written out to the char device, we have to keep it around a

Re: [Qemu-devel] Call for help in reviewing patches (!kvm & linux-user)

2010-04-15 Thread Riku Voipio
On Thu, Apr 15, 2010 at 01:32:17AM +0200, Aurelien Jarno wrote: > My impression is that few persons have interest in linux-user or > non-KVM targets areas, at least from the development point of view. > I personally don't care about linux-user code, though I have tried to > merge patches in this a

[Qemu-devel] Re: [PATCH v4 3/3] Inter-VM shared memory PCI device

2010-04-15 Thread Avi Kivity
On 04/15/2010 02:30 AM, Cam Macdonell wrote: Sample programs, init scripts and the shared memory server are available in a git repo here: www.gitorious.org/nahanni Please consider qemu.git/contrib. Should the compilation be tied into Qemu's regular build with a switch (e.

Re: [Qemu-devel] [RFC PATCH 4/5] block: Open the underlying image file in generic code

2010-04-15 Thread Stefan Hajnoczi
On Wed, Apr 14, 2010 at 4:50 PM, Kevin Wolf wrote: > diff --git a/block/qcow.c b/block/qcow.c > index c619984..01b1692 100644 > --- a/block/qcow.c > +++ b/block/qcow.c [..] > @@ -169,7 +166,7 @@ static int qcow_open(BlockDriverState *bs, const char > *filename, int flags) >     qemu_free(s->l2_ca

Re: [Qemu-devel] Re: Missing singlestep for already-translated code?

2010-04-15 Thread Jan Kiszka
Jun Koi wrote: > On Wed, Apr 14, 2010 at 12:28 AM, Jan Kiszka wrote: >> Alexander Graf wrote: >>> On 13.04.2010, at 15:36, Jan Kiszka wrote: >>> Jun Koi wrote: > Hi, > > I am looking into the singlestep command in monitor interface, and it > seems that we only take into accoun

Re: [Qemu-devel] Re: Missing singlestep for already-translated code?

2010-04-15 Thread Aurelien Jarno
Jun Koi a écrit : > On Wed, Apr 14, 2010 at 12:28 AM, Jan Kiszka wrote: >> Alexander Graf wrote: >>> On 13.04.2010, at 15:36, Jan Kiszka wrote: >>> Jun Koi wrote: > Hi, > > I am looking into the singlestep command in monitor interface, and it > seems that we only take into acc

Re: [Qemu-devel] Re: Missing singlestep for already-translated code?

2010-04-15 Thread Jan Kiszka
Aurelien Jarno wrote: > Jun Koi a écrit : >> On Wed, Apr 14, 2010 at 12:28 AM, Jan Kiszka wrote: >>> Alexander Graf wrote: On 13.04.2010, at 15:36, Jan Kiszka wrote: > Jun Koi wrote: >> Hi, >> >> I am looking into the singlestep command in monitor interface, and it >>

Re: [Qemu-devel] Re: Missing singlestep for already-translated code?

2010-04-15 Thread Aurelien Jarno
Jan Kiszka a écrit : > Aurelien Jarno wrote: >> Jun Koi a écrit : >>> On Wed, Apr 14, 2010 at 12:28 AM, Jan Kiszka wrote: Alexander Graf wrote: > On 13.04.2010, at 15:36, Jan Kiszka wrote: > >> Jun Koi wrote: >>> Hi, >>> >>> I am looking into the singlestep command in

Re: [Qemu-devel] [PATCH v3 0/4] char: write callback, virtio-console: flow control

2010-04-15 Thread Paul Brook
> This series lets interested callers ask for an -EAGAIN return from the > chardev backends (only unix and tcp sockets as of now) to implement > their own flow control. As mentioned previously, I think this is a bad idea. The device has no useful way of determining when to transmit the rest of t

Re: [Qemu-devel] [PATCH v3 0/4] char: write callback, virtio-console: flow control

2010-04-15 Thread Amit Shah
On (Thu) Apr 15 2010 [13:04:40], Paul Brook wrote: > > This series lets interested callers ask for an -EAGAIN return from the > > chardev backends (only unix and tcp sockets as of now) to implement > > their own flow control. > > As mentioned previously, I think this is a bad idea. The device has

[Qemu-devel] [PATCH] qcow2: Use QLIST_FOREACH_SAFE macro

2010-04-15 Thread Stefan Hajnoczi
Signed-off-by: Stefan Hajnoczi --- block/qcow2.c | 10 ++ 1 files changed, 2 insertions(+), 8 deletions(-) diff --git a/block/qcow2.c b/block/qcow2.c index 11ce8d1..9b986ae 100644 --- a/block/qcow2.c +++ b/block/qcow2.c @@ -539,14 +539,8 @@ static void run_dependent_requests(QCowL2Meta

[Qemu-devel] Re: [PATCH] qcow2: Use QLIST_FOREACH_SAFE macro

2010-04-15 Thread Kevin Wolf
Am 15.04.2010 15:11, schrieb Stefan Hajnoczi: > Signed-off-by: Stefan Hajnoczi Thanks, applied to the block branch. Kevin

[Qemu-devel] [PATCH -V5 19/21] virtio-9p: Add P9_TREMOVE support.

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TREMOVE support. This gets file deletion to work. [mo...@in.ibm.com: Fix truncate to use the relative path] Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/file-op-9p.h |1 + hw/virtio-9p-local.c |6 ++ hw/virtio-9p.c

[Qemu-devel] [PATCH -V5 21/21] virtio-9p: Create a syntactic shortcut for the file-system pass-thru

2010-04-15 Thread Aneesh Kumar K.V
From: Gautham R Shenoy Currently the commandline to create a virtual-filesystem pass-through between the guest and the host is as follows: #qemu -fsdev fstype,id=ID,path=path/to/share \ -device virtio-9p-pci,fsdev=ID,mount_tag=tag \ This patch provides a syntactic short-cut to achieve the

[Qemu-devel] [PATCH -V5 16/21] virtio-9p: Add P9_TWRITE support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TWRITE support. This gets write to file to work Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/file-op-9p.h |1 + hw/virtio-9p-local.c |7 +++ hw/virtio-9p.c | 112 +-

[Qemu-devel] [PATCH -V5 20/21] virtio-9p: Add P9_TFLUSH support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Don't do anything special for flush. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 35 ++- 1 files changed, 2 insertions(+), 33 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c index 94b799

[Qemu-devel] [PATCH -V5 13/21] virtio-9p: Add P9_TOPEN support.

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TOPEN support. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/file-op-9p.h |2 + hw/virtio-9p-local.c | 12 hw/virtio-9p.c | 153 -- 3 files changed, 162 insertions

[Qemu-devel] [PATCH -V5 08/21] virtio-9p: Add sg helper functions

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Add scatter-gather helper functions. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 53 + 1 files changed, 53 insertions(+), 0 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio

[Qemu-devel] [PATCH -V5 15/21] virtio-9p: Add P9_TCLUNK support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TCLUNK support. This patch gets `ls -al` to work. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 16 ++-- 1 files changed, 14 insertions(+), 2 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c index

[Qemu-devel] [PATCH -V5 09/21] virtio-9p: Add P9_TVERSION support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TVERSION support. [sripat...@in.ibm.com: Handle unknown 9P versions as per the standards] Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 15 +-- 1 files changed, 13 insertions(+), 2 deletions(-) diff --git

[Qemu-devel] [PATCH -V5 12/21] virtio-9p: Add P9_TWALK support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TWALK support. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 173 +++- 1 files changed, 171 insertions(+), 2 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c

[Qemu-devel] [PATCH -V5 07/21] virtio-9p: Add stat and mode related helper functions.

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Add helpers to obtain file stat and mode details. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 186 1 files changed, 186 insertions(+), 0 deletions(-) diff --git a/hw/virtio

[Qemu-devel] [PATCH -V5 17/21] virtio-9p: Add P9_TCREATE support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TCREATE support. [jv...@linux.vnet.ibm.com: strdup to qemu_strdup conversion] Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/file-op-9p.h |8 ++ hw/virtio-9p-local.c | 87 + hw/virtio-9p.c | 264 ++

[Qemu-devel] [PATCH -V5 11/21] virtio-9p: Add P9_TSTAT support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TSTAT support. This get the mount to work on the guest. [ki...@linux.vnet.ibm.com: malloc to qemu_malloc conversion] Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 55 +++

[Qemu-devel] [PATCH -V5 06/21] virtio-9p: Add fid and qid management support.

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Helper APIs for FID and QID management. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 123 1 files changed, 123 insertions(+), 0 deletions(-) diff --git a/hw/virtio-9p.c b/hw

[Qemu-devel] [PATCH -V5 18/21] virtio-9p: Add P9_TWSTAT support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TWSTAT support. This gets file and directory creation to work. [jv...@linux.vnet.ibm.com: strdup to qemu_strdup conversion] [aneesh.ku...@linux.vnet.ibm.com: v9fs_fix_path] Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/file-op-9p.h

[Qemu-devel] [PATCH -V5 14/21] virtio-9p: Add P9_TREAD support

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TREAD support. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/file-op-9p.h |6 ++ hw/virtio-9p-local.c | 37 hw/virtio-9p.c | 234 +- 3 files changed, 275 inser

[Qemu-devel] [PATCH -V5 04/21] virtio-9p: Add string manipulation support.

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Add helpers to do string manipulation. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 127 1 files changed, 127 insertions(+), 0 deletions(-) diff --git a/hw/virtio-9p.c b/hw/

[Qemu-devel] [PATCH -V5 03/21] virtio-9p: pdu processing support.

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Add helpers to process the PDUs. [ki...@linux.vnet.ibm.com: malloc to qemu_malloc coversion] Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p-debug.h |7 ++ hw/virtio-9p.c | 243 ++

[Qemu-devel] [PATCH -V5 10/21] virtio-9p: Add P9_TATTACH support.

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Implement P9_TATTACH support. Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 33 +++-- 1 files changed, 31 insertions(+), 2 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c index ccc45a3..4ab4f9

[Qemu-devel] [PATCH -V5 00/21] virtio-9p: paravirtual file system passthrough

2010-04-15 Thread Aneesh Kumar K.V
Hi, This patch series adds VirtFS to QEMU. VirtFS is code named for a 9P filesystem server in QEMU enabling paravirtual filesystem pass-trhough between KVM host and guest. VirtFS is intended to offer an alternative to using NFS/CIFS to share host filesystems on guest and provides better perform

[Qemu-devel] [PATCH -V5 05/21] virtio-9p: Add minimal set of FileOperations

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori Add minimal set of FileOperations and the corresponding implementations for local fstype. These will be required for the FID management patches later on. [aneesh.ku...@linux.vnet.ibm.com: rpath fix ] Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- hw/f

[Qemu-devel] [PATCH -V5 02/21] virtio-9p: Add a virtio 9p device to qemu

2010-04-15 Thread Aneesh Kumar K.V
From: Anthony Liguori This patch doesn't implement the 9p protocol handling code. It adds a simple device which dump the protocol data. [jv...@linux.vnet.ibm.com: Little-Endian to host format conversion] [aneesh.ku...@linux.vnet.ibm.com: Multiple-mounts support] Signed-off-by: Anthony Liguori

[Qemu-devel] [PATCH -V5 01/21] virtio-9p: Create a commandline option -fsdev

2010-04-15 Thread Aneesh Kumar K.V
From: Gautham R Shenoy This patch creates a new command line option named -fsdev to hold any file system specific information. The option will currently hold the following attributes: -fsdev fstype id=id,path=path_to_share where fstype: Type of the file system. id: Identifier used to refer t

[Qemu-devel] [PATCH v3 12/12] net: Remove info_str from VLANClientState, not needed anymore

2010-04-15 Thread Miguel Di Ciurcio Filho
Signed-off-by: Miguel Di Ciurcio Filho --- net.c |9 - net.h |2 -- 2 files changed, 0 insertions(+), 11 deletions(-) diff --git a/net.c b/net.c index 46e8873..5dfe24d 100644 --- a/net.c +++ b/net.c @@ -168,15 +168,6 @@ int parse_host_port(struct sockaddr_in *saddr, const char *

[Qemu-devel] [PATCH v3 11/12] monitor/net: Convert do_info_network() to QObject/QMP

2010-04-15 Thread Miguel Di Ciurcio Filho
Each device is represented by a QDict. The returned QObject is a QList of all devices. This commit slightly changes the monitor output when 'info network' is used. Old output: (qemu) info network VLAN 1 devices: e1000.0: model=e1000,macaddr=52:54:00:12:34:56 VLAN 0 devices: tap.0: i

[Qemu-devel] [PATCH v3 10/12] net: xen: use info_dict instead of info_str

2010-04-15 Thread Miguel Di Ciurcio Filho
Signed-off-by: Miguel Di Ciurcio Filho --- hw/xen_nic.c |6 -- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hw/xen_nic.c b/hw/xen_nic.c index 08055b8..d51839d 100644 --- a/hw/xen_nic.c +++ b/hw/xen_nic.c @@ -43,6 +43,8 @@ #include "net/checksum.h" #include "net/util.h"

[Qemu-devel] [PATCH v3 09/12] net: socket: use info_dict instead of info_str

2010-04-15 Thread Miguel Di Ciurcio Filho
Signed-off-by: Miguel Di Ciurcio Filho --- net/socket.c | 47 --- 1 files changed, 32 insertions(+), 15 deletions(-) diff --git a/net/socket.c b/net/socket.c index 1c4e153..fa5d24d 100644 --- a/net/socket.c +++ b/net/socket.c @@ -28,6 +28,10 @@ #inc

[Qemu-devel] [PATCH v3 07/12] net: vde: use info_dict instead of info_str

2010-04-15 Thread Miguel Di Ciurcio Filho
Signed-off-by: Miguel Di Ciurcio Filho --- net/vde.c |9 +++-- 1 files changed, 7 insertions(+), 2 deletions(-) diff --git a/net/vde.c b/net/vde.c index 0b46fa6..f582878 100644 --- a/net/vde.c +++ b/net/vde.c @@ -31,6 +31,9 @@ #include "qemu-char.h" #include "qemu-common.h" #include "

[Qemu-devel] [PATCH v3 08/12] net: dump: use info_dict instead of info_str

2010-04-15 Thread Miguel Di Ciurcio Filho
Signed-off-by: Miguel Di Ciurcio Filho --- net/dump.c |8 ++-- 1 files changed, 6 insertions(+), 2 deletions(-) diff --git a/net/dump.c b/net/dump.c index 6db7ecf..dea7f7d 100644 --- a/net/dump.c +++ b/net/dump.c @@ -27,6 +27,9 @@ #include "sysemu.h" #include "qemu-error.h" #include "

[Qemu-devel] [PATCH v3 04/12] net: various devices: replace qemu_format_nic_info_str by qemu_format_nic_info_dict

2010-04-15 Thread Miguel Di Ciurcio Filho
These are simple one line changes to replace qemu_format_nic_info_str. Signed-off-by: Miguel Di Ciurcio Filho --- hw/dp8393x.c|2 +- hw/e1000.c |2 +- hw/lan9118.c|4 ++-- hw/mcf_fec.c|2 +- hw/mipsnet.c|2 +- hw/ne2000-isa.c |

[Qemu-devel] [PATCH v3 06/12] net: tap/tap-win32: use info_dict instead of info_str

2010-04-15 Thread Miguel Di Ciurcio Filho
Signed-off-by: Miguel Di Ciurcio Filho --- net/tap-win32.c |9 ++--- net/tap.c | 18 +- 2 files changed, 19 insertions(+), 8 deletions(-) diff --git a/net/tap-win32.c b/net/tap-win32.c index 74348da..a54cd31 100644 --- a/net/tap-win32.c +++ b/net/tap-win32.c @@ -3

[Qemu-devel] [PATCH v3 03/12] net: eepro100: replace qemu_format_nic_info_str by qemu_format_nic_info_dict

2010-04-15 Thread Miguel Di Ciurcio Filho
Signed-off-by: Miguel Di Ciurcio Filho --- hw/eepro100.c | 10 -- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 7db6fb5..457bda8 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c @@ -1978,8 +1978,14 @@ static int nic_init(PCIDevice *pci_

[Qemu-devel] [PATCH v3 05/12] net: slirp: use info_dict instead of info_str

2010-04-15 Thread Miguel Di Ciurcio Filho
Signed-off-by: Miguel Di Ciurcio Filho --- net/slirp.c |8 ++-- 1 files changed, 6 insertions(+), 2 deletions(-) diff --git a/net/slirp.c b/net/slirp.c index b41c60a..eb9d261 100644 --- a/net/slirp.c +++ b/net/slirp.c @@ -32,6 +32,9 @@ #include "monitor.h" #include "sysemu.h" #include

[Qemu-devel] [PATCH v3 01/12] QObject API: add qdict_to_qstring() function

2010-04-15 Thread Miguel Di Ciurcio Filho
This is a helper function that converts a QDict to a QString, using the format: key1=value1 SPACE key2=value2 SPACE key3=value3 Handy for debugging and other things. Signed-off-by: Miguel Di Ciurcio Filho --- qdict.c | 41 + qdict.h |3 +++ 2 files

[Qemu-devel] [PATCH v3 02/12] net: add qemu_nic_format_info_dict and VLANClientState->info_dict

2010-04-15 Thread Miguel Di Ciurcio Filho
There is no standard format when formatting VLANClientState.info_str, so it is difficult to extract information and transmit it over QMP. This patch adds info_dict, a QDict to better handle the information of a NIC. Patches that convert the devices to use this new function will follow. Signed-of

[Qemu-devel] [PATCH v3 00/12] Convert do_info_network() to QObject/QMP

2010-04-15 Thread Miguel Di Ciurcio Filho
The VLANClientState structure has the member info_str, a simple string that is filled with information about NIC devices and used on monitor calls. There is no coherent formatting of this string by all the NIC devices, making it difficult to parse and represent this information over QMP. Patch 01

Re: [Qemu-devel] [PATCH v3 03/12] net: eepro100: replace qemu_format_nic_info_str by qemu_format_nic_info_dict

2010-04-15 Thread Richard Henderson
On 04/15/2010 07:06 AM, Miguel Di Ciurcio Filho wrote: Signed-off-by: Miguel Di Ciurcio Filho --- hw/eepro100.c | 10 -- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 7db6fb5..457bda8 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c

Re: [Qemu-devel] sparc-linux-usermode broken after latest pull

2010-04-15 Thread Blue Swirl
On 4/15/10, David Munday wrote: > Hello, > Our lab just did a pull from the qemu repository and now we are unable to > run a 32-bit sparc target on a 64-bit host. This functionality was working > before we did the pull. The error message we get is:mmap: No such device or > address > > And the

[Qemu-devel] Re: [RfC PATCH 08/11] spice: add qxl device

2010-04-15 Thread Blue Swirl
On 4/15/10, Paolo Bonzini wrote: > On 04/14/2010 06:52 PM, Blue Swirl wrote: > > > On 4/14/10, Gerd Hoffmann wrote: > > > > > +static inline void atomic_or(uint32_t *var, uint32_t add) > > > +{ > > > + __asm__ __volatile__ ("lock; orl %1, %0" : "+m" (*var) : "r" (add) > : "memory"); > > > +

[Qemu-devel] Re: sparc32 FPU SP Invalid CEXC Test

2010-04-15 Thread Blue Swirl
On 4/15/10, Artyom Tarasenko wrote: > 2010/4/15 Artyom Tarasenko : > > > One of LX's tests crashes pretty hard, causing qemu abort. > > I've tried to look how does the execution flow works with -d in_asm. > > Does the address in the log show the guest's PC register? > > > It's probably sort of a

[Qemu-devel] Guest latency issues due to bdrv_check_byte_request

2010-04-15 Thread Jan Kiszka
Hi, we are facing sporadic latency issue in our guests due to the synchronous nature of bdrv_check_byte_request on raw images: #0 0x7ff8962e2070 in lseek64 () from /lib64/libpthread.so.0 #1 0x004d7f97 in raw_getlength (bs=0xcab010) at block/raw-posix.c:704 #2 0x004b9d22 in

[Qemu-devel] [PATCH 0/3] Compile some files only once

2010-04-15 Thread Blue Swirl
I think Paolo's approach can work even with vl.c including kvm.h, provided that kvm.h remains such that it can be used safely. The situation is a bit fragile though. Some kind of poisoning, splitting kvm.h into two files, or other means should be used to make kvm.h more robust. Blue Swirl (2):

[Qemu-devel] [PATCH 1/3] provide a stub version of kvm-all.c if !CONFIG_KVM

2010-04-15 Thread Blue Swirl
This allows limited use of kvm functions (which will return ENOSYS) even in once-compiled modules. The patch also improves a bit the error messages for KVM initialization. Signed-off-by: Paolo Bonzini Signed-off-by: Blue Swirl --- Makefile.target |2 + kvm-all.c |6 ++- kvm-stub.

[Qemu-devel] [PATCH 2/3] Compile vl.c once

2010-04-15 Thread Blue Swirl
Since kvm.h can be used in files compiled once, we can partially revert b33612d03540fda7fa67485f1c20395beb7a2bf0. Signed-off-by: Blue Swirl --- Makefile.objs |2 +- Makefile.target |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile.objs b/Makefile.objs index

[Qemu-devel] [PATCH 3/3] Compile event_notifier only once

2010-04-15 Thread Blue Swirl
Signed-off-by: Blue Swirl --- Makefile.objs |2 +- Makefile.target |1 - 2 files changed, 1 insertions(+), 2 deletions(-) diff --git a/Makefile.objs b/Makefile.objs index c0fe5e2..c3864d0 100644 --- a/Makefile.objs +++ b/Makefile.objs @@ -104,7 +104,7 @@ common-obj-$(CONFIG_VNC_TLS) +=

Re: [Qemu-devel] sparc-linux-usermode broken after latest pull

2010-04-15 Thread Blue Swirl
On 4/15/10, Gabriel Southern wrote: > On Thu, Apr 15, 2010 at 9:33 AM, Blue Swirl wrote: > > On 4/15/10, David Munday wrote: > >> Hello, > >> Our lab just did a pull from the qemu repository and now we are unable > to run a 32-bit sparc target on a 64-bit host. This functionality was workin

Re: [Qemu-devel] Re: [RfC PATCH 08/11] spice: add qxl device

2010-04-15 Thread Richard Henderson
On 04/15/2010 11:47 AM, Blue Swirl wrote: On 4/15/10, Paolo Bonzini wrote: On 04/14/2010 06:52 PM, Blue Swirl wrote: On 4/14/10, Gerd Hoffmann wrote: +static inline void atomic_or(uint32_t *var, uint32_t add) +{ + __asm__ __volatile__ ("lock; orl %1, %0" : "+m" (*var) : "r" (add)

Re: [Qemu-devel] sparc-linux-usermode broken after latest pull

2010-04-15 Thread Gabriel Southern
On Thu, Apr 15, 2010 at 9:33 AM, Blue Swirl wrote: > On 4/15/10, David Munday wrote: >> Hello, >>  Our lab just did a pull from the qemu repository and now we are unable to >> run a 32-bit sparc target on a 64-bit host. This functionality was working >> before we did the pull. The error message

[Qemu-devel] Re: sparc32 FPU SP Invalid CEXC Test

2010-04-15 Thread Artyom Tarasenko
2010/4/15 Blue Swirl : > On 4/15/10, Artyom Tarasenko wrote: >> 2010/4/15 Artyom Tarasenko : >> >> > One of LX's tests crashes pretty hard, causing qemu abort. >>  > I've tried to look how does the execution flow works with -d in_asm. >>  > Does the address in the log show the guest's PC register?

[Qemu-devel] sparc32 FPU SP Invalid CEXC Test

2010-04-15 Thread Artyom Tarasenko
One of LX's tests crashes pretty hard, causing qemu abort. I've tried to look how does the execution flow works with -d in_asm. Does the address in the log show the guest's PC register? If so it looks strange: 0x70002d8c: fadds %f1, %f2, %f3 0x70002d90: st %f3, [ %l4 ] 0x70002d94: nop 0x70002

[Qemu-devel] Re: sparc32 FPU SP Invalid CEXC Test

2010-04-15 Thread Artyom Tarasenko
2010/4/15 Artyom Tarasenko : > One of LX's tests crashes pretty hard, causing qemu abort. > I've tried to look how does the execution flow works with -d in_asm. > Does the address in the log show the guest's PC register? It's probably sort of a "timing" issue. Can we check exceptions not just on

[Qemu-devel] [PATCH] flush TB on singlestep command

2010-04-15 Thread Jun Koi
(Thanks to Jan for comments on the last patch) Qemu has a command named singlestep, which reduces the translated code block to be only one instruction. However, there is one flaw when this command is triggered via monitor interface: we do not flush all the current TBs, so we will miss single-step

[Qemu-devel] TLB entry with separate addr_{read|write|code}?

2010-04-15 Thread Jun Koi
Hi, In the TLB entry, why do we need to maintain separately addr_read, addr_write and addr_code? Is it impossible to have only one for all the purposes? As far as I can see in tlb_set_page(), these fields are mutually exclusive, as they either enable or get invalid value (-1). Thanks, Jun

[Qemu-devel] [PATCH] ehci: fix infinite loop with usb netdevice

2010-04-15 Thread David S. Ahern
Hi Jan: The attached addresses the spinning with the usb net device. Now I can enable the device and ethtool shows a link: # ifconfig usb0 up # ethtool usb0 Settings for usb0: Current message level: 0x0007 (7) Link detected: yes Though dhclient still can't get an address. Aft

[Qemu-devel] Re: TLB entry with separate addr_{read|write|code}?

2010-04-15 Thread Jun Koi
On Fri, Apr 16, 2010 at 11:49 AM, Jun Koi wrote: > Hi, > > In the TLB entry, why do we need to maintain separately addr_read, > addr_write and addr_code? Is it impossible to have only one for all > the purposes? > > As far as I can see in tlb_set_page(), these fields are mutually > exclusive, as t

[Qemu-devel] Which functions writes to memory?

2010-04-15 Thread Jun Koi
Hi, I am writing a small tool to trace all the activities that write to an area of (virtual) memory in Qemu. I am currently doing that by putting my code at the top of the below macro in softmmu_header.h static inline void glue(glue(st, SUFFIX), MEMSUFFIX) However, it seems I still miss some

Re: [Qemu-devel] Which functions writes to memory?

2010-04-15 Thread malc
On Fri, 16 Apr 2010, Jun Koi wrote: > Hi, > > I am writing a small tool to trace all the activities that write to an > area of (virtual) memory in Qemu. > I am currently doing that by putting my code at the top of the below > macro in softmmu_header.h > > static inline void glue(glue(st, SUFFIX)