Re: [Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Jamie Lokier
Amit Shah wrote: > > Sure. Does the host app see an EOF on its input when that happens? > > (I.e. *not* like a real serial port). > > If it's an in-qemu app, it gets the guest_closed() callback. So I guess > qmp events for non-qemu apps is what you're looking for? See below. > > But what I real

Re: [Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Amit Shah
On (Fri) Mar 26 2010 [04:07:54], Jamie Lokier wrote: > Amit Shah wrote: > > On (Fri) Mar 26 2010 [01:17:49], Jamie Lokier wrote: > > > Luiz Capitulino wrote: > > > > On Thu, 25 Mar 2010 09:17:17 +0530 > > > > Amit Shah wrote: > > > > > > > > > On (Wed) Mar 24 2010 [17:34:15], Luiz Capitulino wrot

Re: [Qemu-devel] [PATCH 02/15] virtio-serial: save/load: Ensure nr_ports on src and dest are same.

2010-03-25 Thread Jamie Lokier
Amit Shah wrote: > On (Fri) Mar 26 2010 [01:09:23], Jamie Lokier wrote: > > Amit Shah wrote: > > > The number of ports on the source as well as the destination machines > > > should match. If they don't, it means some ports that got hotplugged on > > > the source aren't instantiated on the destinat

Re: [Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Jamie Lokier
Amit Shah wrote: > On (Fri) Mar 26 2010 [01:17:49], Jamie Lokier wrote: > > Luiz Capitulino wrote: > > > On Thu, 25 Mar 2010 09:17:17 +0530 > > > Amit Shah wrote: > > > > > > > On (Wed) Mar 24 2010 [17:34:15], Luiz Capitulino wrote: > > > > > On Wed, 24 Mar 2010 20:19:28 +0530 > > > > > Amit Shah

Re: [Qemu-devel] [patch 1/2] Pass QEMUIOWorker to qemu_notify_event

2010-03-25 Thread Marcelo Tosatti
On Thu, Mar 25, 2010 at 09:06:00PM +, Paul Brook wrote: > > /* Force QEMU to process pending events */ > > -void qemu_notify_event(void); > > +void qemu_notify_event(QEMUIOWorker *worker); > > > static void handle_input(VirtIODevice *vdev, VirtQueue *vq) > > { > > +qemu_notify_event(mai

Re: [Qemu-devel] Significant performance regression in qemu-system-mips.

2010-03-25 Thread Rob Landley
On Thursday 25 March 2010 18:57:00 Alexander Graf wrote: > > This has been broken in r680 of openbios. I haven't found time to find > > the real problem though. > > Ugh. > > Yeah, I really need to look into it again. It's probably something really > simple. 99% of the code was if(newworld) conditio

Re: [Qemu-devel] Supporting hypervisor specific APIs in libvirt

2010-03-25 Thread Jamie Lokier
Avi Kivity wrote: > On 03/23/2010 09:31 PM, Anthony Liguori wrote: > > > >> > >>One problem is that this is libvirt version specific. For example, > >>libvirt x doesn't support spice so we control that thorough qmp. But > >>libvirt x+1 does support spice and now it gets confused about all the

[Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Amit Shah
On (Thu) Mar 25 2010 [15:55:41], Luiz Capitulino wrote: > On Wed, 24 Mar 2010 20:19:28 +0530 > Amit Shah wrote: > > > When adding a port or a device to the guest fails, management software > > might be interested in knowing and then cleaning up the host-side of the > > port. Introduce QMP events

Re: [Qemu-devel] Re: [libvirt] Supporting hypervisor specific APIs in libvirt

2010-03-25 Thread Jamie Lokier
Anthony Liguori wrote: > I'm not sure. The human monitor has some features that are not > appropriate for QMP. For instance, the ability to deal with formula > input and some commands meant to add debugging. > > I guess you could do that in qemu-cmd but I don't see a compelling > reason to.

Re: [Qemu-devel] Re: [libvirt] Supporting hypervisor specific APIs in libvirt

2010-03-25 Thread Jamie Lokier
Anthony Liguori wrote: > On 03/25/2010 09:09 AM, Luiz Capitulino wrote: > > > >>We can provide a generic QMP dispatch interface that high level > >>languages can use. Then they can do fancy dispatch, treat QErrors as > >>exceptions, etc. > >> > > They can do that by accessing QMP directly. W

Re: [Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Amit Shah
On (Fri) Mar 26 2010 [01:17:49], Jamie Lokier wrote: > Luiz Capitulino wrote: > > On Thu, 25 Mar 2010 09:17:17 +0530 > > Amit Shah wrote: > > > > > On (Wed) Mar 24 2010 [17:34:15], Luiz Capitulino wrote: > > > > On Wed, 24 Mar 2010 20:19:28 +0530 > > > > Amit Shah wrote: > > > > > > > > > When

Re: [Qemu-devel] [PATCH 09/10] target-alpha: Implement load-locked/store-conditional properly.

2010-03-25 Thread Jamie Lokier
Richard Henderson wrote: > On 03/25/2010 06:39 AM, Nathan Froyd wrote: > > On Wed, Mar 24, 2010 at 05:11:43PM -0700, Richard Henderson wrote: > >> Use __sync_bool_compare_and_swap to yield correctly atomic results. > >> As yet, this assumes running on an strict-memory-ordering host (i.e. x86), > >>

Re: [Qemu-devel] [PATCH 02/15] virtio-serial: save/load: Ensure nr_ports on src and dest are same.

2010-03-25 Thread Amit Shah
On (Fri) Mar 26 2010 [01:09:23], Jamie Lokier wrote: > Amit Shah wrote: > > The number of ports on the source as well as the destination machines > > should match. If they don't, it means some ports that got hotplugged on > > the source aren't instantiated on the destination. Or that ports that > >

Re: [Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Amit Shah
On (Thu) Mar 25 2010 [15:34:06], Luiz Capitulino wrote: > On Thu, 25 Mar 2010 09:17:17 +0530 > Amit Shah wrote: > > > On (Wed) Mar 24 2010 [17:34:15], Luiz Capitulino wrote: > > > On Wed, 24 Mar 2010 20:19:28 +0530 > > > Amit Shah wrote: > > > > > > > When adding a port or a device to the guest

Re: [Qemu-devel] [PATCH 09/10] target-alpha: Implement load-locked/store-conditional properly.

2010-03-25 Thread Jamie Lokier
Richard Henderson wrote: > On 03/25/2010 10:40 AM, Blue Swirl wrote: > > Sparc V8 has two atomic instructions, ldstub and swap. > > I know -- but not the CAS operation being discussed here. > > As I think about this more and more, the Real Problem is > not with the CAS, but with the memory orderi

Re: [Qemu-devel] [PATCH 00/10, v3] target-alpha improvements

2010-03-25 Thread Jamie Lokier
Richard Henderson wrote: > I don't see how any sort of emulation of cmpxchg/load-locked is working > for any currently enabled nptl target. I think how I've approached > handling load-locked for alpha is probably the easiest way. Slightly > better would be if TCG had a (set of) cmpxchg opcodes, w

Re: [Qemu-devel] Re: [PATCH v3 0/2] Inter-VM shared memory PCI device

2010-03-25 Thread Jamie Lokier
Cam Macdonell wrote: > An irqfd can only trigger a single vector in a guest. Right now I > only have one eventfd per guest.So ioeventfd/irqfd restricts the > current implementation to a single vector that a guest can trigger. > Without irqfd, eventfds can be used like registers a write the num

Re: [Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Jamie Lokier
Luiz Capitulino wrote: > On Thu, 25 Mar 2010 09:17:17 +0530 > Amit Shah wrote: > > > On (Wed) Mar 24 2010 [17:34:15], Luiz Capitulino wrote: > > > On Wed, 24 Mar 2010 20:19:28 +0530 > > > Amit Shah wrote: > > > > > > > When adding a port or a device to the guest fails, management software > > >

Re: [Qemu-devel] TBL register permissions for PPC

2010-03-25 Thread Alexander Graf
On 26.03.2010, at 01:31, Dmitry Ilyevsky wrote: > On Thu, Mar 25, 2010 at 10:53 AM, Alexander Graf wrote: >> >> On 24.03.2010, at 22:56, Dmitry Ilyevsky wrote: >> >>> >>> Hello All, >>> >>> Please review patch for TBL SPR read access for generic PPC. >>> >>> Description: >>> >>> POWER spec

Re: [Qemu-devel] [PATCH 02/15] virtio-serial: save/load: Ensure nr_ports on src and dest are same.

2010-03-25 Thread Jamie Lokier
Amit Shah wrote: > The number of ports on the source as well as the destination machines > should match. If they don't, it means some ports that got hotplugged on > the source aren't instantiated on the destination. Or that ports that > were hot-unplugged on the source are created on the destinatio

Re: [Qemu-devel] TBL register permissions for PPC

2010-03-25 Thread Dmitry Ilyevsky
On Thu, Mar 25, 2010 at 10:53 AM, Alexander Graf wrote: > > On 24.03.2010, at 22:56, Dmitry Ilyevsky wrote: > >> >> Hello All, >> >> Please review patch for TBL SPR read access for generic PPC. >> >> Description: >> >> POWER specification docs define TBL/TBU SPRs as readable in user and >> privil

Re: [Qemu-devel] How do I build mips64-linux-user?

2010-03-25 Thread Nathan Froyd
On Thu, Mar 25, 2010 at 07:04:46PM -0500, Rob Landley wrote: > If I do the standard "./configure --disable-werror", it builds qemu-mips and > qemu-system-mips64, but no qemu-mips64. If I tell it "./configure --disable- > werror --target-list-mips64-linux-user", configure completes but the build

[Qemu-devel] How do I build mips64-linux-user?

2010-03-25 Thread Rob Landley
If I do the standard "./configure --disable-werror", it builds qemu-mips and qemu-system-mips64, but no qemu-mips64. If I tell it "./configure --disable- werror --target-list-mips64-linux-user", configure completes but the build breaks because it can't set up the dependencies for that directory.

Re: [Qemu-devel] Significant performance regression in qemu-system-mips.

2010-03-25 Thread Alexander Graf
On 26.03.2010, at 00:25, Aurelien Jarno wrote: > On Thu, Mar 25, 2010 at 12:33:33PM -0500, Rob Landley wrote: >> On Thursday 25 March 2010 04:20:26 Artyom Tarasenko wrote: >>> 2010/3/24 Rob Landley : I have a native build under qemu that gets killed if it doesn't produce a line of outpu

Re: [Qemu-devel] Significant performance regression in qemu-system-mips.

2010-03-25 Thread Aurelien Jarno
On Thu, Mar 25, 2010 at 12:33:33PM -0500, Rob Landley wrote: > On Thursday 25 March 2010 04:20:26 Artyom Tarasenko wrote: > > 2010/3/24 Rob Landley : > > > I have a native build under qemu that gets killed if it doesn't produce a > > > line of output for 60 seconds (hang detection enforced by the h

[Qemu-devel] Re: [PATCH v3 0/2] Inter-VM shared memory PCI device

2010-03-25 Thread Cam Macdonell
On Thu, Mar 25, 2010 at 3:10 PM, Avi Kivity wrote: > On 03/25/2010 08:17 PM, Cam Macdonell wrote: >> I had a hunch it was probably considered.  That explains why irqfd doesn't have a datamatch field.  I guess supporting multiple MSI vectors with one doorbell per guest isn't possible

Re: [Qemu-devel] [PATCH] qemu-img: add FUSE-based image access

2010-03-25 Thread Anthony Liguori
On 03/25/2010 05:27 PM, Jan Kiszka wrote: Anthony Liguori wrote: On 03/25/2010 04:46 PM, Jan Kiszka wrote: Anthony Liguori wrote: On 03/25/2010 12:52 PM, Jan Kiszka wrote: This adds the "map" subcommand to qemu-img. It is able to expose the raw content of a disk

Re: [Qemu-devel] [PATCH] qemu-img: add FUSE-based image access

2010-03-25 Thread Jan Kiszka
Anthony Liguori wrote: > On 03/25/2010 04:46 PM, Jan Kiszka wrote: >> Anthony Liguori wrote: >> >>> On 03/25/2010 12:52 PM, Jan Kiszka wrote: >>> This adds the "map" subcommand to qemu-img. It is able to expose the raw content of a disk image via a FUSE filesystem. Both the w

Re: [Qemu-devel] [PATCH] qemu-img: add FUSE-based image access

2010-03-25 Thread Anthony Liguori
On 03/25/2010 04:46 PM, Jan Kiszka wrote: Anthony Liguori wrote: On 03/25/2010 12:52 PM, Jan Kiszka wrote: This adds the "map" subcommand to qemu-img. It is able to expose the raw content of a disk image via a FUSE filesystem. Both the whole disk can be accessed, e.g. to run partition

Re: [Qemu-devel] [PATCH] qemu-img: add FUSE-based image access

2010-03-25 Thread Jan Kiszka
Anthony Liguori wrote: > On 03/25/2010 12:52 PM, Jan Kiszka wrote: >> This adds the "map" subcommand to qemu-img. It is able to expose the raw >> content of a disk image via a FUSE filesystem. Both the whole disk can >> be accessed, e.g. to run partitioning tools against it, as well as >> individua

[Qemu-devel] [PATCH] Get bsd-user host page protection code working on FreeBSD hosts

2010-03-25 Thread Juergen Lock
Use kinfo_getvmmap(3) on FeeBSD >= 7.x and /compat/linux/proc on older FreeBSD. (kinfo_getvmmap is preferred since /compat/linux/proc is usually only mounted on hosts also using the Linuxolator.) This patch is a bit hacky because the includes needed for kinfo_getvmmap conflict with other definiti

[Qemu-devel] [PATCH] Avoid page_set_flags() assert in qemu-user host page protection code

2010-03-25 Thread Juergen Lock
Signed-off-by: Juergen Lock --- a/exec.c +++ b/exec.c @@ -293,10 +293,13 @@ static void page_init(void) if (h2g_valid(endaddr)) { endaddr = h2g(endaddr); +page_set_flags(startaddr, endaddr, PAGE_RESERVED);

[Qemu-devel] [PATCH] Add a missing #include for FreeBSD hosts

2010-03-25 Thread Juergen Lock
Signed-off-by: Juergen Lock --- a/qemu-timer.c +++ b/qemu-timer.c @@ -35,6 +35,9 @@ #include #include #include +#ifdef __FreeBSD__ +#include +#endif #ifdef __linux__ #include

[Qemu-devel] [PATCH] Fix bsd-user qemu_vmalloc() host page protection code

2010-03-25 Thread Juergen Lock
Just do the same as linux-user does. Signed-off-by: Juergen Lock --- a/bsd-user/mmap.c +++ b/bsd-user/mmap.c @@ -77,16 +77,15 @@ void mmap_unlock(void) void *qemu_vmalloc(size_t size) { void *p; -unsigned long addr; mmap_lock(); /* Use map and mark the pages as used. */

[Qemu-devel] [PATCH] Fix some compilation warnings on FreeBSD hosts

2010-03-25 Thread Juergen Lock
Signed-off-by: Juergen Lock --- a/qemu-char.c +++ b/qemu-char.c @@ -1372,7 +1372,7 @@ static CharDriverState *qemu_chr_open_pp #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__) static int pp_ioctl(CharDriverState *chr, int cmd, void *arg) { -int fd = (int)c

[Qemu-devel] [PATCH] Use sysctl instead of /proc to find executable path on FreeBSD

2010-03-25 Thread Juergen Lock
..since /proc usually isn't mounted on FreeBSD. Signed-off-by: Juergen Lock --- a/vl.c +++ b/vl.c @@ -52,6 +52,7 @@ #include #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__) #include +#include #else #include #endif @@ -3368,10 +3369,13 @@ static char *

[Qemu-devel] Re: [PATCH v3 0/2] Inter-VM shared memory PCI device

2010-03-25 Thread Avi Kivity
On 03/25/2010 08:17 PM, Cam Macdonell wrote: I had a hunch it was probably considered. That explains why irqfd doesn't have a datamatch field. I guess supporting multiple MSI vectors with one doorbell per guest isn't possible if one 1 bit of information can be communicated. Actually

Re: [Qemu-devel] [patch 1/2] Pass QEMUIOWorker to qemu_notify_event

2010-03-25 Thread Paul Brook
> /* Force QEMU to process pending events */ > -void qemu_notify_event(void); > +void qemu_notify_event(QEMUIOWorker *worker); > static void handle_input(VirtIODevice *vdev, VirtQueue *vq) > { > +qemu_notify_event(main_io_worker); > } This feels completely wrong. Devices shouldn't know o

Re: [Qemu-devel] [PATCH -V3 01/32] vitio-9p: Add a virtio 9p device to qemu

2010-03-25 Thread Anthony Liguori
On 03/25/2010 11:43 AM, Aneesh Kumar K.V wrote: From: Anthony Liguori This patch doesn't implement the 9p protocol handling code. It add a simple device which dump the protocl data Signed-off-by: Anthony Liguori Signed-off-by: Aneesh Kumar K.V --- Makefile.target |1 + hw/virtio-9p-

Re: [Qemu-devel] [PATCH] qemu-img: add FUSE-based image access

2010-03-25 Thread Anthony Liguori
On 03/25/2010 12:52 PM, Jan Kiszka wrote: This adds the "map" subcommand to qemu-img. It is able to expose the raw content of a disk image via a FUSE filesystem. Both the whole disk can be accessed, e.g. to run partitioning tools against it, as well as individual partitions. This allows to create

[Qemu-devel] qemu git head 20100323 on FreeBSD - qemu-devel port update for testing

2010-03-25 Thread Juergen Lock
Hi! Now that qemu git head works again (thanx Aurelien! :) I've finished the FreeBSD qemu-devel port update patch/shar that made me uncover the bug: http://people.freebsd.org/~nox/qemu/qemu-devel-20100323.patch resp. http://people.freebsd.org/~nox/qemu/qemu-devel-20100323.shar T

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

2010-03-25 Thread Blue Swirl
Use qemu_irqs to trigger CMOS S3 and SMI events. Avoid using kvm.h, which uses CPUState. Signed-off-by: Blue Swirl --- Makefile.objs|1 + Makefile.target |4 +- default-configs/i386-softmmu.mak |1 + default-configs/mips-softmmu.mak

[Qemu-devel] [PATCH 2/3] Compile vmware_vga only once

2010-03-25 Thread Blue Swirl
Signed-off-by: Blue Swirl --- Makefile.objs|1 + Makefile.target |3 +-- default-configs/i386-softmmu.mak |1 + default-configs/mips-softmmu.mak |1 + default-configs/mips64-softmmu.mak |1 + default-configs/mips64el-softm

[Qemu-devel] [PATCH 1/3] Compile some MIPS devices only once

2010-03-25 Thread Blue Swirl
Move CPU specific declarations to a separate file. Signed-off-by: Blue Swirl --- Makefile.objs|6 ++ Makefile.target |8 +++- default-configs/mips-softmmu.mak |5 + default-configs/mips64-softmmu.mak |5 + default

[Qemu-devel] [PATCH] Fix busted driftfix option

2010-03-25 Thread Zachary Amsden
For some reason, this uses CONFIG_TARGET_I386 instead of TARGET_I386, so the code is dead. CONFIG_TARGET_XXX is wrong Signed-off-by: Zachary Amsden diff --git a/vl.c b/vl.c index 6e35cc6..9720619 100644 --- a/vl.c +++ b/vl.c @@ -1565,7 +1565,7 @@ static void configure_rtc(QemuOpts *opts)

Re: [Qemu-devel] [PATCH] Add qerror message if the 'change' target filename can't be opened

2010-03-25 Thread Markus Armbruster
Ryan Harper writes: > * Markus Armbruster [2010-03-25 11:41]: >> Ryan Harper writes: >> >> > Currently when using the change command to switch the file in the cd drive >> > the command doesn't complain if the file doesn't exit or can't be opened >> > and the drive keeps the existing image. Th

[Qemu-devel] Re: [PATCH 3/3] monitor: Convert do_migrate() to QError

2010-03-25 Thread Markus Armbruster
Luiz Capitulino writes: > On Thu, 25 Mar 2010 18:37:25 +0100 > Markus Armbruster wrote: > > [...] > >> >> @@ -86,12 +86,13 @@ int do_migrate(Monitor *mon, const QDict *qdict, >> >> QObject **ret_data) >> >> (int)qdict_get_int(qdict, >> >> "inc")); >> >>

Re: [Qemu-devel] [PATCH] Add qerror message if the 'change' target filename can't be opened

2010-03-25 Thread Ryan Harper
* Markus Armbruster [2010-03-25 11:41]: > Ryan Harper writes: > > > Currently when using the change command to switch the file in the cd drive > > the command doesn't complain if the file doesn't exit or can't be opened > > and the drive keeps the existing image. This patch adds a qerror_report

[Qemu-devel] Re: [PATCH v3 00/11] monitor: New commands netdev_add, netdev_del

2010-03-25 Thread Luiz Capitulino
On Thu, 25 Mar 2010 17:22:29 +0100 Markus Armbruster wrote: > v2: Avoid loss of help in parse_option_size(). Rebased. > > v3: Fix detection of duplicate netdev id. Yes, it's fixed. Looks good.

[Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Luiz Capitulino
On Wed, 24 Mar 2010 20:19:28 +0530 Amit Shah wrote: > When adding a port or a device to the guest fails, management software > might be interested in knowing and then cleaning up the host-side of the > port. Introduce QMP events to signal such errors. > > Signed-off-by: Amit Shah > CC: Luiz Cap

[Qemu-devel] Re: [PATCH 10/15] virtio-serial: Add QMP events for failed port/device add

2010-03-25 Thread Luiz Capitulino
On Thu, 25 Mar 2010 09:17:17 +0530 Amit Shah wrote: > On (Wed) Mar 24 2010 [17:34:15], Luiz Capitulino wrote: > > On Wed, 24 Mar 2010 20:19:28 +0530 > > Amit Shah wrote: > > > > > When adding a port or a device to the guest fails, management software > > > might be interested in knowing and the

[Qemu-devel] Re: [PATCH v3 0/2] Inter-VM shared memory PCI device

2010-03-25 Thread Cam Macdonell
On Thu, Mar 25, 2010 at 11:48 AM, Avi Kivity wrote: > On 03/25/2010 07:35 PM, Cam Macdonell wrote: >> >>> Ah, I see.  You adjusted for the different behaviours in the driver. >>> >>> Still I recommend dropping the status register: this allows single-msi >>> and >>> PIRQ to behave the same way.  Al

Re: [Qemu-devel] [PATCH 09/10] target-alpha: Implement load-locked/store-conditional properly.

2010-03-25 Thread Richard Henderson
On 03/25/2010 10:40 AM, Blue Swirl wrote: > Sparc V8 has two atomic instructions, ldstub and swap. I know -- but not the CAS operation being discussed here. As I think about this more and more, the Real Problem is not with the CAS, but with the memory ordering requirements of the guest vs the mem

[Qemu-devel] [PATCH] qemu-img: add FUSE-based image access

2010-03-25 Thread Jan Kiszka
This adds the "map" subcommand to qemu-img. It is able to expose the raw content of a disk image via a FUSE filesystem. Both the whole disk can be accessed, e.g. to run partitioning tools against it, as well as individual partitions. This allows to create new filesystems in the image or loop-back m

[Qemu-devel] Re: [PATCH 3/3] monitor: Convert do_migrate() to QError

2010-03-25 Thread Luiz Capitulino
On Thu, 25 Mar 2010 18:37:25 +0100 Markus Armbruster wrote: [...] > >> @@ -86,12 +86,13 @@ int do_migrate(Monitor *mon, const QDict *qdict, > >> QObject **ret_data) > >> (int)qdict_get_int(qdict, "inc")); > >> #endif > >> } else { > >> -mon

[Qemu-devel] Re: [PATCH v3 0/2] Inter-VM shared memory PCI device

2010-03-25 Thread Avi Kivity
On 03/25/2010 07:35 PM, Cam Macdonell wrote: Ah, I see. You adjusted for the different behaviours in the driver. Still I recommend dropping the status register: this allows single-msi and PIRQ to behave the same way. Also it is racy, if two guests signal a third, they will overwrite each oth

Re: [Qemu-devel] [PATCH 09/10] target-alpha: Implement load-locked/store-conditional properly.

2010-03-25 Thread Blue Swirl
On 3/25/10, Richard Henderson wrote: > On 03/25/2010 06:39 AM, Nathan Froyd wrote: > > On Wed, Mar 24, 2010 at 05:11:43PM -0700, Richard Henderson wrote: > >> Use __sync_bool_compare_and_swap to yield correctly atomic results. > >> As yet, this assumes running on an strict-memory-ordering host

[Qemu-devel] Re: [PATCH 0/4] monitor: Convert do_set_link() to QObject, QError

2010-03-25 Thread Daniel P. Berrange
On Wed, Mar 24, 2010 at 04:20:53PM -0300, Luiz Capitulino wrote: > On Tue, 23 Mar 2010 11:27:54 +0100 > Markus Armbruster wrote: > > > PATCH 3/4 changes syntax of set_link's second argument from up|down to > > on|off. I feel that the argument needs to be boolean in QMP, and this > > is the simpl

Re: [Qemu-devel] Re: [libvirt] Supporting hypervisor specific APIs in libvirt

2010-03-25 Thread Anthony Liguori
On 03/25/2010 11:50 AM, Markus Armbruster wrote: The point is, C is a lowest common denominator and it's important to support in a proper way. No. The lowest truly common denominator is plain text. And we got that covered already. A developer encountered the problem of talking a simpl

[Qemu-devel] Re: [PATCH 2/4] monitor: New argument type 'b'

2010-03-25 Thread Luiz Capitulino
On Thu, 25 Mar 2010 18:28:43 +0100 Markus Armbruster wrote: > Luiz Capitulino writes: > > > On Tue, 23 Mar 2010 11:27:56 +0100 > > Markus Armbruster wrote: > > > >> This is a boolean value. Human monitor accepts "on" or "off". > >> Consistent with option parsing (see parse_option_bool()). > >

[Qemu-devel] Re: [PATCH 3/3] monitor: Convert do_migrate() to QError

2010-03-25 Thread Markus Armbruster
Luiz Capitulino writes: > On Tue, 23 Mar 2010 19:07:21 +0100 > Markus Armbruster wrote: > >> Human monitor error message changes from "unknown migration protocol: >> FOO" to "Invalid parameter uri". >> >> The conversion is shallow: the FOO_start_outgoing_migration() aren't >> converted. Conver

[Qemu-devel] Re: [PATCH v3 0/2] Inter-VM shared memory PCI device

2010-03-25 Thread Cam Macdonell
On Thu, Mar 25, 2010 at 11:02 AM, Avi Kivity wrote: > On 03/25/2010 06:50 PM, Cam Macdonell wrote: >> >>> Please put the spec somewhere publicly accessible with a permanent URL. >>>  I >>> suggest a new qemu.git directory specs/.  It's more important than the >>> code >>> IMO. >>> >> >> Sorry to b

Re: [Qemu-devel] Significant performance regression in qemu-system-mips.

2010-03-25 Thread Rob Landley
On Thursday 25 March 2010 04:20:26 Artyom Tarasenko wrote: > 2010/3/24 Rob Landley : > > I have a native build under qemu that gets killed if it doesn't produce a > > line of output for 60 seconds (hang detection enforced by the host > > monitoring qemu's stdout with --nographic, not from within qe

[Qemu-devel] Re: [PATCH 2/4] monitor: New argument type 'b'

2010-03-25 Thread Markus Armbruster
Luiz Capitulino writes: > On Tue, 23 Mar 2010 11:27:56 +0100 > Markus Armbruster wrote: > >> This is a boolean value. Human monitor accepts "on" or "off". >> Consistent with option parsing (see parse_option_bool()). >> >> Signed-off-by: Markus Armbruster >> --- >> monitor.c | 31 ++

[Qemu-devel] Re: [PATCH v3 1/1] Shared memory uio_pci driver

2010-03-25 Thread Cam Macdonell
On Thu, Mar 25, 2010 at 10:34 AM, Michael S. Tsirkin wrote: > On Thu, Mar 25, 2010 at 10:30:42AM -0600, Cam Macdonell wrote: >> On Thu, Mar 25, 2010 at 3:05 AM, Michael S. Tsirkin wrote: >> > On Thu, Mar 25, 2010 at 12:09:36AM -0600, Cam Macdonell wrote: >> >> This patch adds a driver for my shar

[Qemu-devel] Re: [PATCH v3 1/1] Shared memory uio_pci driver

2010-03-25 Thread Avi Kivity
On 03/25/2010 06:40 PM, Michael S. Tsirkin wrote: On Thu, Mar 25, 2010 at 06:32:15PM +0200, Avi Kivity wrote: On 03/25/2010 06:23 PM, Anthony Liguori wrote: There has been previous discussion of virtio, however while virtio is good for exporting guest memory, it's not ideal for import

[Qemu-devel] Re: [PATCH v3 0/2] Inter-VM shared memory PCI device

2010-03-25 Thread Cam Macdonell
On Thu, Mar 25, 2010 at 3:04 AM, Avi Kivity wrote: > On 03/25/2010 08:08 AM, Cam Macdonell wrote: >> >> Support an inter-vm shared memory device that maps a shared-memory object >> as a PCI device in the guest.  This patch also supports interrupts between >> guest by communicating over a unix doma

Re: [Qemu-devel] [PATCH 09/10] target-alpha: Implement load-locked/store-conditional properly.

2010-03-25 Thread Richard Henderson
On 03/25/2010 09:42 AM, Nathan Froyd wrote: > Ah, OK. Those helpers are never called for user-mode emulation, > though. They're only called for system emulation and...well, everybody > lies about being atomic in system mode. :) Ah, right. I missed the user/system variations of OP_ST_ATOMIC. r

Re: [Qemu-devel] Re: [libvirt] Supporting hypervisor specific APIs in libvirt

2010-03-25 Thread Markus Armbruster
Anthony Liguori writes: > On 03/25/2010 07:37 AM, Avi Kivity wrote: >> On 03/25/2010 02:33 PM, Anthony Liguori wrote: From my point of view, i wouldn't want to write a high level management toolstack in C, specially since the API is well defined JSON which is easily available in >>

[Qemu-devel] Re: [PATCH v3 1/1] Shared memory uio_pci driver

2010-03-25 Thread Avi Kivity
On 03/25/2010 06:37 PM, Michael S. Tsirkin wrote: On Thu, Mar 25, 2010 at 06:36:02PM +0200, Avi Kivity wrote: On 03/25/2010 11:05 AM, Michael S. Tsirkin wrote: +static struct pci_device_id ivshmem_pci_ids[] __devinitdata = { +{ +.vendor =0x1af4, +.devic

[Qemu-devel] Re: [PATCH v3 0/2] Inter-VM shared memory PCI device

2010-03-25 Thread Avi Kivity
On 03/25/2010 06:50 PM, Cam Macdonell wrote: Please put the spec somewhere publicly accessible with a permanent URL. I suggest a new qemu.git directory specs/. It's more important than the code IMO. Sorry to be pedantic, do you want a URL or the spec as part of a patch that adds it as

[Qemu-devel] Re: [PATCH v3 1/1] Shared memory uio_pci driver

2010-03-25 Thread Michael S. Tsirkin
On Thu, Mar 25, 2010 at 10:24:20AM -0600, Cam Macdonell wrote: > On Thu, Mar 25, 2010 at 3:46 AM, Avi Kivity wrote: > > On 03/25/2010 08:09 AM, Cam Macdonell wrote: > >> > >> This patch adds a driver for my shared memory PCI device using the uio_pci > >> interface.  The driver has three memory reg

[Qemu-devel] Re: [PATCH v3 1/1] Shared memory uio_pci driver

2010-03-25 Thread Michael S. Tsirkin
On Thu, Mar 25, 2010 at 06:32:15PM +0200, Avi Kivity wrote: > On 03/25/2010 06:23 PM, Anthony Liguori wrote: >>> There has been previous discussion of virtio, however while virtio is >>> good for exporting guest memory, it's not ideal for importing memory >>> into a guest. >> >> virtio is a DMA-bas

[Qemu-devel] [PATCH -V3 32/32] virtio-9p: Handle unknown 9P protocol versions as per the standards.

2010-03-25 Thread Aneesh Kumar K.V
From: Sripathi Kodi Currently the code does BUG_ON if it receives any version other than 9P2000.u. However, 9P protocol says: If the server does not understand the client's version string, it should respond with an Rversion message (not Rerror) with the version string the 7 characters "unknown".

[Qemu-devel] [PATCH -V3 31/32] virtio-9p: Return proper errors from create paths.

2010-03-25 Thread Aneesh Kumar K.V
From: Sripathi Kodi Create first calls lstat to see if the file exists. Errors from lstat are not handled properly. For most of the errors we return EEXIST. We should return the errno instead. Signed-off-by: Sripathi Kodi Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c |2 +- 1 files c

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

2010-03-25 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 -V3 29/32] virtio-9p: Decouple share_path details from virtio-9p-dev

2010-03-25 Thread Aneesh Kumar K.V
From: Gautham R Shenoy Currently the share_path is an attribute of the virtio-9p device. This patch makes fsdev object as an attribute of virtio-9p device by decoupling the latter's association with share_path. This abstraction would be useful in the future when we want to specify certain file-

[Qemu-devel] [PATCH -V3 28/32] virtio-9p: Handle the fsdev command line options.

2010-03-25 Thread Aneesh Kumar K.V
From: Gautham R Shenoy This patch handles: - Parsing of fsdev commandline options. - Maintaining a list of fsdev entries. - Providing callbacks for the other subsystems to obtain FsTypeEntries for a given fsdev based on it's id. This will be used later to decouple the share_path attribute from

[Qemu-devel] [PATCH -V3 27/32] virtio-9p: Create qemu_fsdev_opts

2010-03-25 Thread Aneesh Kumar K.V
From: Gautham R Shenoy Create qemu_fsdev_opts to store the parsed commandline attributes for fsdev. Signed-off-by: Gautham R Shenoy Signed-off-by: Aneesh Kumar K.V --- qemu-config.c | 16 qemu-config.h |1 + 2 files changed, 17 insertions(+), 0 deletions(-) diff --git

[Qemu-devel] [PATCH -V3 25/32] virtio-9p: Move V9fs File system specific options to a separate header file.

2010-03-25 Thread Aneesh Kumar K.V
Move the V9fs File System specific operations structs into a different header file. Also introduce a new struct named context which is the subset of the V9fsState to be passed to the individual file-system operations. Signed-off-by: Aneesh Kumar K.V Signed-off-by: Gautham R Shenoy --- hw/file-

[Qemu-devel] [PATCH -V3 26/32] virtio-9p: Create a commandline option -fsdev

2010-03-25 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 The only option for fstype currently is local. Signed-off-by: Gautham

[Qemu-devel] [PATCH -V3 24/32] qemu-malloc: Add qemu_asprintf

2010-03-25 Thread Aneesh Kumar K.V
From: Gautham R Shenoy Add the API qemu_asprintf() along the lines of qemu_vasprintf() Signed-off-by: Gautham R Shenoy Signed-off-by: Aneesh Kumar K.V --- qemu-common.h |1 + qemu-malloc.c | 12 2 files changed, 13 insertions(+), 0 deletions(-) diff --git a/qemu-common.h b

[Qemu-devel] [PATCH -V3 20/32] virtio-9p: Remove BUG_ON and add proper error handling

2010-03-25 Thread Aneesh Kumar K.V
Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 106 1 files changed, 84 insertions(+), 22 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c index 1237bac..3ce26ca 100644 --- a/hw/virtio-9p.c +++ b/hw/virtio-9p.c @@ -244,7 +2

[Qemu-devel] [PATCH -V3 23/32] vritio-9p: Fix chmod bug with directory

2010-03-25 Thread Aneesh Kumar K.V
chmod 0777 fails with EIO. This is a result of wrong check in server code. Server code is trying to check if the file type is not being changed by making sure that fidp->dir is not NULL. But the fidp->dir is set only on opendir/createdir. This patch gives proper check to all special files. Sign

[Qemu-devel] [PATCH -V3 21/32] virtio-9p: Remove unnecessary definition of fid

2010-03-25 Thread Aneesh Kumar K.V
We already have fid as a part of V9fsFidState so use that instead of defining another variable Signed-off-by: Aneesh Kumar K.V Reviewed-by: Venkateswararao Jujjuri --- hw/virtio-9p.c | 62 ++- 1 files changed, 29 insertions(+), 33 deletions(

[Qemu-devel] [PATCH -V3 22/32] virtio-9p: Update existing fid path on rename

2010-03-25 Thread Aneesh Kumar K.V
We need to make sure that we update the path component of the existing fid's when we rename a file. The client is not expected to clunk these fids pointing to the old name. If we don't update any operation on the old unopened fid will point to the old name and will fail Add BUG_ON to make sure whe

[Qemu-devel] [PATCH -V3 19/32] virtio-9p: Get the correct count values from the pdu

2010-03-25 Thread Aneesh Kumar K.V
From: Venkateswararao Jujjuri PDU contain little endian format for integer values. So we need to make sure we map them to host format. Also the count value can be in another sg offset other than 0. Use the righ functions to get the count value Signed-off-by: Venkateswararao Jujjuri Signed-off-b

[Qemu-devel] [PATCH -V3 18/32] virtio-9p: Fix sg usage in the code

2010-03-25 Thread Aneesh Kumar K.V
sg list contain more than one element and we need to use the right element when we are doing the marshaling and unmarshaling of data. This patch also abstract out the pack/unpack interface and make sure we use one function for doing both. Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p-debug.c

[Qemu-devel] [PATCH -V3 15/32] virtio-9p: Use little endian format on virtio

2010-03-25 Thread Aneesh Kumar K.V
We need to use platform independent data format as part of protocol data. 9P uses little endian format on wire Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c | 34 +++--- 1 files changed, 23 insertions(+), 11 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio

[Qemu-devel] [PATCH -V3 17/32] Implement sync support in 9p server

2010-03-25 Thread Aneesh Kumar K.V
From: M. Mohan Kumar When wstat is called with stat field values set to 'don't touch' pattern, 9p Server interprets it as a request to guarantee that the contents of the associated file are committed to stable storage before the Rwstat message is returned. Implement this feature in the server sid

[Qemu-devel] [PATCH -V3 13/32] virtio-9p: Implement P9_TFLUSH

2010-03-25 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 |5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c index 4478e57..1dbb982 100644 --- a/hw/virti

[Qemu-devel] [PATCH -V3 16/32] virtio-9p: Add support for hardlink

2010-03-25 Thread Aneesh Kumar K.V
link count for files and directories are encoded as a tagged string in the extension field for a .u protocol extension. Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/hw/virtio-9p.c b/hw/virtio-9p.c index e8a9eeb..3dd

[Qemu-devel] [PATCH -V3 14/32] virtio-9p: Add multiple mount point support

2010-03-25 Thread Aneesh Kumar K.V
This patch add a mount tag name in 9p config space. This tag should uniquely identify the mount point and should be used in the mount command as the device name Qemu command line for specifying 9p share directory now becomes -device virtio-9p-pci,share_path=/mnt/,mount_tag=v_mnt -device virtio-9p-

[Qemu-devel] [PATCH -V3 12/32] virtio-9p: Implement P9_TREMOVE

2010-03-25 Thread Aneesh Kumar K.V
From: Anthony Liguori 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: Gautham R Shenoy Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p-local.c |7 ++ hw/virtio-9p.c | 54

[Qemu-devel] [PATCH -V3 11/32] virtio-9p: Implement P9_TWSTAT

2010-03-25 Thread Aneesh Kumar K.V
From: Anthony Liguori This gets file and directory creation to work [jv...@linux.vnet.ibm.com: strdup to qemu_strdup conversion] Signed-off-by: Anthony Liguori Signed-off-by: Gautham R Shenoy Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p-local.c | 42 + hw/virtio-9p.c |

[Qemu-devel] [PATCH -V3 10/32] virtio-9p: Implement P9_TCREATE

2010-03-25 Thread Aneesh Kumar K.V
From: Anthony Liguori [jv...@linux.vnet.ibm.com: strdup to qemu_strdup conversion] Signed-off-by: Anthony Liguori Signed-off-by: Gautham R Shenoy Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p-local.c | 80 +++ hw/virtio-9p.c | 266 +

[Qemu-devel] [PATCH -V3 04/32] virtio-9p: Implement P9_TSTAT

2010-03-25 Thread Aneesh Kumar K.V
From: Anthony Liguori 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: Gautham R Shenoy Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p-local.c |7 ++ hw/virtio-9p.c | 169 +

[Qemu-devel] [PATCH -V3 09/32] virtio-9p: Implement P9_TWRITE

2010-03-25 Thread Aneesh Kumar K.V
From: Anthony Liguori This gets write to file to work Signed-off-by: Anthony Liguori Signed-off-by: Venkateswararao Jujjuri Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p-local.c |7 hw/virtio-9p.c | 97 - 2 files changed, 10

[Qemu-devel] [PATCH -V3 08/32] virtio-9p: Implement P9_TCLUNK

2010-03-25 Thread Aneesh Kumar K.V
From: Anthony Liguori 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 9bc0a57..3ac6255 100644 --- a/h

[Qemu-devel] [PATCH -V3 07/32] virtio-9p: Implement P9_TREAD

2010-03-25 Thread Aneesh Kumar K.V
From: Anthony Liguori Signed-off-by: Anthony Liguori Signed-off-by: Venkateswararao Jujjuri Signed-off-by: Aneesh Kumar K.V --- hw/virtio-9p-local.c | 37 hw/virtio-9p.c | 253 +- 2 files changed, 287 insertions(+), 3 deletions

  1   2   3   >