[Qemu-devel] KVM call agenda for Jan 19

2010-01-18 Thread Chris Wright
Please send in any agenda items you are interested in covering in tomorrow's call. thanks, -chris

[Qemu-devel] [PATCH] sparc64: reimplement tick timers v2

2010-01-18 Thread Igor V. Kovalenko
From: Igor V. Kovalenko sparc64 timer has tick counter which can be set and read, and tick compare value used as deadline to fire timer interrupt. The timer is not used as periodic timer, instead deadline is set each time new timer interrupt is needed. v1 -> v2: - new conversion helpers cpu_to_t

[Qemu-devel] Re: [PATCHv2 0/3] rwhandler: introduce and switch pci_host to it

2010-01-18 Thread Blue Swirl
On Mon, Jan 18, 2010 at 7:41 PM, Michael S. Tsirkin wrote: > On Mon, Jan 18, 2010 at 07:53:25PM +0200, Michael S. Tsirkin wrote: >> On Mon, Jan 18, 2010 at 05:50:35PM +, Blue Swirl wrote: >> > On Mon, Jan 18, 2010 at 10:56 AM, Michael S. Tsirkin >> > wrote: >> > > Alexander, so I assume the

[Qemu-devel] Re: [PATCH 1/6] Make config space accessor host bus trapable

2010-01-18 Thread Blue Swirl
On Tue, Jan 12, 2010 at 7:29 PM, Blue Swirl wrote: > On Mon, Jan 11, 2010 at 10:33 PM, Igor Kovalenko > wrote: >> On Tue, Jan 12, 2010 at 12:29 AM, Blue Swirl wrote: >>> On Sun, Jan 10, 2010 at 6:41 PM, Blue Swirl wrote: On Sun, Jan 3, 2010 at 7:18 PM, Blue Swirl wrote: > On Sun, Jan

[Qemu-devel] Re: [PATCHv2 0/3] rwhandler: introduce and switch pci_host to it

2010-01-18 Thread Michael S. Tsirkin
On Mon, Jan 18, 2010 at 07:53:25PM +0200, Michael S. Tsirkin wrote: > On Mon, Jan 18, 2010 at 05:50:35PM +, Blue Swirl wrote: > > On Mon, Jan 18, 2010 at 10:56 AM, Michael S. Tsirkin > > wrote: > > > Alexander, so I assume the following patchset should be enough for you > > > to implement u3

Re: [Qemu-devel] [PATCH] Documentation: Add missing documentation for qdev related command line options

2010-01-18 Thread Stefan Weil
Markus Armbruster schrieb: > Stefan Weil writes: > >> The command line options -device, -nodefaults, -readconfig, >> -writeconfig had entries for command line help, but >> documentation for texi and derived formats (man, html, info) >> was missing. >> >> This also required moving "@end table" to t

[Qemu-devel] Re: [PATCHv2 0/3] rwhandler: introduce and switch pci_host to it

2010-01-18 Thread Michael S. Tsirkin
On Mon, Jan 18, 2010 at 05:50:35PM +, Blue Swirl wrote: > On Mon, Jan 18, 2010 at 10:56 AM, Michael S. Tsirkin wrote: > > Alexander, so I assume the following patchset should be enough for you > > to implement u3 support, simply by creating your own rwhandler, and > > using pci_data_read/write

[Qemu-devel] Re: virtio: Add memory statistics reporting to the balloon driver (V7)

2010-01-18 Thread Adam Litke
On Mon, 2010-01-18 at 12:12 -0200, Luiz Capitulino wrote: > On Fri, 15 Jan 2010 13:54:29 -0600 > Adam Litke wrote: > > > This version improves support for multiple monitors and has been ported up > > to > > HEAD as of 01/14. > > Overall review on the Monitor related changes seems ok, but I'm n

[Qemu-devel] Re: [PATCHv2 0/3] rwhandler: introduce and switch pci_host to it

2010-01-18 Thread Blue Swirl
On Mon, Jan 18, 2010 at 10:56 AM, Michael S. Tsirkin wrote: > Alexander, so I assume the following patchset should be enough for you > to implement u3 support, simply by creating your own rwhandler, and > using pci_data_read/write directly there. I have pushed it to a > temporary branch in my tree

Re: [Qemu-devel] [PATCH] Improve error reporting on file access

2010-01-18 Thread Markus Armbruster
Andreas Färber writes: > Hello, > > Am 27.10.2009 um 18:38 schrieb malc: > >> On Tue, 27 Oct 2009, Markus Armbruster wrote: >> >>> Mark McLoughlin writes: >>> On Thu, 2009-10-01 at 09:42 -0500, Justin M. Forbes wrote: > Author: Justin M. Forbes > Date: Thu Oct 1 09:34:56 2009 -05

[Qemu-devel] Re: sparc32 do_unassigned_access overhaul v2

2010-01-18 Thread Blue Swirl
On Mon, Jan 18, 2010 at 4:17 PM, Artyom Tarasenko wrote: > Btw, what is the following hack for in do_unassigned_access? > > >    saved_env = env; >    env = cpu_single_env; > //... >    env = saved_env; env is a host CPU register, see for example target-sparc/exec.h. Code which is called directly

Re: [Qemu-devel] [PATCH v1 0/5]: Convert pci_info() to QObject

2010-01-18 Thread Markus Armbruster
Luiz Capitulino writes: > Hi, > > This is a new version of the pci_info() conversion. > > changelog > - > > V0 -> V1 > > - Coding style fixes > - Make 'BAR' and 'IRQ' keys lowercase > - Add 'irq' key to the documentation > > Thanks. PATCH 3/5 regresses info pci, 4/5 and 5/5 fix it. D

Re: [Qemu-devel] [PATCH 3/5] PCI: Convert pci_info() to QObject

2010-01-18 Thread Markus Armbruster
Luiz Capitulino writes: > The returned QObject is a QList of all buses. Each bus is > represented by a QDict, which has a key with a QList of all > PCI devices attached to it. Each device is represented by > a QDict. > > IMPORTANT: support for printing PCI bridge information and > its devices is

Re: [Qemu-devel] [PATCH 4/5] PCI: do_pci_info(): PCI bridge support

2010-01-18 Thread Markus Armbruster
Luiz Capitulino writes: > This commit adds the "pci_bridge" key to the PCI device QDict, > it also adds support for printing it in the user protocol. > > IMPORTANT: This code is being added separately because I could > NOT test it properly. According to Michael Tsirkin, it depends > on ultrasparc

[Qemu-devel] [PATCH] Add definitions for current cpu models..

2010-01-18 Thread john cooper
This is a rework of the prior version which adds definitions for contemporary processors selected via -cpu , as an alternative to the existing use of "-cpu qemu64" augmented with a series of feature flags. The primary motivation was determination of a least common denominator within a given proces

Re: [Qemu-devel] [PATCH 2/6] QError: New QERR_FOPEN_FAILED

2010-01-18 Thread Luiz Capitulino
On Mon, 18 Jan 2010 15:52:13 +0100 Markus Armbruster wrote: > Luiz Capitulino writes: > > > On Fri, 15 Jan 2010 17:25:25 +0100 > > Markus Armbruster wrote: > > > >> > >> Signed-off-by: Markus Armbruster > >> --- > >> qerror.c |4 > >> qerror.h |3 +++ > >> 2 files changed, 7 in

[Qemu-devel] Extend ARM IO to connect to real hardware?

2010-01-18 Thread Wilfried Holzke
Hi, Is it possible to extend to qemu (ARM) to run code which connects to real hardware? If yes, where do I hook in? Thanks for hints =). regards Wilfried

[Qemu-devel] Re: sparc32 do_unassigned_access overhaul v2

2010-01-18 Thread Artyom Tarasenko
Btw, what is the following hack for in do_unassigned_access? saved_env = env; env = cpu_single_env; //... env = saved_env; I wonder whether I modify the correct env here: env = saved_env; +/* flush neverland mappings created during no-fault mode, + so the sequential MM

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Avi Kivity
On 01/18/2010 06:08 PM, Michael S. Tsirkin wrote: On Mon, Jan 18, 2010 at 06:04:40PM +0200, Avi Kivity wrote: On 01/18/2010 05:45 PM, Michael S. Tsirkin wrote: cpu_register_physical_memory_offset already is O(memory size) btw. Right, but we'd like to replace it with a range

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Michael S. Tsirkin
On Mon, Jan 18, 2010 at 06:04:40PM +0200, Avi Kivity wrote: > On 01/18/2010 05:45 PM, Michael S. Tsirkin wrote: >> >> cpu_register_physical_memory_offset already is O(memory size) btw. >> > > Right, but we'd like to replace it with a range API. So, when we do the implementation of notifiers ca

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Avi Kivity
On 01/18/2010 05:45 PM, Michael S. Tsirkin wrote: cpu_register_physical_memory_offset already is O(memory size) btw. Right, but we'd like to replace it with a range API. Maybe we mandate clients be registered at init-time? This might be tricky - vhost currently only regis

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Michael S. Tsirkin
On Mon, Jan 18, 2010 at 04:52:10PM +0200, Avi Kivity wrote: > On 01/18/2010 04:44 PM, Michael S. Tsirkin wrote: >> >> The point is that clients can be registered at any point. A client that registered when memory is present needs to be notified about it. >>

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Michael S. Tsirkin
On Mon, Jan 18, 2010 at 04:52:10PM +0200, Avi Kivity wrote: > On 01/18/2010 04:44 PM, Michael S. Tsirkin wrote: >> >> The point is that clients can be registered at any point. A client that registered when memory is present needs to be notified about it. >>

Re: [Qemu-devel] [PATCH 2/6] QError: New QERR_FOPEN_FAILED

2010-01-18 Thread Markus Armbruster
Luiz Capitulino writes: > On Fri, 15 Jan 2010 17:25:25 +0100 > Markus Armbruster wrote: > >> >> Signed-off-by: Markus Armbruster >> --- >> qerror.c |4 >> qerror.h |3 +++ >> 2 files changed, 7 insertions(+), 0 deletions(-) >> >> diff --git a/qerror.c b/qerror.c >> index 5f8fc5d

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Avi Kivity
On 01/18/2010 04:44 PM, Michael S. Tsirkin wrote: The point is that clients can be registered at any point. A client that registered when memory is present needs to be notified about it. It looks very expensive. Shouldn't be hard to optimize ... It's O(memory size),

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Michael S. Tsirkin
On Mon, Jan 18, 2010 at 03:58:51PM +0200, Avi Kivity wrote: > On 01/18/2010 03:52 PM, Michael S. Tsirkin wrote: >> On Mon, Jan 18, 2010 at 03:02:59PM +0200, Avi Kivity wrote: >> >>> On 01/04/2010 09:49 PM, Michael S. Tsirkin wrote: >>> This adds notifiers for phys memory changes: a s

Re: [Qemu-devel] [PATCH 2/6] QError: New QERR_FOPEN_FAILED

2010-01-18 Thread Luiz Capitulino
On Mon, 18 Jan 2010 12:23:28 -0200 Luiz Capitulino wrote: > On Fri, 15 Jan 2010 17:25:25 +0100 > Markus Armbruster wrote: > > > > > Signed-off-by: Markus Armbruster > > --- > > qerror.c |4 > > qerror.h |3 +++ > > 2 files changed, 7 insertions(+), 0 deletions(-) > > > > diff -

Re: [Qemu-devel] [PATCH 2/6] QError: New QERR_FOPEN_FAILED

2010-01-18 Thread Luiz Capitulino
On Fri, 15 Jan 2010 17:25:25 +0100 Markus Armbruster wrote: > > Signed-off-by: Markus Armbruster > --- > qerror.c |4 > qerror.h |3 +++ > 2 files changed, 7 insertions(+), 0 deletions(-) > > diff --git a/qerror.c b/qerror.c > index 5f8fc5d..e7b8ca7 100644 > --- a/qerror.c > +++

[Qemu-devel] Re: virtio: Add memory statistics reporting to the balloon driver (V7)

2010-01-18 Thread Luiz Capitulino
On Fri, 15 Jan 2010 13:54:29 -0600 Adam Litke wrote: > This version improves support for multiple monitors and has been ported up to > HEAD as of 01/14. Overall review on the Monitor related changes seems ok, but I'm not sure how I should enable it.

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Avi Kivity
On 01/18/2010 03:52 PM, Michael S. Tsirkin wrote: On Mon, Jan 18, 2010 at 03:02:59PM +0200, Avi Kivity wrote: On 01/04/2010 09:49 PM, Michael S. Tsirkin wrote: This adds notifiers for phys memory changes: a set of callbacks that vhost can register and update kernel accordingly. Down

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Michael S. Tsirkin
On Mon, Jan 18, 2010 at 03:02:59PM +0200, Avi Kivity wrote: > On 01/04/2010 09:49 PM, Michael S. Tsirkin wrote: >> This adds notifiers for phys memory changes: a set of callbacks that >> vhost can register and update kernel accordingly. Down the road, kvm >> code can be switched to use these as we

[Qemu-devel] Please remove from mailing-list

2010-01-18 Thread Chip Panarchy
Hi Sorry about this post, tried removing myself from this list about a week ago, yet I keep getting messages. Please remove from list Thanks in advance, Panarchy

Re: [Qemu-devel] [PATCHv2 1/3] qemu: memory notifiers

2010-01-18 Thread Avi Kivity
On 01/04/2010 09:49 PM, Michael S. Tsirkin wrote: This adds notifiers for phys memory changes: a set of callbacks that vhost can register and update kernel accordingly. Down the road, kvm code can be switched to use these as well, instead of calling kvm code directly from exec.c as is done now.

Re: [Qemu-devel] [RFC, PATCH 10/11] qdev: Add do_info_qbus and friends.

2010-01-18 Thread Gerd Hoffmann
On 01/18/10 13:34, Markus Armbruster wrote: However, because there are both device properties and bus properties (really: device properties common to all devices on this bus), their names can clash. Device properties take precedence (see qdev_prop_find()). Hmm, qdev_printf() prints even overrid

Re: [Qemu-devel] Re: [PATCH v2 2/4] Clean-up a little bit the RW related bits of BDRV_O_FLAGS. BDRV_O_RDONLY gone (and so is BDRV_O_ACCESS). Default value for bdrv_flags (0/zero) is READ-ONLY. Need to

2010-01-18 Thread Markus Armbruster
"Michael S. Tsirkin" writes: > On Mon, Jan 18, 2010 at 11:34:59AM +0100, Markus Armbruster wrote: >> "Michael S. Tsirkin" writes: >> >> > On Sun, Jan 17, 2010 at 04:48:13PM +0200, Naphtali Sprei wrote: >> >> Instead of using the field 'readonly' of the BlockDriverState struct for >> >> passing

Re: [Qemu-devel] [RFC,PATCH 08/11] qdev: Add usb_bus_dev_info

2010-01-18 Thread Markus Armbruster
Gerd Hoffmann writes: > On 01/18/10 11:15, Markus Armbruster wrote: >> Nathan Baum writes: >> > +static QObject *usb_bus_dev_info(Monitor *mon, DeviceState *qdev) > +{ > +USBDevice *dev = DO_UPCAST(USBDevice, qdev, qdev); > +USBBus *bus = usb_bus_from_device(dev); > +

Re: [Qemu-devel] [RFC, PATCH 10/11] qdev: Add do_info_qbus and friends.

2010-01-18 Thread Markus Armbruster
Gerd Hoffmann writes: >> However, because there are both device properties and bus properties >> (really: device properties common to all devices on this bus), their >> names can clash. Device properties take precedence (see >> qdev_prop_find()). Hmm, qdev_printf() prints even overridden bus >>

[Qemu-devel] [PATCH 09/10] qcow2: Don't ignore update_refcount return value

2010-01-18 Thread Kevin Wolf
update_refcount can return errors that need to be handled by the callers. Signed-off-by: Kevin Wolf --- block/qcow2-refcount.c | 31 +++ 1 files changed, 23 insertions(+), 8 deletions(-) diff --git a/block/qcow2-refcount.c b/block/qcow2-refcount.c index 3dfadf1..b9

[Qemu-devel] [PATCH 10/10] qcow2: Don't ignore qcow2_alloc_clusters return value

2010-01-18 Thread Kevin Wolf
Now that qcow2_alloc_clusters can return error codes, we must handle them in the callers of qcow2_alloc_clusters. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 18 -- block/qcow2-refcount.c |6 ++ block/qcow2-snapshot.c | 11 ++- 3 files changed, 32 i

[Qemu-devel] [PATCH 08/10] qcow2: Allow updating no refcounts

2010-01-18 Thread Kevin Wolf
There's absolutely no problem with updating the refcounts of 0 clusters. At least snapshot code is doing this and would fail once the result of update_refcount isn't ignored any more. Signed-off-by: Kevin Wolf --- block/qcow2-refcount.c |4 +++- 1 files changed, 3 insertions(+), 1 deletions(

[Qemu-devel] [PATCH 07/10] qcow2: Improve error handling in update_refcount

2010-01-18 Thread Kevin Wolf
If update_refcount fails, try to undo any changes made so far to avoid inconsistencies in the image file. Signed-off-by: Kevin Wolf --- block/qcow2-refcount.c | 32 +--- 1 files changed, 25 insertions(+), 7 deletions(-) diff --git a/block/qcow2-refcount.c b/block/q

[Qemu-devel] [PATCH 05/10] block: Return original error codes in bdrv_pread/write

2010-01-18 Thread Kevin Wolf
Don't assume -EIO but return the real error. Signed-off-by: Kevin Wolf --- block.c | 34 ++ 1 files changed, 18 insertions(+), 16 deletions(-) diff --git a/block.c b/block.c index 115e591..a4c4953 100644 --- a/block.c +++ b/block.c @@ -717,6 +717,7 @@ int bdrv_

[Qemu-devel] [PATCH 06/10] qcow2: Fix error handling in grow_refcount_table

2010-01-18 Thread Kevin Wolf
Return the appropriate error code instead of -EIO. Signed-off-by: Kevin Wolf --- block/qcow2-refcount.c |9 ++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/block/qcow2-refcount.c b/block/qcow2-refcount.c index 3a2d44a..6f449c6 100644 --- a/block/qcow2-refcount.c +++

[Qemu-devel] [PATCH 03/10] qcow2: Return 0/-errno in get_cluster_table

2010-01-18 Thread Kevin Wolf
Switching to 0/-errno allows it to distinguish different error cases. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 30 ++ 1 files changed, 18 insertions(+), 12 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c index adddf56..424bedd 1

[Qemu-devel] [PATCH 04/10] qcow2: Return 0/-errno in qcow2_alloc_cluster_offset

2010-01-18 Thread Kevin Wolf
Returning 0/-errno allows it to distingush different errors classes. The cluster offset of newly allocated clusters is now returned in the QCowL2Meta struct. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 28 ++-- block/qcow2.c | 36 +++-

[Qemu-devel] [PATCH 02/10] qcow2: Fix error handling in qcow_save_vmstate

2010-01-18 Thread Kevin Wolf
Don't assume success but pass the bdrv_pwrite return value on. Signed-off-by: Kevin Wolf --- block/qcow2.c |5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/block/qcow2.c b/block/qcow2.c index 6622eba..e06f4dd 100644 --- a/block/qcow2.c +++ b/block/qcow2.c @@ -1163,12

[Qemu-devel] [PATCH 01/10] qcow2: Fix error handling in qcow2_grow_l1_table

2010-01-18 Thread Kevin Wolf
Return the appropriate error value instead of always using EIO. Don't free the L1 table on errors, we still need it. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c |8 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c i

[Qemu-devel] [PATCH 00/10] qcow2 error path fixes

2010-01-18 Thread Kevin Wolf
In qcow2 (and partly also in general block code), error handling doesn't quite do what it should. In some places, errors are silently ignored. In other places, the error code in not passed to the called but rather turned into false, NULL or -EIO. Besides reporting the right error to the user, provi

[Qemu-devel] Re: [PATCH v2 4/4] Disable fall-back to read-only when cannot open drive's file for read-write

2010-01-18 Thread Naphtali Sprei
Michael S. Tsirkin wrote: > On Sun, Jan 17, 2010 at 04:48:15PM +0200, Naphtali Sprei wrote: >> Signed-off-by: Naphtali Sprei >> --- >> block.c |6 -- >> 1 files changed, 0 insertions(+), 6 deletions(-) >> >> diff --git a/block.c b/block.c >> index 8def3c4..f90e983 100644 >> --- a/block.c

[Qemu-devel] Re: [PATCH] Check for sdl-config before calling it

2010-01-18 Thread Paolo Bonzini
On 01/17/2010 05:06 PM, Loïc Minier wrote: On Sun, Jan 17, 2010, Stefan Weil wrote: On systems were sdl-config isn't installed, ./configure triggers this warning: ./configure: 957: sdl-config: not found which version did you test? Git master has no sdl-config call at configure:957. But I get

[Qemu-devel] Re: [PATCH v2 2/4] Clean-up a little bit the RW related bits of BDRV_O_FLAGS. BDRV_O_RDONLY gone (and so is BDRV_O_ACCESS). Default value for bdrv_flags (0/zero) is READ-ONLY. Need to exp

2010-01-18 Thread Naphtali Sprei
Michael S. Tsirkin wrote: > On Sun, Jan 17, 2010 at 04:48:13PM +0200, Naphtali Sprei wrote: >> Instead of using the field 'readonly' of the BlockDriverState struct for >> passing the request, >> pass the request in the flags parameter to the function. >> >> Signed-off-by: Naphtali Sprei > > Many

[Qemu-devel] Re: [PATCH][STABLE] Drop debug printfs from qemu_chr_parse_compat

2010-01-18 Thread Gerd Hoffmann
While you are at it, can you also zap this debug leftover? Looks like there are three of them in qemu_chr_parse_compat - kill them all? Yes. thanks, Gerd Signed-off-by: Jan Kiszka Acked-by: Gerd Hoffmann -fprintf(stderr, "udp #1\n"); -fprintf(std

[Qemu-devel] [PATCH][STABLE] Drop debug printfs from qemu_chr_parse_compat

2010-01-18 Thread Jan Kiszka
Gerd Hoffmann wrote: > On 01/18/10 11:21, Jan Kiszka wrote: >> Gerd Hoffmann wrote: >>> On 01/15/10 21:07, Jan Kiszka wrote: The missing '@' broke 'udp::@:' parsing. >>> if (sscanf(p, "%64[^:]:%32[^@,]%n", host, port,&pos)< 2) { host[0] = 0; -

[Qemu-devel] [PATCHv2 3/3] pci_host: rewrite using rwhandler

2010-01-18 Thread Michael S. Tsirkin
Save a ton of code by switching pcihost to use rwhandler. Signed-off-by: Michael S. Tsirkin --- hw/pci_host.c | 172 +++ hw/pci_host.h |4 + hw/pci_host_template.h | 109 -- 3 files changed, 74 insert

[Qemu-devel] [PATCHv2 2/3] rwhandler: simplified way to register for mem/io

2010-01-18 Thread Michael S. Tsirkin
Some users prefer a single callback with length passed as parameter to using b/w/l callbacks. It would maybe be cleaner to just pass length to existing callbacks but that's a lot of churn. So for now add a wrapper. For convenience use uint64_t for address so a single callback can be used for iopor

[Qemu-devel] [PATCHv2 1/3] bwap: add qemu_bswap helper

2010-01-18 Thread Michael S. Tsirkin
add helper that can swap values of 4, 2, 1 bytes Signed-off-by: Michael S. Tsirkin --- bswap.h |6 ++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/bswap.h b/bswap.h index 4558704..aace9b7 100644 --- a/bswap.h +++ b/bswap.h @@ -214,4 +214,10 @@ static inline void cpu_to_

[Qemu-devel] [PATCHv2 0/3] rwhandler: introduce and switch pci_host to it

2010-01-18 Thread Michael S. Tsirkin
Alexander, so I assume the following patchset should be enough for you to implement u3 support, simply by creating your own rwhandler, and using pci_data_read/write directly there. I have pushed it to a temporary branch in my tree: git://git.kernel.org/pub/scm/linux/kernel/git/mst/qemu.git rwhandle

Re: [Qemu-devel] Re: [PATCH v2 2/4] Clean-up a little bit the RW related bits of BDRV_O_FLAGS. BDRV_O_RDONLY gone (and so is BDRV_O_ACCESS). Default value for bdrv_flags (0/zero) is READ-ONLY. Need to

2010-01-18 Thread Michael S. Tsirkin
On Mon, Jan 18, 2010 at 11:34:59AM +0100, Markus Armbruster wrote: > "Michael S. Tsirkin" writes: > > > On Sun, Jan 17, 2010 at 04:48:13PM +0200, Naphtali Sprei wrote: > >> Instead of using the field 'readonly' of the BlockDriverState struct for > >> passing the request, > >> pass the request in

Re: [Qemu-devel] [PATCH][STABLE] Fix corner case in chardev udp: parameter

2010-01-18 Thread Gerd Hoffmann
On 01/18/10 11:21, Jan Kiszka wrote: Gerd Hoffmann wrote: On 01/15/10 21:07, Jan Kiszka wrote: The missing '@' broke 'udp::@:' parsing. if (sscanf(p, "%64[^:]:%32[^@,]%n", host, port,&pos)< 2) { host[0] = 0; -if (sscanf(p, ":%32[^,]%n", port,&pos)< 1

Re: [Qemu-devel] [RFC, PATCH 10/11] qdev: Add do_info_qbus and friends.

2010-01-18 Thread Gerd Hoffmann
However, because there are both device properties and bus properties (really: device properties common to all devices on this bus), their names can clash. Device properties take precedence (see qdev_prop_find()). Hmm, qdev_printf() prints even overridden bus properties, not sure that's appropria

Re: [Qemu-devel] [RFC,PATCH 08/11] qdev: Add usb_bus_dev_info

2010-01-18 Thread Gerd Hoffmann
On 01/18/10 11:15, Markus Armbruster wrote: Nathan Baum writes: +static QObject *usb_bus_dev_info(Monitor *mon, DeviceState *qdev) +{ +USBDevice *dev = DO_UPCAST(USBDevice, qdev, qdev); +USBBus *bus = usb_bus_from_device(dev); +return qobject_from_jsonf("{'busnr': %d, 'addr':%d, 's

Re: [Qemu-devel] Re: [PATCH v2 2/4] Clean-up a little bit the RW related bits of BDRV_O_FLAGS. BDRV_O_RDONLY gone (and so is BDRV_O_ACCESS). Default value for bdrv_flags (0/zero) is READ-ONLY. Need to

2010-01-18 Thread Markus Armbruster
"Michael S. Tsirkin" writes: > On Sun, Jan 17, 2010 at 04:48:13PM +0200, Naphtali Sprei wrote: >> Instead of using the field 'readonly' of the BlockDriverState struct for >> passing the request, >> pass the request in the flags parameter to the function. >> >> Signed-off-by: Naphtali Sprei > >

Re: [Qemu-devel] [PATCH][STABLE] Fix corner case in chardev udp: parameter

2010-01-18 Thread Jan Kiszka
Gerd Hoffmann wrote: > On 01/15/10 21:07, Jan Kiszka wrote: >> The missing '@' broke 'udp::@:' parsing. > >> if (sscanf(p, "%64[^:]:%32[^@,]%n", host, port,&pos)< 2) { >> host[0] = 0; >> -if (sscanf(p, ":%32[^,]%n", port,&pos)< 1) { >> +if (sscanf(

Re: [Qemu-devel] [RFC,PATCH 08/11] qdev: Add usb_bus_dev_info

2010-01-18 Thread Markus Armbruster
Nathan Baum writes: > On Fri, 2010-01-15 at 19:14 +0100, Markus Armbruster wrote: >> Nathan Baum writes: >> >> > Returns a QObject with information about a USB device. >> > >> > Signed-off-by: Nathan Baum >> > --- >> > hw/usb-bus.c | 13 + >> > 1 files changed, 13 insertions(+),

Re: [Qemu-devel] [PATCH] Documentation: Add missing documentation for qdev related command line options

2010-01-18 Thread Markus Armbruster
Stefan Weil writes: > The command line options -device, -nodefaults, -readconfig, > -writeconfig had entries for command line help, but > documentation for texi and derived formats (man, html, info) > was missing. > > This also required moving "@end table" to the end of > qemu-options.hx again. >

Re: [Qemu-devel] [PATCH][STABLE] Fix corner case in chardev udp: parameter

2010-01-18 Thread Gerd Hoffmann
On 01/15/10 21:07, Jan Kiszka wrote: The missing '@' broke 'udp::@:' parsing. if (sscanf(p, "%64[^:]:%32[^@,]%n", host, port,&pos)< 2) { host[0] = 0; -if (sscanf(p, ":%32[^,]%n", port,&pos)< 1) { +if (sscanf(p, ":%32[^@,]%n", port,&pos)< 1) {