Re: [Qemu-devel] [Qemu-trivial] [PATCH] Makefile: fix out-of-tree builds

2011-07-25 Thread Michael Roth
On 07/25/2011 07:43 AM, Stefan Hajnoczi wrote: On Mon, Jul 25, 2011 at 1:16 PM, Michael Roth wrote: On 07/25/2011 05:15 AM, Stefan Hajnoczi wrote: On Thu, Jul 21, 2011 at 5:41 AM, Alexandre Raymond wrote: This patch fixes a minor bugs which prevented QEMU from being built out of tree. Si

[Qemu-devel] [PATCH 00/23] Memory API, batch 1

2011-07-25 Thread Avi Kivity
This patchset contains the core of the memory API, with one device (usb-ohci) coverted for reference. The API is currently implemented on top of the old ram_addr_t/cpu_register_physical_memory() API, but the plan is to make it standalone later. The goals of the API are: - correctness: by modelli

[Qemu-devel] [PATCH 02/23] memory: implement dirty tracking

2011-07-25 Thread Avi Kivity
Currently dirty tracking is implemented by passing through all calls to the underlying cpu_physical_memory_*() calls. Signed-off-by: Avi Kivity --- memory.c | 39 +++ memory.h |1 + 2 files changed, 32 insertions(+), 8 deletions(-) diff --git a/memory.c

[Qemu-devel] [PATCH 18/23] pc: convert pc_memory_init() to memory API

2011-07-25 Thread Avi Kivity
Signed-off-by: Avi Kivity --- hw/pc.c | 59 --- hw/pc.h |1 + 2 files changed, 41 insertions(+), 19 deletions(-) diff --git a/hw/pc.c b/hw/pc.c index 369566a..1c9d89a 100644 --- a/hw/pc.c +++ b/hw/pc.c @@ -41,6 +41,7 @@ #include "sys

[Qemu-devel] [PATCH 21/23] pci: add MemoryRegion based BAR management API

2011-07-25 Thread Avi Kivity
Allow registering a BAR using a MemoryRegion. Once all users are converted, pci_register_bar() and pci_register_bar_simple() will be removed. Signed-off-by: Avi Kivity --- hw/pci.c | 47 +++ hw/pci.h |3 +++ 2 files changed, 42 insertions(+), 8

[Qemu-devel] [PATCH 08/23] memory: I/O address space support

2011-07-25 Thread Avi Kivity
Allow registering I/O ports via the same mechanism as mmio ranges. Signed-off-by: Avi Kivity --- exec-memory.h |3 ++ memory.c | 60 - memory.h |2 + 3 files changed, 64 insertions(+), 1 deletions(-) diff --git a/exec-m

Re: [Qemu-devel] [RFC v5 86/86] 440fx: fix PAM, PCI holes

2011-07-25 Thread Avi Kivity
On 07/25/2011 04:47 PM, Anthony Liguori wrote: On 07/25/2011 08:38 AM, Avi Kivity wrote: On 07/25/2011 04:35 PM, Gleb Natapov wrote: > > That's the ISA TOM (15MB hole and friends). > Correct. What about: 3.2.19. DRB[0:7] DRAM ROW BOUNDARY REGISTERS from 440fx spec? Maybe. But we can't use t

Re: [Qemu-devel] [RFC v5 86/86] 440fx: fix PAM, PCI holes

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:05 AM, Avi Kivity wrote: On 07/25/2011 04:47 PM, Anthony Liguori wrote: On 07/25/2011 08:38 AM, Avi Kivity wrote: On 07/25/2011 04:35 PM, Gleb Natapov wrote: > > That's the ISA TOM (15MB hole and friends). > Correct. What about: 3.2.19. DRB[0:7] DRAM ROW BOUNDARY REGISTERS fr

Re: [Qemu-devel] [RFC v5 86/86] 440fx: fix PAM, PCI holes

2011-07-25 Thread Avi Kivity
On 07/25/2011 05:08 PM, Anthony Liguori wrote: Why not use 3.5GB and call it a day? It's safer for memory hotplug, if we ever get it. The guest will never put a PCI BAR below that anyway. My entire concern is that they will. We're not just talking about Windows or Linux here, but any odd DOS

Re: [Qemu-devel] [PATCH 5/7] balloon: Separate out stat and balloon handling

2011-07-25 Thread Markus Armbruster
Amit Shah writes: > On (Fri) 22 Jul 2011 [16:45:55], Markus Armbruster wrote: >> Amit Shah writes: >> >> > Passing on '0' as ballooning target to indicate retrieval of stats is >> > bad API. It also makes 'balloon 0' in the monitor cause a segfault. >> > Have two different functions handle the

Re: [Qemu-devel] [PATCH 0/7] balloon: cleanups, fix segfault

2011-07-25 Thread Markus Armbruster
Amit Shah writes: > 'balloon 0' in the monitor causes a segfault. This happens because > the function that handles change in balloon values is also tasked with > handling stats retrieval from the guest, and it does the retrieval > when the balloon target is '0'. > > Silly API, replace it. Also

[Qemu-devel] [PATCH 17/23] pc: grab system_memory

2011-07-25 Thread Avi Kivity
While eventually this should come from the machine initialization function, take a short cut to avoid converting all machines now. Signed-off-by: Avi Kivity --- hw/pc.c |3 ++- hw/pc.h |4 +++- hw/pc_piix.c |8 +++- 3 files changed, 12 insertions(+), 3 deletions(-) dif

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Blue Swirl
On Mon, Jul 25, 2011 at 1:09 PM, Avi Kivity wrote: > On 07/25/2011 01:04 PM, Alexander Graf wrote: >> >> On 25.07.2011, at 12:02, Avi Kivity wrote: >> >> >  On 07/25/2011 12:56 PM, Alexander Graf wrote: >> >>  > >> >>  >   That argument can be used to block any change.  You'll get used to >> >> it

[Qemu-devel] [Request for Help] QEMU 0.15.0 change log

2011-07-25 Thread Anthony Liguori
Hi, Hands down, 0.14.0 had the best change log of any QEMU release. A large part of the success of the change log was how many people participated in creating it. I'd love for us to go even further with 0.15.0. I've created a template to start with: http://wiki.qemu.org/ChangeLog/0.15 If

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Avi Kivity
On 07/25/2011 05:16 PM, Blue Swirl wrote: There is no escape. Don't make me destroy you. You cannot hide forever, Luke. Touché -- error compiling committee.c: too many arguments to function

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Blue Swirl
On Mon, Jul 25, 2011 at 3:21 PM, Anthony Liguori wrote: > On 07/25/2011 07:18 AM, Avi Kivity wrote: >> >> On 07/25/2011 03:11 PM, Anthony Liguori wrote: >>> >>> On 07/25/2011 03:51 AM, Avi Kivity wrote: qemu_malloc() is type-unsafe as it returns a void pointer. Introduce QEMU_NEW()

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:23 AM, Blue Swirl wrote: On Mon, Jul 25, 2011 at 3:21 PM, Anthony Liguori wrote: On 07/25/2011 07:18 AM, Avi Kivity wrote: On 07/25/2011 03:11 PM, Anthony Liguori wrote: On 07/25/2011 03:51 AM, Avi Kivity wrote: qemu_malloc() is type-unsafe as it returns a void pointer. I

[Qemu-devel] [PATCH 03/23] memory: merge adjacent segments of a single memory region

2011-07-25 Thread Avi Kivity
Simple implementations of memory routers, for example the Cirrus VGA memory banks or the 440FX PAM registers can generate adjacent memory regions which are contiguous. Detect these and merge them; this saves kvm memory slots and shortens lookup times. Signed-off-by: Avi Kivity --- memory.c |

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Max Filippov
>> qemu_malloc() is type-unsafe as it returns a void pointer. Introduce >> QEMU_NEW() (and QEMU_NEWZ()), which return the correct type. > > Just use g_new() and g_new0() > These bypass qemu_malloc(). Are we okay with that? >>> >>> Yes.  We can just make qemu_malloc use

[Qemu-devel] [PATCH 12/23] memory: separate building the final memory map into two steps

2011-07-25 Thread Avi Kivity
Instead of adding and deleting regions in one pass, do a delete pass followed by an add pass. This fixes the following case: from: 0x-0x0fff ram (a1) 0x1000-0x1fff mmio (a2) 0x2000-0x2fff ram (a3) to: 0x-0x2fff ram (b1) The single pass algorithm removed a1, added b2, then rem

[Qemu-devel] [PATCH 10/23] memory: add backward compatibility for old mmio registration

2011-07-25 Thread Avi Kivity
This eases the transition to the new API. Signed-off-by: Avi Kivity --- memory.c | 10 ++ memory.h | 10 ++ 2 files changed, 20 insertions(+), 0 deletions(-) diff --git a/memory.c b/memory.c index bb04952..e4446a0 100644 --- a/memory.c +++ b/memory.c @@ -14,6 +14,7 @@ #incl

Re: [Qemu-devel] [PATCH v2 1/2] qapi: check for python, allow path to be specified

2011-07-25 Thread Blue Swirl
On Sun, Jul 24, 2011 at 9:36 PM, Michael Roth wrote: > QAPI requires python to generate code. Check for python during > configuration and allow python to be specified manually. Now your patch is almost identical to mine. Maybe you missed it: http://lists.nongnu.org/archive/html/qemu-devel/2011-07

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:30 AM, Max Filippov wrote: qemu_malloc() is type-unsafe as it returns a void pointer. Introduce QEMU_NEW() (and QEMU_NEWZ()), which return the correct type. Just use g_new() and g_new0() These bypass qemu_malloc(). Are we okay with that? Yes. We can just make qemu_malloc

Re: [Qemu-devel] [Qemu-trivial] [PATCH] Makefile: fix out-of-tree builds

2011-07-25 Thread Stefan Hajnoczi
On Mon, Jul 25, 2011 at 2:57 PM, Michael Roth wrote: > On 07/25/2011 07:43 AM, Stefan Hajnoczi wrote: >> >> On Mon, Jul 25, 2011 at 1:16 PM, Michael Roth >>  wrote: >>> >>> On 07/25/2011 05:15 AM, Stefan Hajnoczi wrote: On Thu, Jul 21, 2011 at 5:41 AM, Alexandre Raymond  wrote:

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread malc
On Mon, 25 Jul 2011, Anthony Liguori wrote: > On 07/25/2011 09:30 AM, Max Filippov wrote: > > > > > > > > qemu_malloc() is type-unsafe as it returns a void pointer. > > > > > > > > Introduce > > > > > > > > QEMU_NEW() (and QEMU_NEWZ()), which return the correct type. > > > > > > > > > > > > > > J

[Qemu-devel] [PATCH 01/23] Hierarchical memory region API

2011-07-25 Thread Avi Kivity
The memory API separates the attributes of a memory region (its size, how reads or writes are handled, dirty logging, and coalescing) from where it is mapped and whether it is enabled. This allows a device to configure a memory region once, then hand it off to its parent bus to map it according to

[Qemu-devel] [PATCH 07/23] memory: late initialization of ram_addr

2011-07-25 Thread Avi Kivity
For non-RAM memory regions, we cannot tell whether this is an I/O region or an MMIO region. Since the qemu backing registration is different for the two, we have to defer initialization until we know which address space we are in. These shenanigans will be removed once the backing registration is

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Avi Kivity
On 07/25/2011 05:47 PM, malc wrote: Right right.. only g_new aborts on zero.. "If n_structs is 0 it returns NULL . " It's annoying that it takes this parameter at all, but I can live with it. -- error compiling com

[Qemu-devel] [PATCH 19/23] pc: move global memory map out of pc_init1() and into its callers

2011-07-25 Thread Avi Kivity
Signed-off-by: Avi Kivity --- hw/pc_piix.c | 15 --- 1 files changed, 8 insertions(+), 7 deletions(-) diff --git a/hw/pc_piix.c b/hw/pc_piix.c index d83854c..f2d0476 100644 --- a/hw/pc_piix.c +++ b/hw/pc_piix.c @@ -68,7 +68,8 @@ static void ioapic_init(IsaIrqState *isa_irq_state)

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Paolo Bonzini
On 07/25/2011 04:23 PM, Blue Swirl wrote: > Yes. We can just make qemu_malloc use g_malloc. It would be also possible to make g_malloc() use qemu_malloc(). That way we could keep the tracepoints which would lose their value with g_malloc() otherwise. qemu_malloc uses g_malloc => you keep tra

[Qemu-devel] Need to find OS running in VMs

2011-07-25 Thread bharath pb
Hi, how to find which OS running in my VMs..? If I can select the OS to deploy, which OS I can choose..? And how to deploy in KVM ? I need a simple os to do some samll processing, stiarge and computation which can run on KVM .. I’m using KVM hyper visor since I’m using open nebula to mana

Re: [Qemu-devel] [PATCH v2 1/2] qapi: check for python, allow path to be specified

2011-07-25 Thread Michael Roth
On 07/25/2011 09:36 AM, Blue Swirl wrote: On Sun, Jul 24, 2011 at 9:36 PM, Michael Roth wrote: QAPI requires python to generate code. Check for python during configuration and allow python to be specified manually. Now your patch is almost identical to mine. Maybe you missed it: http://lists.

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Blue Swirl
On Mon, Jul 25, 2011 at 5:51 PM, Paolo Bonzini wrote: > On 07/25/2011 04:23 PM, Blue Swirl wrote: >> >> >  Yes.  We can just make qemu_malloc use g_malloc. >> >> It would be also possible to make g_malloc() use qemu_malloc(). That >> way we could keep the tracepoints which would lose their value w

[Qemu-devel] [PATCH 20/23] pci: pass address space to pci bus when created

2011-07-25 Thread Avi Kivity
This is now done sloppily, via get_system_memory(). Eventually callers will be converted to stop using that. Signed-off-by: Avi Kivity --- hw/apb_pci.c |2 ++ hw/bonito.c|4 +++- hw/grackle_pci.c |5 +++-- hw/gt64xxx.c |4 +++- hw/pc.h|4 +++

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread malc
On Mon, 25 Jul 2011, Avi Kivity wrote: > On 07/25/2011 05:47 PM, malc wrote: > > Right right.. only g_new aborts on zero.. > > > > "If n_structs is 0 it returns NULL > . " Right you are. > > It's annoying that it takes

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Avi Kivity
On 07/25/2011 05:58 PM, malc wrote: > > It's annoying that it takes this parameter at all, but I can live with it. > n_structs? Yes. It's 1 in 1-epsilon of all cases. Would have preferred g_new and G_new_array instead. -- error compiling committee.c: too many arguments to function

[Qemu-devel] [PATCH 11/23] memory: add ioeventfd support

2011-07-25 Thread Avi Kivity
As with the rest of the memory API, the caller associates an eventfd with an address, and the memory API takes care of registering or unregistering when the address is made visible or invisible to the guest. Signed-off-by: Avi Kivity --- memory.c | 230 ++

[Qemu-devel] [PATCH 15/23] exec.c: initialize memory map

2011-07-25 Thread Avi Kivity
Allocate the root memory region and initialize it. Signed-off-by: Avi Kivity --- exec.c | 19 +++ 1 files changed, 19 insertions(+), 0 deletions(-) diff --git a/exec.c b/exec.c index 2160ded..d51502f 100644 --- a/exec.c +++ b/exec.c @@ -33,6 +33,8 @@ #include "kvm.h" #includ

Re: [Qemu-devel] [Qemu-trivial] [PATCH] Makefile: fix out-of-tree builds

2011-07-25 Thread Michael Roth
On 07/25/2011 09:43 AM, Stefan Hajnoczi wrote: On Mon, Jul 25, 2011 at 2:57 PM, Michael Roth wrote: On 07/25/2011 07:43 AM, Stefan Hajnoczi wrote: On Mon, Jul 25, 2011 at 1:16 PM, Michael Roth wrote: On 07/25/2011 05:15 AM, Stefan Hajnoczi wrote: On Thu, Jul 21, 2011 at 5:41 AM, Alexand

Re: [Qemu-devel] [PATCH v2] pci: Common overflow prevention

2011-07-25 Thread Michael S. Tsirkin
On Fri, Jul 22, 2011 at 11:05:01AM +0200, Jan Kiszka wrote: > Introduce pci_config_read/write_common helpers to prevent passing > accesses down the callback chain that go beyond the config space limits. > Adjust length assertions as they are no longer correct (cutting may > generate valid 3 byte ac

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Jes Sorensen
On 07/25/11 12:06, Stefan Hajnoczi wrote: >> +#define QEMU_NEW(type) ((type *)(qemu_malloc(sizeof(type >> > +#define QEMU_NEWZ(type) ((type *)(qemu_mallocz(sizeof(type > Does this mean we need to duplicate the type name for each allocation? > > struct foo *f; > > ... > f = qemu_malloc(siz

[Qemu-devel] [PATCH 13/23] memory: document the memory API

2011-07-25 Thread Avi Kivity
Signed-off-by: Avi Kivity --- docs/memory.txt | 172 +++ 1 files changed, 172 insertions(+), 0 deletions(-) create mode 100644 docs/memory.txt diff --git a/docs/memory.txt b/docs/memory.txt new file mode 100644 index 000..4460c06 --- /dev

[Qemu-devel] [PATCH resend] Add missing trace call to oslib-posix.c:qemu_vmalloc()

2011-07-25 Thread Jes . Sorensen
From: Jes Sorensen Signed-off-by: Jes Sorensen --- oslib-posix.c |5 - 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/oslib-posix.c b/oslib-posix.c index 3a18e86..196099c 100644 --- a/oslib-posix.c +++ b/oslib-posix.c @@ -79,7 +79,10 @@ void *qemu_memalign(size_t alignme

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Anthony Liguori
On 07/25/2011 10:10 AM, Jes Sorensen wrote: On 07/25/11 12:06, Stefan Hajnoczi wrote: +#define QEMU_NEW(type) ((type *)(qemu_malloc(sizeof(type +#define QEMU_NEWZ(type) ((type *)(qemu_mallocz(sizeof(type Does this mean we need to duplicate the type name for each allocation? struct foo

Re: [Qemu-devel] [PATCH 11/23] memory: add ioeventfd support

2011-07-25 Thread malc
On Mon, 25 Jul 2011, Avi Kivity wrote: > As with the rest of the memory API, the caller associates an eventfd > with an address, and the memory API takes care of registering or > unregistering when the address is made visible or invisible to the > guest. > > Signed-off-by: Avi Kivity [..snip..]

Re: [Qemu-devel] [PATCH v2] pci: Common overflow prevention

2011-07-25 Thread Michael S. Tsirkin
> Introduce pci_config_read/write_common helpers to prevent passing > accesses down the callback chain that go beyond the config space limits. > Adjust length assertions as they are no longer correct (cutting may > generate valid 3 byte accesses). > > Signed-off-by: Jan Kiszka I renamed to pci_h

Re: [Qemu-devel] [PATCH 11/23] memory: add ioeventfd support

2011-07-25 Thread Avi Kivity
On 07/25/2011 06:16 PM, malc wrote: On Mon, 25 Jul 2011, Avi Kivity wrote: > As with the rest of the memory API, the caller associates an eventfd > with an address, and the memory API takes care of registering or > unregistering when the address is made visible or invisible to the > guest. >

[Qemu-devel] [PATCH 04/23] Internal interfaces for memory API

2011-07-25 Thread Avi Kivity
get_system_memory() provides the root of the memory hierarchy. This interface is intended to be private between memory.c and exec.c. If this file is included elsewhere, it should be regarded as a bug (or TODO item). However, it will be temporarily needed for the conversion to hierarchical memory

Re: [Qemu-devel] [PATCH v2] pci: Common overflow prevention

2011-07-25 Thread Jan Kiszka
On 2011-07-25 17:17, Michael S. Tsirkin wrote: >> Introduce pci_config_read/write_common helpers to prevent passing >> accesses down the callback chain that go beyond the config space limits. >> Adjust length assertions as they are no longer correct (cutting may >> generate valid 3 byte accesses).

[Qemu-devel] [PATCH 06/23] memory: rename MemoryRegion::has_ram_addr to ::terminates

2011-07-25 Thread Avi Kivity
I/O regions will not have ram_addrs, so this is a better name. Signed-off-by: Avi Kivity --- memory.c | 18 +- memory.h |2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/memory.c b/memory.c index 7187223..5fda4a0 100644 --- a/memory.c +++ b/memory.c @@

[Qemu-devel] [PATCH 22/23] sysbus: add MemoryRegion based memory management API

2011-07-25 Thread Avi Kivity
Allow registering sysbus device memory using a MemoryRegion. Once all users are converted, sysbus_init_mmio() and sysbus_init_mmio_cb() will be removed. Signed-off-by: Avi Kivity --- hw/sysbus.c | 27 --- hw/sysbus.h |3 +++ 2 files changed, 27 insertions(+), 3 del

[Qemu-devel] [PATCH 16/23] ioport: register ranges by byte aligned addresses always

2011-07-25 Thread Avi Kivity
The I/O port space is byte addressable, even for word and long accesses. An example is the VMware svga card, which has long ports on offsets 0, 1, and 2. Signed-off-by: Avi Kivity --- ioport.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ioport.c b/ioport.c index

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Jes Sorensen
On 07/25/11 17:15, Anthony Liguori wrote: > On 07/25/2011 10:10 AM, Jes Sorensen wrote: >> On 07/25/11 12:06, Stefan Hajnoczi wrote: +#define QEMU_NEW(type) ((type *)(qemu_malloc(sizeof(type > +#define QEMU_NEWZ(type) ((type *)(qemu_mallocz(sizeof(type >>> Does this mean we need to

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Avi Kivity
On 07/25/2011 06:17 PM, Jes Sorensen wrote: Using the commands consistently does have an impact, and at least with qemu_malloc() it is obvious what they are and how they behave. The proposed macros on the other hand requires everybody to go look up the macro to find out what it is trying to do.

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Paolo Bonzini
On 07/25/2011 04:56 PM, Blue Swirl wrote: > qemu_malloc uses g_malloc => you keep tracepoints, you just do not trace > memory allocated by glib Unless the plan is to replace all qemu_malloc() calls with calls to g_malloc(). We can worry when the day comes... there is already another task bloc

[Qemu-devel] [PATCH 05/23] memory: abstract address space operations

2011-07-25 Thread Avi Kivity
Prepare for multiple address space support by abstracting away the details of registering a memory range with qemu's flat representation into an AddressSpace object. Note operations which are memory specific are not abstracted, since they will never be called on I/O address spaces anyway. Signed-

Re: [Qemu-devel] [PATCH 11/23] memory: add ioeventfd support

2011-07-25 Thread malc
On Mon, 25 Jul 2011, Avi Kivity wrote: > On 07/25/2011 06:16 PM, malc wrote: > > On Mon, 25 Jul 2011, Avi Kivity wrote: > > > > > As with the rest of the memory API, the caller associates an eventfd > > > with an address, and the memory API takes care of registering or > > > unregistering when

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Jes Sorensen
On 07/25/11 17:20, Avi Kivity wrote: > On 07/25/2011 06:17 PM, Jes Sorensen wrote: >> Using the commands consistently does have an impact, and at least with >> qemu_malloc() it is obvious what they are and how they behave. The >> proposed macros on the other hand requires everybody to go look up th

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Avi Kivity
On 07/25/2011 06:21 PM, Jes Sorensen wrote: On 07/25/11 17:20, Avi Kivity wrote: > On 07/25/2011 06:17 PM, Jes Sorensen wrote: >> Using the commands consistently does have an impact, and at least with >> qemu_malloc() it is obvious what they are and how they behave. The >> proposed macros on

Re: [Qemu-devel] [PATCH resend] Add missing trace call to oslib-posix.c:qemu_vmalloc()

2011-07-25 Thread Stefan Hajnoczi
On Mon, Jul 25, 2011 at 4:13 PM, wrote: > From: Jes Sorensen > > Signed-off-by: Jes Sorensen > --- >  oslib-posix.c |    5 - >  1 files changed, 4 insertions(+), 1 deletions(-) Acked-by: Stefan Hajnoczi

[Qemu-devel] [PATCH 14/23] memory: transaction API

2011-07-25 Thread Avi Kivity
Allow changes to the memory hierarchy to be accumulated and made visible all at once. This reduces computational effort, especially when an accelerator (e.g. kvm) is involved. Useful when a single register update causes multiple changes to an address space. Signed-off-by: Avi Kivity --- memory

[Qemu-devel] [PATCH 09/23] memory: add backward compatibility for old portio registration

2011-07-25 Thread Avi Kivity
Signed-off-by: Avi Kivity --- memory.c | 32 memory.h | 17 + 2 files changed, 49 insertions(+), 0 deletions(-) diff --git a/memory.c b/memory.c index 62bd60b..bb04952 100644 --- a/memory.c +++ b/memory.c @@ -211,6 +211,21 @@ static AddressSpa

[Qemu-devel] [PATCH 23/23] usb-ohci: convert to MemoryRegion

2011-07-25 Thread Avi Kivity
Signed-off-by: Avi Kivity --- hw/usb-ohci.c | 42 +- 1 files changed, 17 insertions(+), 25 deletions(-) diff --git a/hw/usb-ohci.c b/hw/usb-ohci.c index 8491d59..337b250 100644 --- a/hw/usb-ohci.c +++ b/hw/usb-ohci.c @@ -62,7 +62,7 @@ typedef struct OHCI

Re: [Qemu-devel] [PATCH 11/23] memory: add ioeventfd support

2011-07-25 Thread Avi Kivity
On 07/25/2011 06:22 PM, malc wrote: > > > +} > > > +if (a.fd< b.fd) { > > > +return true; > > > +} else { if (a.fd> b.fd) { > > > +return false; > > > +} } CODING_STYLE permits braceless else if.

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Jes Sorensen
On 07/25/11 17:24, Avi Kivity wrote: > On 07/25/2011 06:21 PM, Jes Sorensen wrote: >> On 07/25/11 17:20, Avi Kivity wrote: >> > On 07/25/2011 06:17 PM, Jes Sorensen wrote: >> >> Using the commands consistently does have an impact, and at least >> with >> >> qemu_malloc() it is obvious what they

Re: [Qemu-devel] [PATCH 00/55] Block layer cleanup & fixes

2011-07-25 Thread Markus Armbruster
Amit Shah writes: > On (Wed) 20 Jul 2011 [18:23:34], Markus Armbruster wrote: >> This patch series looks bigger than it is. All the patches are small >> and hopefully easy to review. >> >> Objectives: >> >> * Push BlockDriverState members locked, tray_open, media_changed into >> device model

Re: [Qemu-devel] [PATCH] Introduce QEMU_NEW()

2011-07-25 Thread Avi Kivity
On 07/25/2011 06:28 PM, Jes Sorensen wrote: > > I guess type safety doesn't matter to you. In my experience it's one of the lesser problems in the code. It's a big issue to someone making widespread changes in the code (like me now). -- error compiling committee.c: too many arguments to f

Re: [Qemu-devel] [PATCH 11/23] memory: add ioeventfd support

2011-07-25 Thread malc
On Mon, 25 Jul 2011, Avi Kivity wrote: > On 07/25/2011 06:22 PM, malc wrote: > > > > > +} > > > > > +if (a.fd< b.fd) { > > > > > +return true; > > > > > +} else { > > if (a.fd> b.fd) { > > > > > +return false; > > > > >

Re: [Qemu-devel] qemu 0.12 monitor command syntax and interface

2011-07-25 Thread Markus Armbruster
Vinay Venkataraghavan writes: > Hi all, > > I am implementing a generic interface that supports qemu versions 0.9 to > 0.12. > > > As a result I have been trying to get the syntax for the monitor commands for > various qemu versions. I have scrounged all over but have not been able to > find

Re: [Qemu-devel] [PATCH 11/23] memory: add ioeventfd support

2011-07-25 Thread Avi Kivity
On 07/25/2011 06:38 PM, malc wrote: On Mon, 25 Jul 2011, Avi Kivity wrote: > On 07/25/2011 06:22 PM, malc wrote: > > > > >+} > > > > >+if (a.fd > > > >+return true; > > > > >+} else { > > if (a.fd>b.

Re: [Qemu-devel] [PATCH 0/7] balloon: cleanups, fix segfault

2011-07-25 Thread Amit Shah
On (Mon) 25 Jul 2011 [16:13:33], Markus Armbruster wrote: > Amit Shah writes: > > > 'balloon 0' in the monitor causes a segfault. This happens because > > the function that handles change in balloon values is also tasked with > > handling stats retrieval from the guest, and it does the retrieval

Re: [Qemu-devel] [Qemu-trivial] [PATCH] Makefile: fix out-of-tree builds

2011-07-25 Thread Alexandre Raymond
Hi guys, Thank you for investigating this problem. I finally found out why this problem occured in the first place. It is a combination of the bug you just described and the fact that "make distclean" only deletes the build directories of the targets specified *in the last call to configure*. e.

[Qemu-devel] idea: non-ethernet paravirtual network device

2011-07-25 Thread Sassan Panahinejad
Hi all, Here's a thought, could we improve network performance by creating a paravirtual network device which doesn't emulate ethernet? It shouldn't be too hard to just whack IP packets pretty much directly over a virtio link. This should improve performance when using a "user" host connection and

Re: [Qemu-devel] [RFC PATCH 0/2] Signal fixes for OSX

2011-07-25 Thread Alexandre Raymond
Please ignore this patch series. It is most definitely wrong. Alexandre On Wed, Jul 20, 2011 at 1:01 AM, Alexandre Raymond wrote: > This series fixes a race condition that occurs under OS X. > > It also reworks the signal initialization to make it simpler for later > maintenance/additions. > > N

[Qemu-devel] [PATCH] CODING_STYLE: explicitly allow braceless 'else if'

2011-07-25 Thread Avi Kivity
It's already allowed by the example; there are about 1800 instances in the tree; and disallowing it would lead to if (a) { ... } else { if (b) { ... } else { if (c) { ... } else { if (d) {

Re: [Qemu-devel] [PATCH 5/6] scsi-disk: Remove 'drive_kind'

2011-07-25 Thread Markus Armbruster
Hannes Reinecke writes: > Instead of using its own definitions scsi-disk should > be using the device type of the parent device. > > Signed-off-by: Hannes Reinecke > --- > hw/scsi-defs.h |6 +- > hw/scsi-disk.c | 48 > 2 files changed,

Re: [Qemu-devel] [PATCH 0/6][v2] Check for supported SCSI commands

2011-07-25 Thread Markus Armbruster
Hannes Reinecke writes: > Markus Armbruster pointed out that not every SCSI command is supported > for a given device type. Based on his patch and suggestiongs this series > cleans up the SCSI device type and adds a check for supported commands. I like this series. It conflicts with mine. I ca

[Qemu-devel] [PATCH] Allow to leave type on default in -machine

2011-07-25 Thread Jan Kiszka
On 2011-07-25 13:48, Jan Kiszka wrote: > On 2011-07-25 13:39, Markus Armbruster wrote: >> Jan Kiszka writes: >> >>> On 2011-07-25 12:45, Richard W.M. Jones wrote: On Mon, Jul 25, 2011 at 12:33:01PM +0200, Jan Kiszka wrote: > On 2011-07-25 11:41, Richard W.M. Jones wrote: >> On Sat, Ju

Re: [Qemu-devel] [PATCH] Allow to leave type on default in -machine

2011-07-25 Thread Richard W.M. Jones
On Mon, Jul 25, 2011 at 06:11:20PM +0200, Jan Kiszka wrote: > I was incorrectly pointing the core, the problem is solvable at the > level where we parse -machine: > > ---8< > > This allows to specify -machine options without setting an explicit > machine type. We will pick the default

Re: [Qemu-devel] [PATCH] Allow to leave type on default in -machine

2011-07-25 Thread Alexander Graf
On 25.07.2011, at 18:21, Richard W.M. Jones wrote: > On Mon, Jul 25, 2011 at 06:11:20PM +0200, Jan Kiszka wrote: >> I was incorrectly pointing the core, the problem is solvable at the >> level where we parse -machine: >> >> ---8< >> >> This allows to specify -machine options without

[Qemu-devel] [Bug 814222] Re: kvm cannot use vhd files over 127GB

2011-07-25 Thread Serge Hallyn
** Also affects: qemu Importance: Undecided Status: New ** Changed in: qemu-kvm (Ubuntu) Status: New => Confirmed -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/814222 Title: kvm c

Re: [Qemu-devel] [PATCH v2 1/2] qapi: check for python, allow path to be specified

2011-07-25 Thread Blue Swirl
On Mon, Jul 25, 2011 at 5:55 PM, Michael Roth wrote: > On 07/25/2011 09:36 AM, Blue Swirl wrote: >> >> On Sun, Jul 24, 2011 at 9:36 PM, Michael Roth >>  wrote: >>> >>> QAPI requires python to generate code. Check for python during >>> configuration and allow python to be specified manually. >> >>

[Qemu-devel] [Bug 814222] Re: kvm cannot use vhd files over 127GB

2011-07-25 Thread Serge Hallyn
@Matthew thanks for the attachments. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/814222 Title: kvm cannot use vhd files over 127GB Status in QEMU: New Status in “qemu-kvm” package in Ubuntu:

Re: [Qemu-devel] [PATCH] CODING_STYLE: explicitly allow braceless 'else if'

2011-07-25 Thread Blue Swirl
On Mon, Jul 25, 2011 at 6:55 PM, Avi Kivity wrote: > It's already allowed by the example; there are about 1800 instances in the > tree; and disallowing it would lead to > >    if (a) { >        ... >    } else { >        if (b) { >            ... >        } else { >            if (c) { >          

Re: [Qemu-devel] Need to find OS running in VMs

2011-07-25 Thread Mulyadi Santosa
On Mon, Jul 25, 2011 at 21:52, bharath pb wrote: > Hi, > >   how to find which OS running in my VMs..? just check the SDL graphic output? its console or window? -- regards, Mulyadi Santosa Freelance Linux trainer and consultant blog: the-hydra.blogspot.com training: mulyaditraining.blogspot.

Re: [Qemu-devel] [PATCH 10/55] ide: Update command code definitions as per ACS-2 Table B.2

2011-07-25 Thread Markus Armbruster
Christoph Hellwig writes: > On Wed, Jul 20, 2011 at 06:23:44PM +0200, Markus Armbruster wrote: >> Drop WIN_SRST, it has same value as WIN_DEVICE_RESET. >> >> CFA_IDLEIMMEDIATE isn't specific to CFATA. ACS-2 shows it as a >> defined command in ATA-1, -2 and -3. Rename to WIN_IDLEIMMEDIATE2. >>

[Qemu-devel] [PATCH] fix disabling interrupts in sun4u

2011-07-25 Thread Artyom Tarasenko
clear interrupt request if the interrupt priority < CPU pil clear hardware interrupt request if interrupts are disabled Signed-off-by: Artyom Tarasenko --- hw/sun4u.c |6 -- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/hw/sun4u.c b/hw/sun4u.c index d7dcaf0..7f95aeb 1006

[Qemu-devel] [Bug 814222] Re: kvm cannot use vhd files over 127GB

2011-07-25 Thread Serge Hallyn
** Patch added: "proposed fix for upstream qemu" https://bugs.launchpad.net/qemu/+bug/814222/+attachment/2231766/+files/0001-block-vpc.c-Detect-too-large-vpc-file.patch -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.

Re: [Qemu-devel] [PATCH 01/23] Hierarchical memory region API

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: The memory API separates the attributes of a memory region (its size, how reads or writes are handled, dirty logging, and coalescing) from where it is mapped and whether it is enabled. This allows a device to configure a memory region once, then hand it

[Qemu-devel] [Bug 814222] Re: kvm cannot use vhd files over 127GB

2011-07-25 Thread Serge Hallyn
** Changed in: qemu-kvm (Ubuntu) Status: Confirmed => Triaged -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/814222 Title: kvm cannot use vhd files over 127GB Status in QEMU: New Status in

Re: [Qemu-devel] [PATCH 02/23] memory: implement dirty tracking

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: Currently dirty tracking is implemented by passing through all calls to the underlying cpu_physical_memory_*() calls. Signed-off-by: Avi Kivity Ah, I see, you're fixing FIXMEs in updated patches before anything uses it. Reviewed-by: Anthony Liguori

Re: [Qemu-devel] [PATCH 03/23] memory: merge adjacent segments of a single memory region

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: Simple implementations of memory routers, for example the Cirrus VGA memory banks or the 440FX PAM registers can generate adjacent memory regions which are contiguous. Detect these and merge them; this saves kvm memory slots and shortens lookup times.

Re: [Qemu-devel] [PATCH 04/23] Internal interfaces for memory API

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: get_system_memory() provides the root of the memory hierarchy. This interface is intended to be private between memory.c and exec.c. If this file is included elsewhere, it should be regarded as a bug (or TODO item). However, it will be temporarily neede

Re: [Qemu-devel] [PATCH 05/23] memory: abstract address space operations

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: Prepare for multiple address space support by abstracting away the details of registering a memory range with qemu's flat representation into an AddressSpace object. Note operations which are memory specific are not abstracted, since they will never be c

Re: [Qemu-devel] [PATCH 06/23] memory: rename MemoryRegion::has_ram_addr to ::terminates

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: I/O regions will not have ram_addrs, so this is a better name. Signed-off-by: Avi Kivity Reviewed-by: Anthony Liguori Although it seems squashable. Regards, Anthony Liguori --- memory.c | 18 +- memory.h |2 +- 2 files c

Re: [Qemu-devel] [PATCH 08/23] memory: I/O address space support

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: Allow registering I/O ports via the same mechanism as mmio ranges. Signed-off-by: Avi Kivity Reviewed-by: Anthony Liguori Regards, Anthony Liguori --- exec-memory.h |3 ++ memory.c | 60 +++

Re: [Qemu-devel] [PATCH 09/23] memory: add backward compatibility for old portio registration

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: Signed-off-by: Avi Kivity Reviewed-by: Anthony Liguori Regards, Anthony Liguori --- memory.c | 32 memory.h | 17 + 2 files changed, 49 insertions(+), 0 deletions(-) diff --git a/memory.c b/

Re: [Qemu-devel] [PATCH 10/23] memory: add backward compatibility for old mmio registration

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: This eases the transition to the new API. Signed-off-by: Avi Kivity Reviewed-by: Anthony Liguori Regards, Anthony Liguori --- memory.c | 10 ++ memory.h | 10 ++ 2 files changed, 20 insertions(+), 0 deletions(-) diff --git

Re: [Qemu-devel] [PATCH 11/23] memory: add ioeventfd support

2011-07-25 Thread Anthony Liguori
On 07/25/2011 09:02 AM, Avi Kivity wrote: As with the rest of the memory API, the caller associates an eventfd with an address, and the memory API takes care of registering or unregistering when the address is made visible or invisible to the guest. Signed-off-by: Avi Kivity --- memory.c | 23

[Qemu-devel] [PATCH 1/1] block/vpc.c: Detect too-large vpc file

2011-07-25 Thread Serge E. Hallyn
VHD files technically can be up to 2Tb, but virtual pc is limited to 127G. Currently qemu-img refused to create vpc files > 127G, but it is failing to return error when converting from a non-vpc VHD file which is >127G. It returns success, but creates a truncated converted image. Also, qemu-img

<    1   2   3   >