Re: [Qemu-devel] Re: [sneak preview] major scsi overhaul

2009-11-12 Thread Hannes Reinecke
Gerd Hoffmann wrote: On 11/11/09 14:30, Hannes Reinecke wrote: Gerd Hoffmann wrote: How about sticking a 'void *hba_private' element into SCSIRequest instead? Would work for me, too. Pushed (scsi.v7 now). Okay, I've converted the driver. Works so far. One minor nitpick, though: diff

[Qemu-devel] Re: [PATCH 01/20] pci: fix pci_info_device().

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:29PM +0900, Isaku Yamahata wrote: It printed wrong limit value of bridge. This patch fixes it. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |2 +- 1 files changed, 1 insertions(+), 1

[Qemu-devel] Re: [PATCH 02/20] pci: move pci_data_{read, write}() declaration from pci.h to pci_host.h

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:30PM +0900, Isaku Yamahata wrote: Now pci host stuff has been moved from pci.[hc] to pci_host.[hc] so the declaration of pci_data_{read, write}() should be in pci_host.h This patch moves them from pci.h to pci_host.h for consistency. Signed-off-by: Isaku

[Qemu-devel] Re: [PATCH 11/20] pci: clean up of pci_init_wmask().

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:39PM +0900, Isaku Yamahata wrote: This patch replaces for loop by memset in pci_init_wmask(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |6 +++--- 1 files changed, 3 insertions(+), 3

[Qemu-devel] Re: [PATCH 06/20] pci: shorten pci_host_{conf, data}_register_xxx function a bit.

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:34PM +0900, Isaku Yamahata wrote: pci_host_data_register_io_memory and its variants are too long a bit. So shorten them. Now they are pci_host_{conf, data}_register_{mmio, mmio_noswap, ioport}() Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by:

[Qemu-devel] Re: [PATCH 2/3] qemu_system_reset: we need to call it before loadvm/migration

2009-11-12 Thread Glauber Costa
On Thu, Nov 12, 2009 at 12:39:13AM +0100, Juan Quintela wrote: Signed-off-by: Juan Quintela quint...@redhat.com --- vl.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/vl.c b/vl.c index bf91ee1..fff8e8d 100644 --- a/vl.c +++ b/vl.c @@ -4044,7 +4044,6 @@

[Qemu-devel] Re: [PATCH 09/20] pci_host: remove unnecessary 0xff.

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:37PM +0900, Isaku Yamahata wrote: This patch removes unnecessary 0xff in pci_dev_find_by_addr(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci_host.c |5 +++-- 1 files changed, 3

[Qemu-devel] Re: [PATCH 10/20] pci: kill unnecessary included in pci.c

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:38PM +0900, Isaku Yamahata wrote: including pci_host.h isn't needed by pci.c. This patch kills it. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |1 - 1 files changed, 0 insertions(+), 1

[Qemu-devel] Re: [PATCH 12/20] pci: remove some unnecessary comment in pci.h

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:40PM +0900, Isaku Yamahata wrote: This patch removes some comment which should go into commit log in pci.h. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.h | 11 ++- 1 files changed, 2

[Qemu-devel] Re: [PATCH 13/20] pci: move typedef, PCIHostState, PCIExpressHost to qemu-common.h.

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:41PM +0900, Isaku Yamahata wrote: This patch moves two typedefs, PCIHostState and PCIExpressHost to qemu-common.h for consistency as PCIBus and PCIDevice are typedefed in qemu-common.h. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S.

[Qemu-devel] Re: [PATCH 14/20] pci: remove unused constants.

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:42PM +0900, Isaku Yamahata wrote: This patch removes unused constants committed by fb23162885f7fd8cf7334bed22c25ac32c7d8b9d. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.h |9 - 1

[Qemu-devel] Re: [PATCH 15/20] pci: clean up of pci_update_mappings()

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:43PM +0900, Isaku Yamahata wrote: This patch converts r-size == 0 to !r_size. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff

[Qemu-devel] Re: [PATCH 17/20] pci: remove magic number, 256 in pci.c

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:45PM +0900, Isaku Yamahata wrote: This patch replaces magic number, 256, with ARRAY_SIZE(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |5 +++-- 1 files changed, 3 insertions(+), 2

[Qemu-devel] Re: [PATCH 18/20] pci: fix pci_config_get_io_base().

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:46PM +0900, Isaku Yamahata wrote: fix typo in pci_config_get_io_base(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git

[Qemu-devel] Re: [PATCH 07/20] pci: remove pci_sub_bus() by open coding.

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:35PM +0900, Isaku Yamahata wrote: Because pci_sub_bus() is used only once so eliminate it by open coding as suggested by Michael S. Tsirkin m...@redhat.com. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com As a

[Qemu-devel] Re: [PATCH 08/20] pci: s/pci_find_host_bus/pci_find_root_bus/g

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:36PM +0900, Isaku Yamahata wrote: This patch renames pci_find_host_bus() to pci_find_root_bus() as suggested by Michael S. Tsirkin m...@redhat.com. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com ---

[Qemu-devel] Re: [PATCH 19/20] pci: pci bridge related clean up.

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:47PM +0900, Isaku Yamahata wrote: - fix bridge prefetchable memory accesser to check 64bit or not. - use pcibus_t consistently instead mixing pcibus_t and uint64_t. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com

[Qemu-devel] Re: [PATCH 03/20] pci: simplify pci_data_read(), pcie_mmcfg_data_read().

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:31PM +0900, Isaku Yamahata wrote: simplify ugly switch by memcpy trick. And add one assert(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp In fact, there's no reason to be so careful about zeroing out high bits as far as I can tell: in the end, the value

[Qemu-devel] Re: [PATCH 04/20] pci: remove pci_addr_to_config() by open code

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:32PM +0900, Isaku Yamahata wrote: This patch removes pci_addr_to_config() and open code it as suggested by Michael S. Tsirkin m...@redhat.com. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci_host.c

[Qemu-devel] Re: [PATCH 05/20] pci: rename pci_addr_to_dev(), pcie_mmcfg_addr_to_dev().

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:33PM +0900, Isaku Yamahata wrote: This patch renames pci_addr_to_dev(), pcie_mmcfg_addr_to_dev() to pci_dev_find_by_addr(), pcie_dev_find_by_mmcfg_addr() as Michael S. Tsirkin m...@redhat.com suggested. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp

[Qemu-devel] Re: [PATCH 03/20] pci: simplify pci_data_read(), pcie_mmcfg_data_read().

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 01:01:09PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 02:58:31PM +0900, Isaku Yamahata wrote: simplify ugly switch by memcpy trick. And add one assert(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp In fact, there's no reason to be so

[Qemu-devel] Stack corruption problem with SeaBIOS/gPXE under QEMU

2009-11-12 Thread Naphtali Sprei
Hi, I've found a problem with the usage of SeaBIOS/gPXE in Qemu. The scenario is when failing to boot from network and falling back to booting from hard-disk (-boot nc). The cause of the problem is that both SeaBIOS and gPXE (in it's installation phase) uses same stack area, 0x7c00. The gPXE

[Qemu-devel] [PATCH] megasas: LSI MegaRAID SAS HBA emulation

2009-11-12 Thread Hannes Reinecke
This patch adds an emulation for the LSI MegaRAID SAS HBA. It is build on top of kraxel's scsi.v7 tree. This is just a rough implementation, many of the more advanced topics (like Windows booting :-) are missing. Signed-off-by: Hannes Reinecke h...@suse.de -- diff --git a/Makefile.hw

[Qemu-devel] Seabios vs. -enable-kvm: Slow framebuffer console setup

2009-11-12 Thread Jan Kiszka
Hi, when booting qemu in kvm mode into a framebuffer console (vga=0x317 here), the mode switch is terribly slow under Seabios. -bios pcbios.bin does not show this behavior. Outputs done later look fine and reasonably fast. Anyone any thoughts on this? Jan -- Siemens AG, Corporate Technology,

[Qemu-devel] Re: [PATCH 03/20] pci: simplify pci_data_read(), pcie_mmcfg_data_read().

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 01:15:25PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 01:01:09PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 02:58:31PM +0900, Isaku Yamahata wrote: simplify ugly switch by memcpy trick. And add one assert(). Signed-off-by: Isaku

[Qemu-devel] Re: [PATCH 16/20] pci: kill goto in pci_update_mappings()

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:44PM +0900, Isaku Yamahata wrote: This patch kills nasty goto in pci_update_mappings(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp --- hw/pci.c | 54 -- 1 files changed, 28 insertions(+), 26

[Qemu-devel] Re: [PATCH 20/20] pci: remove goto in pci_bridge_filter().

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:48PM +0900, Isaku Yamahata wrote: This patch removes ugly goto in pci_bridge_filter() by introducing subfunction, pci_bridge_filter_nomap(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp goto on error is actually cleaner IMO. just *not into scope*. ---

[Qemu-devel] Re: [PATCH 03/20] pci: simplify pci_data_read(), pcie_mmcfg_data_read().

2009-11-12 Thread Isaku Yamahata
On Thu, Nov 12, 2009 at 02:02:45PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 01:15:25PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 01:01:09PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 02:58:31PM +0900, Isaku Yamahata wrote: simplify ugly switch

[Qemu-devel] Re: [PATCH 02/20] pci: move pci_data_{read, write}() declaration from pci.h to pci_host.h

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:30PM +0900, Isaku Yamahata wrote: Now pci host stuff has been moved from pci.[hc] to pci_host.[hc] so the declaration of pci_data_{read, write}() should be in pci_host.h This patch moves them from pci.h to pci_host.h for consistency. Signed-off-by: Isaku

[Qemu-devel] Re: [PATCH 07/20] pci: remove pci_sub_bus() by open coding.

2009-11-12 Thread Isaku Yamahata
On Thu, Nov 12, 2009 at 12:45:08PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 02:58:35PM +0900, Isaku Yamahata wrote: Because pci_sub_bus() is used only once so eliminate it by open coding as suggested by Michael S. Tsirkin m...@redhat.com. Signed-off-by: Isaku Yamahata

[Qemu-devel] Re: [PATCH 00/20] PCI express clean up patches.

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 02:58:28PM +0900, Isaku Yamahata wrote: Here is the patch series to clean up PCI express patches. Although there remained some issues to address, the PCI express patches was commited while I wasn't responsive last week. (Sorry for that) This patch series addresses the

[Qemu-devel] Re: [PATCH] fdc: Fix vmsave/restore regression

2009-11-12 Thread Juan Quintela
Jan Kiszka jan.kis...@web.de wrote: *** NOTE *** 'git shortlog|grep reset + vmsd' shows 10 such conversions. I only briefly checked the first one, and it looks similar broken. Could someone have a second look at them? Maybe it is also better to define a vmsd opaque in DeviceInfo, which would

[Qemu-devel] Re: [PATCH 16/20] pci: kill goto in pci_update_mappings()

2009-11-12 Thread Isaku Yamahata
On Thu, Nov 12, 2009 at 02:06:22PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 02:58:44PM +0900, Isaku Yamahata wrote: This patch kills nasty goto in pci_update_mappings(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp --- hw/pci.c | 54

[Qemu-devel] Re: [PATCH] fdc: Fix vmsave/restore regression

2009-11-12 Thread Jan Kiszka
Juan Quintela wrote: Jan Kiszka jan.kis...@web.de wrote: *** NOTE *** 'git shortlog|grep reset + vmsd' shows 10 such conversions. I only briefly checked the first one, and it looks similar broken. Could someone have a second look at them? Maybe it is also better to define a vmsd opaque in

[Qemu-devel] Re: [PATCH 20/20] pci: remove goto in pci_bridge_filter().

2009-11-12 Thread Isaku Yamahata
On Thu, Nov 12, 2009 at 02:08:05PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 02:58:48PM +0900, Isaku Yamahata wrote: This patch removes ugly goto in pci_bridge_filter() by introducing subfunction, pci_bridge_filter_nomap(). Signed-off-by: Isaku Yamahata

[Qemu-devel] Re: [PATCH 16/20] pci: kill goto in pci_update_mappings()

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 10:12:07PM +0900, Isaku Yamahata wrote: On Thu, Nov 12, 2009 at 02:06:22PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 02:58:44PM +0900, Isaku Yamahata wrote: This patch kills nasty goto in pci_update_mappings(). Signed-off-by: Isaku Yamahata

[Qemu-devel] Re: [PATCH 16/20] pci: kill goto in pci_update_mappings()

2009-11-12 Thread Michael S. Tsirkin
On Thu, Nov 12, 2009 at 10:12:07PM +0900, Isaku Yamahata wrote: On Thu, Nov 12, 2009 at 02:06:22PM +0200, Michael S. Tsirkin wrote: On Thu, Nov 12, 2009 at 02:58:44PM +0900, Isaku Yamahata wrote: This patch kills nasty goto in pci_update_mappings(). Signed-off-by: Isaku Yamahata

Re: [Qemu-devel] [RFC 0/8]: QError v2

2009-11-12 Thread Luiz Capitulino
On Wed, 11 Nov 2009 15:20:30 -0600 Anthony Liguori anth...@codemonkey.ws wrote: Luiz Capitulino wrote: Hi, I can't remember seeing updated versions of a RFC series, but this should prevent Anthony's scripts from merging these patches. This new QError version has two major changes:

[Qemu-devel] Re: [PATCH] fdc: Fix vmsave/restore regression

2009-11-12 Thread Juan Quintela
Jan Kiszka jan.kis...@web.de wrote: Juan Quintela wrote: Jan Kiszka jan.kis...@web.de wrote: *** NOTE *** 'git shortlog|grep reset + vmsd' shows 10 such conversions. I only briefly checked the first one, and it looks similar broken. Could someone have a second look at them? Maybe it is also

Re: [Qemu-devel] [RFC 0/8]: QError v2

2009-11-12 Thread Anthony Liguori
Luiz Capitulino wrote: #define QERR_DEVICE_ALREADY_OPEN {'class': 'DeviceAlreadyOpen', 'data' : {'bus_num': %d, 'addr': %d} qemu_error_new(QERR_DEVICE_ALREADY_OPEN, bus_num, addr); What about DeviceAlreadyOpen errors with a different argument list? Why would you have this? That

Re: [Qemu-devel] [PATCH 0/6] Fix -kernel with SeaBIOS

2009-11-12 Thread Christoph Hellwig
Thanks Alexander, I hope this goes into qemu.git ASAP - without it it's totally unusable for my test setup, and it of course bit my silently when preparing a demo for a confernence where only reverting back to and older qemu helped..

Re: [Qemu-devel] [PATCH 0/6] Fix -kernel with SeaBIOS

2009-11-12 Thread Alexander Graf
Am 12.11.2009 um 15:53 schrieb Christoph Hellwig h...@lst.de: Thanks Alexander, I hope this goes into qemu.git ASAP - without it it's totally unusable for my test setup, and it of course bit my silently when preparing a demo for a confernence where only reverting back to and older qemu

Re: [Qemu-devel] [RFC 0/8]: QError v2

2009-11-12 Thread Luiz Capitulino
On Thu, 12 Nov 2009 08:44:03 -0600 Anthony Liguori aligu...@linux.vnet.ibm.com wrote: Luiz Capitulino wrote: #define QERR_DEVICE_ALREADY_OPEN {'class': 'DeviceAlreadyOpen', 'data' : {'bus_num': %d, 'addr': %d} qemu_error_new(QERR_DEVICE_ALREADY_OPEN, bus_num, addr); What

Re: [Qemu-devel] [RFC 0/8]: QError v2

2009-11-12 Thread Anthony Liguori
Luiz Capitulino wrote: On Thu, 12 Nov 2009 08:44:03 -0600 Anthony Liguori aligu...@linux.vnet.ibm.com wrote: Luiz Capitulino wrote: #define QERR_DEVICE_ALREADY_OPEN {'class': 'DeviceAlreadyOpen', 'data' : {'bus_num': %d, 'addr': %d} qemu_error_new(QERR_DEVICE_ALREADY_OPEN, bus_num,

Re: [Qemu-devel] [PATCH] EHCI emulation module for review

2009-11-12 Thread Michael Trimarchi
Hi, Michael Trimarchi wrote: Hi, I'm working on this patch and I have some trouble after a data IN transaction. I submit the urb but I don't receive any async completation. 88011e512140 2614190796 S Ii:2:008:7 -115:128 16 husb: data submit. ep 0x87 len 16 aurb 0xcf3850 So the state

Re: [Qemu-devel] [PATCH 02/11] Add operations to qlist to allow it to be used as a stack

2009-11-12 Thread Kevin Wolf
Am 11.11.2009 18:28, schrieb Anthony Liguori: This makes lists no longer invariant. It's a very useful bit of functionality though. To deal with the fact that lists are no longer invariant, introduce a deep copy mechanism for lists. Signed-off-by: Anthony Liguori aligu...@us.ibm.com ---

Re: [Qemu-devel] [PATCH 02/11] Add operations to qlist to allow it to be used as a stack

2009-11-12 Thread Anthony Liguori
Kevin Wolf wrote: Am 11.11.2009 18:28, schrieb Anthony Liguori: This makes lists no longer invariant. It's a very useful bit of functionality though. To deal with the fact that lists are no longer invariant, introduce a deep copy mechanism for lists. Signed-off-by: Anthony Liguori

Re: [Qemu-devel] [PATCH 02/11] Add operations to qlist to allow it to be used as a stack

2009-11-12 Thread Kevin Wolf
Am 12.11.2009 17:46, schrieb Anthony Liguori: Kevin Wolf wrote: Am 11.11.2009 18:28, schrieb Anthony Liguori: This makes lists no longer invariant. It's a very useful bit of functionality though. To deal with the fact that lists are no longer invariant, introduce a deep copy mechanism

Re: [Qemu-devel] [PATCH 02/11] Add operations to qlist to allow it to be used as a stack

2009-11-12 Thread Anthony Liguori
Kevin Wolf wrote: Unfortunately. There are places where such comments could be a good specification on what an interface is actually meant to work like (particularly in error cases). Currently you often can't tell if the implementation or the caller of a function is buggy. Not sure if they are

Re: [Qemu-devel] [PATCH 02/11] Add operations to qlist to allow it to be used as a stack

2009-11-12 Thread Luiz Capitulino
On Thu, 12 Nov 2009 11:13:45 -0600 Anthony Liguori aligu...@linux.vnet.ibm.com wrote: Kevin Wolf wrote: Unfortunately. There are places where such comments could be a good specification on what an interface is actually meant to work like (particularly in error cases). Currently you often

Re: [Qemu-devel] arm, mips and mipsel broken

2009-11-12 Thread Stefan Weil
Aurelien Jarno schrieb: Please note that at least qemu-system-arm, qemu-system-mips and qemu-system-mipsel are broken by this commit: commit c169998802505c244b8bcad562633f29de7d74a4 Author: Glauber Costa glom...@redhat.com Date: Thu Nov 5 16:05:15 2009 -0200 v3: don't call reset functions

Re: [Qemu-devel] [PATCH 02/11] Add operations to qlist to allow it to be used as a stack

2009-11-12 Thread Ian Molton
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Kevin Wolf wrote: I think in general qemu is poorly commented. I think thats a bit of an understatement. in particular I'm finding the options code to be a nightmare. Hopefully I'll be fixing some of that in my upcomming submissions. -BEGIN PGP

[Qemu-devel] [PATCH] This patch adds a Priority and a Machine menu to the menu bar.

2009-11-12 Thread G 3
The Priority menu controls how much cpu time qemu receives, and the Machine menu has the Restart menu item for restarting the emulator. Signed-off-by: John Arbuckle programmingk...@gmail.com --- cocoa.m | 91 + + 1 files changed,

[Qemu-devel] [PATCH] Makefile: Remove unneeded prerequisites

2009-11-12 Thread Stefan Weil
Thanks to f527c57935e22b56952d1ed1af36070b682ecf70 (fix parallel build), these prerequisites are redundant now and can be removed. Signed-off-by: Stefan Weil w...@mail.berlios.de --- Makefile |4 +--- 1 files changed, 1 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index

[Qemu-devel] [PATCH 5/7] qdev: add qdev_foreach()

2009-11-12 Thread Mark McLoughlin
No doubt this is the worst idea ever, but the requirement is simple - some way to iterate all NICs in the system. Signed-off-by: Mark McLoughlin mar...@redhat.com --- hw/qdev.c | 20 hw/qdev.h |3 +++ 2 files changed, 23 insertions(+), 0 deletions(-) diff --git

[Qemu-devel] [PATCH 6/7] qdev: add qdev_prop_get_{macaddr, net_client}()

2009-11-12 Thread Mark McLoughlin
Probably the second worst idea in the world, ever. While iterating over all NICs in the system, we need to be able to query their 'net-client' and 'macaddr' properties. Signed-off-by: Mark McLoughlin mar...@redhat.com --- hw/qdev-properties.c | 31 --- hw/qdev.h

[Qemu-devel] [PATCH 1/7] net: remove NICInfo::vc

2009-11-12 Thread Mark McLoughlin
Since 1cc33683, this field is not set for most devices, so just remove it and its remaining few uses. Signed-off-by: Mark McLoughlin mar...@redhat.com --- hw/dp8393x.c | 10 +- hw/etraxfs_eth.c | 10 +- hw/mcf_fec.c | 10 +- hw/mipsnet.c | 10

[Qemu-devel] [RFC PATCH 0/7] Fix qemu_announce_self() properly

2009-11-12 Thread Mark McLoughlin
Hi, The recent fix to qemu_announce_self() will segfault if you use -netdev. The real root cause of the regression was the removal of the assignment to NICInfo::vc that used to live in qdev_get_vlan_client(). Now that NICs are qdev-ified, we should just iterate over the qdev tree

[Qemu-devel] [PATCH 7/7] net: fix qemu_announce_self()

2009-11-12 Thread Mark McLoughlin
Now that we have a sane way of iterating over NICs. Signed-off-by: Mark McLoughlin mar...@redhat.com --- savevm.c | 43 ++- 1 files changed, 26 insertions(+), 17 deletions(-) diff --git a/savevm.c b/savevm.c index 039740c..3736588 100644 --- a/savevm.c

[Qemu-devel] [PATCH 2/7] qdev: add net-client property

2009-11-12 Thread Mark McLoughlin
Rather than having each NIC create it's own client, let's create the client early and pass it down to the NIC. One advantage is that we can add parameters which only the client knows about, without having the NIC know anything about it - e.g. NICs shouldn't know about netdev vs. vlan. Another

[Qemu-devel] [PATCH 3/7] net: create the VLANClientState for NICs early

2009-11-12 Thread Mark McLoughlin
Signed-off-by: Mark McLoughlin mar...@redhat.com --- hw/dp8393x.c| 10 +- hw/e1000.c | 10 +- hw/eepro100.c | 10 +- hw/etraxfs_eth.c| 11 +-- hw/mcf_fec.c| 10 +- hw/mipsnet.c| 15 ++-

[Qemu-devel] [PATCH 4/7] net: kill off NICInfo/NICConf::vlan/netdev

2009-11-12 Thread Mark McLoughlin
No valid users left except the announce_self() code which currently crashes when used with -netdev. Note the assertion in the xen code. Need to figure out how to support the -netdev arg with xen. Signed-off-by: Mark McLoughlin mar...@redhat.com --- hw/integratorcp.c|3 +- hw/mcf5208.c

[Qemu-devel] [PATCH 0/9]: QError v3

2009-11-12 Thread Luiz Capitulino
Hi, This is a new QError version which implements what has been suggested by Anthony in this email: http://lists.gnu.org/archive/html/qemu-devel/2009-11/msg00601.html Basically, the error table is back and qemu_error_new() calls are like this: qemu_error_new(QERR_DEVICE_NOT_FOUND, driver);

[Qemu-devel] [PATCH 1/9] QJSON: Introduce qobject_from_json_va()

2009-11-12 Thread Luiz Capitulino
Accepts a va_list, will be used by QError. Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- qjson.c | 14 ++ qjson.h |2 ++ 2 files changed, 16 insertions(+), 0 deletions(-) diff --git a/qjson.c b/qjson.c index 7270909..491b61e 100644 --- a/qjson.c +++ b/qjson.c @@

[Qemu-devel] [PATCH 2/9] QString: Introduce qstring_append_chr()

2009-11-12 Thread Luiz Capitulino
It appends a C char to a QString. Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- qstring.c | 24 +++- qstring.h |1 + 2 files changed, 20 insertions(+), 5 deletions(-) diff --git a/qstring.c b/qstring.c index 441a9e6..e422bd9 100644 --- a/qstring.c +++

[Qemu-devel] [PATCH 3/9] QString: Introduce qstring_append_int()

2009-11-12 Thread Luiz Capitulino
Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- qstring.c |8 qstring.h |2 ++ 2 files changed, 10 insertions(+), 0 deletions(-) diff --git a/qstring.c b/qstring.c index e422bd9..ad17769 100644 --- a/qstring.c +++ b/qstring.c @@ -75,6 +75,14 @@ void

[Qemu-devel] [PATCH 4/9] Add qstring_append_chr() unit-test

2009-11-12 Thread Luiz Capitulino
Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- check-qstring.c | 17 + 1 files changed, 17 insertions(+), 0 deletions(-) diff --git a/check-qstring.c b/check-qstring.c index ea4dfd0..412038a 100644 --- a/check-qstring.c +++ b/check-qstring.c @@ -55,6 +55,22 @@

[Qemu-devel] [PATCH 5/9] Introduce QError

2009-11-12 Thread Luiz Capitulino
QError is a high-level data type which represents an exception in QEMU, it stores the following error information: - class Error class name (eg. ServiceUnavailable) - descriptionA detailed error description, which may contain references to run-time error data -

[Qemu-devel] [PATCH 6/9] QJSON: Fix compile error

2009-11-12 Thread Luiz Capitulino
Add QTYPE_QERROR handling in the to_json() switch, otherwise GCC will complain. We just abort(), as QError design is not finished yet. Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- qjson.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/qjson.c b/qjson.c

[Qemu-devel] [PATCH 7/9] monitor: QError support

2009-11-12 Thread Luiz Capitulino
This commit adds QError support in the Monitor. A QError member is added to the Monitor struct. This new member stores error information and is also used to check if an error has occurred when the called handlers returns. Additionally, a new macro called qemu_error_new() is introduced. It should

[Qemu-devel] [PATCH 8/9] qdev: Use QError for 'device not found' error

2009-11-12 Thread Luiz Capitulino
Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- hw/qdev.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/qdev.c b/hw/qdev.c index d19d531..875ca50 100644 --- a/hw/qdev.c +++ b/hw/qdev.c @@ -29,6 +29,7 @@ #include qdev.h #include sysemu.h #include

[Qemu-devel] [PATCH 9/9] monitor: do_info_balloon(): use QError

2009-11-12 Thread Luiz Capitulino
Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- monitor.c |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) diff --git a/monitor.c b/monitor.c index a8fd552..76cb187 100644 --- a/monitor.c +++ b/monitor.c @@ -1717,10 +1717,11 @@ static void do_info_balloon(Monitor *mon,

[Qemu-devel] [PATCH 2/6] Introduce rom_rom

2009-11-12 Thread Alexander Graf
We have several rom helpers currently, but none of them can get us code that spans several roms into a pointer. This patch introduces a function that copies over rom contents. Signed-off-by: Alexander Graf ag...@suse.de --- v1 - v2: - rename copy_rom - rom_copy --- hw/loader.c | 38

[Qemu-devel] [PATCH 4/6] Move common option rom code to header file

2009-11-12 Thread Alexander Graf
We will have a linux boot option rom soon, so let's take all functionality that might be useful for both to a header file that both roms can include. That way we only have to write fw_cfg access code once. Signed-off-by: Alexander Graf ag...@suse.de --- pc-bios/optionrom/multiboot.S | 79

[Qemu-devel] [PATCH 5/6] Convert linux bootrom to external rom and fw_cfg

2009-11-12 Thread Alexander Graf
We already have a working multiboot implementation that uses fw_cfg to get its kernel module etc. data in int19 runtime now. So what's missing is a working linux boot option rom. While at it I figured it would be a good idea to take the opcode generator out of pc.c and instead use a proper option

[Qemu-devel] [PATCH 3/6] Convert multiboot to fw_cfg backed data storage

2009-11-12 Thread Alexander Graf
Right now we load the guest kernel to RAM, fire off the BIOS, hope it doesn't clobber memory and run an option rom that jumps into the kernel. That breaks with SeaBIOS, as that clears memory. So let's read all kernel, module etc. data using the fw_cfg interface when in the int19 handler. This

[Qemu-devel] [PATCH 1/6] Make fw_cfg interface 32-bit aware

2009-11-12 Thread Alexander Graf
The fw_cfg interface can only handle up to 16 bits of data for its streams. While that isn't too much of a problem when handling integers, we would like to stream full kernel images over that interface! So let's extend it to 32 bit length variables. Signed-off-by: Alexander Graf ag...@suse.de

[Qemu-devel] [PATCH 6/6] Add linuxboot to BLOBS

2009-11-12 Thread Alexander Graf
We should install linuxboot.bin too, so let's add it to the to-be-installed blobs. Signed-off-by: Alexander Graf ag...@suse.de --- Makefile |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/Makefile b/Makefile index 30f1c9d..a6647c2 100644 --- a/Makefile +++ b/Makefile @@

Re: [Qemu-devel] [PATCH 1/9] QJSON: Introduce qobject_from_json_va()

2009-11-12 Thread Anthony Liguori
Luiz Capitulino wrote: Accepts a va_list, will be used by QError. Signed-off-by: Luiz Capitulino lcapitul...@redhat.com --- qjson.c | 14 ++ qjson.h |2 ++ 2 files changed, 16 insertions(+), 0 deletions(-) diff --git a/qjson.c b/qjson.c index 7270909..491b61e 100644 ---

[Qemu-devel] Re: [PATCH 1/6] Make fw_cfg interface 32-bit aware

2009-11-12 Thread Glauber Costa
On Thu, Nov 12, 2009 at 09:53:10PM +0100, Alexander Graf wrote: The fw_cfg interface can only handle up to 16 bits of data for its streams. While that isn't too much of a problem when handling integers, we would like to stream full kernel images over that interface! So let's extend it to 32

Re: [Qemu-devel] Re: [PATCH] qemu/virtio: make wmb compiler barrier + comments

2009-11-12 Thread Jamie Lokier
Scott Tsai wrote: I do have a newbie question, when exactly would vrtio have to handle concurrent access from multiple threads? My current reading of the code suggests: 1. when CONFIG_IOTHREAD is true 2. when CONFIG_KVM is true and the guest machine has multiple CPUs It's enough to have

Re: [Qemu-devel] [PATCH 3/3] Add test suite for json marshalling

2009-11-12 Thread Jamie Lokier
Anthony Liguori wrote: After checking that we can demarshal, marshal again and compared to the expected decoded value. This doesn't work so well for floats because they cannot be accurately represented in decimal but we try our best. Good sprintf/scanf/strtod implementations do guarantee

[Qemu-devel] [PATCH V2 05/20] pci: rename pci_addr_to_dev(), pcie_mmcfg_addr_to_dev().

2009-11-12 Thread Isaku Yamahata
This patch renames pci_addr_to_dev(), pcie_mmcfg_addr_to_dev() to pci_dev_find_by_addr(), pcie_dev_find_by_mmcfg_addr() as Michael S. Tsirkin m...@redhat.com suggested. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci_host.c |6

[Qemu-devel] [PATCH V2 03/20] pci: simplify (pci_/pcie_mmcfg_)data_read()

2009-11-12 Thread Isaku Yamahata
From: Michael S. Tsirkin m...@redhat.com Remove switch on length: we don't care about high bits for value, so just return all ones if no device. And add one assert(). Signed-off-by: Michael S. Tsirkin m...@redhat.com Acked-by: Isaku Yamahata yamah...@valinux.co.jp --- hw/pci_host.c | 22

[Qemu-devel] [PATCH V2 07/20] pci: remove pci_sub_bus() by open coding.

2009-11-12 Thread Isaku Yamahata
Because pci_sub_bus() is used only once so eliminate it by open coding as suggested by Michael S. Tsirkin m...@redhat.com. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c | 11 +++ 1 files changed, 3 insertions(+), 8

[Qemu-devel] [PATCH V2 00/20] PCI express clean up patches.

2009-11-12 Thread Isaku Yamahata
Here is the patch series V2 to clean up PCI express patches. Changes from v1: - replaced patches with ones proposed by Michael. - compilation fix. thanks, Isaku Yamahata (17): pci: fix pci_info_device(). pci: move pci_data_{read, write}() declaration from pci.h to pci_host.h pci:

[Qemu-devel] [PATCH V2 09/20] pci_host: remove unnecessary 0xff.

2009-11-12 Thread Isaku Yamahata
This patch removes unnecessary 0xff in pci_dev_find_by_addr(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci_host.c |5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/hw/pci_host.c b/hw/pci_host.c index

[Qemu-devel] [PATCH V2 11/20] pci: clean up of pci_init_wmask().

2009-11-12 Thread Isaku Yamahata
This patch replaces for loop by memset in pci_init_wmask(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index 9c84cb2..2814c51

[Qemu-devel] [PATCH V2 01/20] pci: fix pci_info_device().

2009-11-12 Thread Isaku Yamahata
It printed wrong limit value of bridge. This patch fixes it. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index 2ab1117..4169d4f 100644

[Qemu-devel] [PATCH V2 02/20] pci: move pci_data_{read, write}() declaration from pci.h to pci_host.h

2009-11-12 Thread Isaku Yamahata
Now pci host stuff has been moved from pci.[hc] to pci_host.[hc] so the declaration of pci_data_{read, write}() should be in pci_host.h This patch moves them from pci.h to pci_host.h for consistency. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com

[Qemu-devel] [PATCH V2 13/20] pci: move typedef, PCIHostState, PCIExpressHost to qemu-common.h.

2009-11-12 Thread Isaku Yamahata
This patch moves two typedefs, PCIHostState and PCIExpressHost to qemu-common.h for consistency as PCIBus and PCIDevice are typedefed in qemu-common.h. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci_host.h |4 ++-- hw/pcie_host.h

[Qemu-devel] [PATCH V2 19/20] pci: pci bridge related clean up.

2009-11-12 Thread Isaku Yamahata
- fix bridge prefetchable memory accesser to check 64bit or not. - use pcibus_t consistently instead mixing pcibus_t and uint64_t. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c | 18 +++--- hw/pci.h |1 + 2 files

[Qemu-devel] [PATCH V2 14/20] pci: remove unused constants.

2009-11-12 Thread Isaku Yamahata
This patch removes unused constants committed by fb23162885f7fd8cf7334bed22c25ac32c7d8b9d. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.h |9 - 1 files changed, 0 insertions(+), 9 deletions(-) diff --git a/hw/pci.h

[Qemu-devel] [PATCH V2 17/20] pci: remove magic number, 256 in pci.c

2009-11-12 Thread Isaku Yamahata
This patch replaces magic number, 256, with ARRAY_SIZE(). Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index 24345b0..72b60a7 100644

[Qemu-devel] [PATCH V2 06/20] pci: shorten pci_host_{conf, data}_register_xxx function a bit.

2009-11-12 Thread Isaku Yamahata
pci_host_data_register_io_memory and its variants are too long a bit. So shorten them. Now they are pci_host_{conf, data}_register_{mmio, mmio_noswap, ioport}() Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/apb_pci.c |4 ++--

[Qemu-devel] [PATCH V2 15/20] pci: clean up of pci_update_mappings()

2009-11-12 Thread Isaku Yamahata
This patch converts r-size == 0 to !r_size. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index 2814c51..bb3236c 100644 --- a/hw/pci.c

[Qemu-devel] [PATCH V2 12/20] pci: remove some unnecessary comment in pci.h

2009-11-12 Thread Isaku Yamahata
This patch removes some comment which should go into commit log in pci.h. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.h | 11 ++- 1 files changed, 2 insertions(+), 9 deletions(-) diff --git a/hw/pci.h b/hw/pci.h index

[Qemu-devel] [PATCH V2 10/20] pci: kill unnecessary included in pci.c

2009-11-12 Thread Isaku Yamahata
including pci_host.h isn't needed by pci.c. This patch kills it. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci.c |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index 5ebcba2..9c84cb2

[Qemu-devel] [PATCH V2 08/20] pci: s/pci_find_host_bus/pci_find_root_bus/g

2009-11-12 Thread Isaku Yamahata
This patch renames pci_find_host_bus() to pci_find_root_bus() as suggested by Michael S. Tsirkin m...@redhat.com. Signed-off-by: Isaku Yamahata yamah...@valinux.co.jp Acked-by: Michael S. Tsirkin m...@redhat.com --- hw/pci-hotplug.c |4 ++-- hw/pci.c |8 hw/pci.h

[Qemu-devel] [PATCH V2 16/20] pci: split up up pci_update mappings

2009-11-12 Thread Isaku Yamahata
From: Michael S. Tsirkin m...@redhat.com Split bar address math into a separate function. In particular, this gets rid of an ugly forward goto into scope that we have there. Signed-off-by: Michael S. Tsirkin m...@redhat.com Acked-by: Isaku Yamahata yamah...@valinux.co.jp --- hw/pci.c | 125

  1   2   >