[Qemu-devel] Re: [PATCH 0/9] S390x KVM support

2009-10-21 Thread Alexander Graf
On 20.10.2009, at 18:40, Carsten Otte wrote: Alexander Graf wrote: This is the resulting code. Please comment on things you like and also on the ones you don't :-). I've reviewed and tested it, great work Alex :-) Thanks :-). Also to actually run this code you need a patch for an ugly bu

[Qemu-devel] Re: [PATCH 0/9] S390x KVM support

2009-10-21 Thread Alexander Graf
On 20.10.2009, at 18:40, Carsten Otte wrote: Alexander Graf wrote: This is the resulting code. Please comment on things you like and also on the ones you don't :-). I've reviewed and tested it, great work Alex :-) Also to actually run this code you need a patch for an ugly bug in the ker

[Qemu-devel] Re: [PATCH 0/9] S390x KVM support

2009-10-21 Thread Alexander Graf
On 20.10.2009, at 18:40, Carsten Otte wrote: Alexander Graf wrote: This is the resulting code. Please comment on things you like and also on the ones you don't :-). I've reviewed and tested it, great work Alex :-) Also to actually run this code you need a patch for an ugly bug in the ker

Re: [Qemu-devel] [PATCH] new SDL keyboard shortcuts to start and stop VM

2009-10-21 Thread Kevin Wolf
Am 20.10.2009 19:08, schrieb Daniel P. Berrange: > On Tue, Oct 20, 2009 at 12:40:08PM +0200, Kevin Wolf wrote: >> Am 20.10.2009 00:20, schrieb Anthony Liguori: >>> Mulyadi Santosa wrote: IMO, it would be faster if we provide keyboard shortcuts that will stop and resume VM execution right

[Qemu-devel] Re: [PATCH 0/9] S390x KVM support

2009-10-21 Thread Carsten Otte
Alexander Graf wrote: Either we take the psw in on x86 too or we #ifdef out the x86 specific stuff on s390. Good idea, I'll #ifndef CONFIG_S390 the x86 specifics while we're at it.

[Qemu-devel] Re: [PATCH 0/9] S390x KVM support

2009-10-21 Thread Alexander Graf
On 21.10.2009, at 10:18, Carsten Otte wrote: Alexander Graf wrote: Either we take the psw in on x86 too or we #ifdef out the x86 specific stuff on s390. Good idea, I'll #ifndef CONFIG_S390 the x86 specifics while we're at it. Maybe better #if defined(TARGET_X86) || defined(TARGET_IA64). W

[Qemu-devel] RE: [ANNOUNCE] Sheepdog: Distributed Storage System for KVM

2009-10-21 Thread Dietmar Maurer
Quite interesting. But would it be possible to use corosync for the cluster communication? The point is that we need corosync anyways for pacemaker, it is written in C (high performance) and seem to implement the feature you need? > -Original Message- > From: kvm-ow...@vger.kernel.org [m

[Qemu-devel] [PATCH 5/9] Add S390x virtio machine description

2009-10-21 Thread Alexander Graf
In order to use the new S390x virtio bus we just introduced, we also need a machine description that sets up the machine according to our PV specification. Let's add that machine description and be happy! Signed-off-by: Alexander Graf --- Makefile.target |2 +- hw/s390-virtio.c | 244

[Qemu-devel] [PATCH 7/9] Implement early printk in virtio-console

2009-10-21 Thread Alexander Graf
On our S390x Virtio machine we don't have anywhere to display early printks on, because we don't know about VGA or serial ports. So instead we just forward everything to the virtio console that we created anyways. Signed-off-by: Alexander Graf --- hw/virtio-console.c |7 +++ hw/virtio-c

[Qemu-devel] [PATCH 9/9] Move mp_state to CPU_COMMON

2009-10-21 Thread Alexander Graf
MP State is implemented in the generic code, so let's move the variable it accesses to generic code as well. Still unbreaks PPC and now even S390x w/ KVM. Signed-off-by: Alexander Graf --- cpu-defs.h|1 + target-i386/cpu.h |1 - 2 files changed, 1 insertions(+), 1 deletions(-)

[Qemu-devel] [PATCH 1/9] Export function for VA defined ram allocation

2009-10-21 Thread Alexander Graf
S390 requires vmas for guests to be < 256 GB. So we need to directly export mmaps "try to use this vma as start address" feature to not accidently get over that limit. Signed-off-by: Alexander Graf --- cpu-common.h |1 + exec.c | 15 +-- 2 files changed, 14 insertions(+),

[Qemu-devel] [PATCH 3/9] Add support for S390x system emulation

2009-10-21 Thread Alexander Graf
Right now only S390x Linux userspace emulation is supported. Let's enable the basics for system emulation so we can run virtual machines with KVM! Signed-off-by: Alexander Graf --- target-s390x/cpu.h | 86 - target-s390x/exec.h |5 +++

[Qemu-devel] [PATCH 6/9] S390 GDB stub

2009-10-21 Thread Alexander Graf
In order to debug funny kernel breakages it's always good to have a working gdb stub around. While Uli's patches don't include one one, I needed one that's at least good enough for 'bt' and some variable examinations during early bootup. So here it is - the absolute basics to get the qemu gdb stu

[Qemu-devel] [PATCH 2/9] Add KVM support for S390x

2009-10-21 Thread Alexander Graf
S390x was one of the first platforms that received support for KVM back in the day. Unfortunately until now there hasn't been a qemu implementation that would enable users to actually run guests. So let's include support for KVM S390x in qemu! Signed-off-by: Alexander Graf --- v1 -> v2: - us

[Qemu-devel] [PATCH 0/9] S390x KVM support v2

2009-10-21 Thread Alexander Graf
While S390x was one of the first targets that were supported by KVM it always lacked qemu system emulation support. In order to change that sad fact, I figured I'd just take on the task myself, taking kuli (http://www.ibm.com/developerworks/linux/linux390/kuli.html), Documentation/s390/kvm.txt and

[Qemu-devel] [PATCH 4/9] Add S390x virtio machine bus

2009-10-21 Thread Alexander Graf
On S390x we don't want to go through the hassle of emulating real existing hardware, because we don't need to for running Linux. So let's instead implement a machine that is 100% based on VirtIO which we fortunately implement already. This patch implements the bus that is the groundwork for such

[Qemu-devel] [PATCH 8/9] Set default console to virtio on S390x

2009-10-21 Thread Alexander Graf
All "normal" system emulation targets in qemu I'm aware of display output on either VGA or serial output. Our S390x virtio machine doesn't have such kind of legacy hardware. So instead we need to default to a virtio console. I'm not particularly proud of this patch. It would be a lot better to ha

[Qemu-devel] Re: [PATCH 2/2] multiboot: Limit number of multiboot modules

2009-10-21 Thread Kevin Wolf
Am 21.10.2009 01:05, schrieb Juan Quintela: > Adam Lackorzynski wrote: > > Hi > >> +enum { >> +/* Multiboot info */ >> +MBI_FLAGS = 0, >> +MBI_MEM_LOWER = 4, >> +MBI_MEM_UPPER = 8, >> +MBI_BOOT_DEVICE = 12, >> +MBI_CMDLINE = 16, >> +MBI_MODS_COUNT = 20,

[Qemu-devel] PCI address question

2009-10-21 Thread Màrius Montón
Hello, For my PCI device to QEMU, I need the real address the PCI bus is using to access my device. For a IO BAR (PCI_ADDRESS_SPACE_IO), I receive the real address (like 0xc200 or similar), but when registering a PCI_ADDRESS_SPACE_MEM I only receive the offset to the BAR. How I can receive or obt

[Qemu-devel] [PATCH 00/12] target-arm: miscellaneous fixes

2009-10-21 Thread Juha.Riihimaki
Hi, This patch series includes a number of smaller fixes and improvements to the ARM translator. The series should be applied in sequence as the modifications are all but one related to the same file, target-arm/ translate.c. The whole series should apply cleanly against latest git AFTER ap

[Qemu-devel] [PATCH 03/12] target-arm: add support for neon vld1.64 instruction

2009-10-21 Thread Juha.Riihimaki
Add support for neon vld1.64 instruction. From: Riku Voipio Signed-off-by: Juha Riihimäki --- diff --git a/target-arm/translate.c b/target-arm/translate.c index 3ea9d51..d027572 100644 --- a/target-arm/translate.c +++ b/target-arm/translate.c @@ -795,6 +795,12 @@ static inline TCGv gen_ld32(TCGv

[Qemu-devel] [PATCH 02/12] target-arm: optimize thumb 32bit multiply

2009-10-21 Thread Juha.Riihimaki
Current implementation of thumb mul instruction is implemented as a 32x32->64 multiply which then uses only 32 least significant bits of the result. Replace that with a simple 32x32->32 multiply. Signed-off-by: Juha Riihimäki --- diff --git a/target-arm/translate.c b/target-arm/translate.c in

[Qemu-devel] [PATCH 07/12] target-arm: fix neon vsri, vshl and vsli ops

2009-10-21 Thread Juha.Riihimaki
Shift immediate value is incorrectly overwritten by a temporary variable in the processing of NEON vsri, vshl and vsli instructions. Signed-off-by: Juha Riihimäki --- diff --git a/target-arm/translate.c b/target-arm/translate.c index 59bf7bc..c92ecc6 100644 --- a/target-arm/translate.c +++ b/ta

[Qemu-devel] [PATCH 06/12] target-arm: optimize arm load/store multiple ops

2009-10-21 Thread Juha.Riihimaki
ARM load/store multiple instructions can be slightly optimized by loading the register offset constant into a variable outside the register loop and using the preloaded variable inside the loop instead of reloading the offset value to a temporary variable on each loop iteration. This causes

[Qemu-devel] [PATCH 10/12] target-arm: replace tcg_gen_rori_i32 by tcg_gen_rotri_i32

2009-10-21 Thread Juha.Riihimaki
Use native rotation if possible instead of a simulated one. From: Filip Navara Signed-off-by: Juha Riihimäki --- diff --git a/target-arm/translate.c b/target-arm/translate.c index 99a9ffd..1734fae 100644 --- a/target-arm/translate.c +++ b/target-arm/translate.c @@ -418,21 +418,6 @@ static inline

[Qemu-devel] [PATCH 01/12] target-arm: fix resource leak in gen_set_cpsr macro

2009-10-21 Thread Juha.Riihimaki
Current implementation of the gen_set_cpsr macro creates a new temporary tcg variable through the tcg_const_i32 call but never marks it dead. Signed-off-by: Juha Riihimäki --- diff --git a/target-arm/translate.c b/target-arm/translate.c index bc51bcb..bda105e 100644 --- a/target-arm/translate

[Qemu-devel] [PATCH 11/12] target-arm: optimize neon vld/vst ops

2009-10-21 Thread Juha.Riihimaki
Reduce the amount of tcg ops generated from NEON vld/vst instructions by simplifying the code generation. Signed-off-by: Juha Riihimäki --- diff --git a/target-arm/translate.c b/target-arm/translate.c index 1734fae..fa03df8 100644 --- a/target-arm/translate.c +++ b/target-arm/translate.c @@ -36

[Qemu-devel] [PATCH 04/12] target-arm: allow modifying vfp fpexc en bit only

2009-10-21 Thread Juha.Riihimaki
All other bits except for the EN in the VFP FPEXC register are defined as subarchitecture specific and real functionality for any of the other bits has not been implemented in QEMU. However, current code allows modifying all bits in the VFP FPEXC register leading to problems when guest code

[Qemu-devel] [PATCH 12/12] target-arm: fix neon shift helper functions

2009-10-21 Thread Juha.Riihimaki
Current code is broken at least on gcc 4.2, the result of a comparison "-1 >= sizeof(type) * 8" results true and causes wrong code path to be taken. The fix utilizes abs() function where applicable and otherwise adds a test to ensure both arguments are positive before making the aforementio

[Qemu-devel] [PATCH 09/12] target-arm: optimize thumb push/pop ops

2009-10-21 Thread Juha.Riihimaki
Thumb push/pop instructions can be slightly optimized by loading the register offset constant into a variable outside the register loop and using the preloaded variable inside the loop instead of reloading the offset value to a temporary variable on each loop iteration. This causes less TCG

[Qemu-devel] [PATCH 08/12] target-arm: optimize thumb2 load/store multiple ops

2009-10-21 Thread Juha.Riihimaki
Thumb2 load/store multiple instructions can be slightly optimized by loading the register offset constant into a variable outside the register loop and using the preloaded variable inside the loop instead of reloading the offset value to a temporary variable on each loop iteration. This cau

[Qemu-devel] [PATCH 05/12] target-arm: optimize vfp load/store multiple ops

2009-10-21 Thread Juha.Riihimaki
VFP load/store multiple instructions can be slightly optimized by loading the register offset constant into a variable outside the register loop and using the preloaded variable inside the loop instead of reloading the offset value to a temporary variable on each loop iteration. This causes

Re: [Qemu-devel] [PATCH 02/12] target-arm: optimize thumb 32bit multiply

2009-10-21 Thread Laurent Desnogues
On Wed, Oct 21, 2009 at 12:17 PM, wrote: > Current implementation of thumb mul instruction is implemented as a > 32x32->64 multiply which then uses only 32 least significant bits of > the result. Replace that with a simple 32x32->32 multiply. > > Signed-off-by: Juha Riihimäki Acked-by: Laurent

Re: [Qemu-devel] [PATCH 07/12] target-arm: fix neon vsri, vshl and vsli ops

2009-10-21 Thread Laurent Desnogues
On Wed, Oct 21, 2009 at 12:17 PM, wrote: > Shift immediate value is incorrectly overwritten by a temporary > variable in the processing of NEON vsri, vshl and vsli instructions. > > Signed-off-by: Juha Riihimäki > --- > diff --git a/target-arm/translate.c b/target-arm/translate.c > index 59bf7bc

Re: [Qemu-devel] [PATCH 01/12] target-arm: fix resource leak in gen_set_cpsr macro

2009-10-21 Thread Laurent Desnogues
On Wed, Oct 21, 2009 at 12:17 PM, wrote: > Current implementation of the gen_set_cpsr macro creates a new > temporary tcg variable through the tcg_const_i32 call but never marks > it dead. > > Signed-off-by: Juha Riihimäki > --- > diff --git a/target-arm/translate.c b/target-arm/translate.c > in

Re: [Qemu-devel] [PATCH 10/12] target-arm: replace tcg_gen_rori_i32 by tcg_gen_rotri_i32

2009-10-21 Thread Laurent Desnogues
On Wed, Oct 21, 2009 at 12:18 PM, wrote: > Use native rotation if possible instead of a simulated one. > > From: Filip Navara > Signed-off-by: Juha Riihimäki Acked-by: Laurent Desnogues > --- > diff --git a/target-arm/translate.c b/target-arm/translate.c > index 99a9ffd..1734fae 100644 > ---

[Qemu-devel] [PATCH 12/12] [RESEND] target-arm: fix neon shift helper functions

2009-10-21 Thread Juha.Riihimaki
Current code is broken at least on gcc 4.2, the result of a comparison "-1 >= sizeof(type) * 8" results true and causes wrong code path to be taken. The fix utilizes abs() function where applicable and otherwise adds a test to ensure both arguments are positive before making the aforementioned comp

[Qemu-devel] Re: [PATCH 0/9] S390x KVM support v2

2009-10-21 Thread Carsten Otte
Alexander Graf wrote: This is the resulting code. Please comment on things you like and also on the ones you don't :-). Looks fantastic now. Whole series: Acked-by: Carsten Otte

[Qemu-devel] [PATCH 03/19] net: make tap_receive() re-use tap_receive_iov() code

2009-10-21 Thread Mark McLoughlin
In future we will want to prepend a virtio_net header if the NIC didn't supply one but IFF_VNET_HDR is enabled on the interface. This is most easily achived by using writev() in all cases. Signed-off-by: Mark McLoughlin --- net.c | 23 +++ 1 files changed, 15 insertions(+),

[Qemu-devel] [PATCH 00/19]

2009-10-21 Thread Mark McLoughlin
Hey, Over a year ago we added some code to qemu-kvm.git which takes advantage of the recent tun/tap IFF_VNET_HDR feature in order to allow virtio-net to send and receive packets with partial checksums and segmentation offloaded: http://article.gmane.org/gmane.comp.emulators.kvm.devel/20

[Qemu-devel] [PATCH 01/19] net: remove unused includes of if_tun.h and if_tap.h

2009-10-21 Thread Mark McLoughlin
Looks like these are just artifacts of vl.c being split up. Signed-off-by: Mark McLoughlin --- qemu-char.c |6 -- savevm.c|6 -- vl.c|6 -- 3 files changed, 0 insertions(+), 18 deletions(-) diff --git a/qemu-char.c b/qemu-char.c index 8084a67..7b39ace 100644

[Qemu-devel] [PATCH 08/19] net: add tap_has_vnet_hdr() and tap_using_vnet_hdr() APIs

2009-10-21 Thread Mark McLoughlin
These lamely named functions allow virtio-net to query whether IFF_VNET_HDR is enabled on a tap interface and inform the tap code that virtio-net will supply packets with a vnet header. Signed-off-by: Mark McLoughlin --- net.c | 39 +++ net.h |3 +++ 2 f

[Qemu-devel] [PATCH 04/19] net: enable IFF_VNET_HDR on tap fds if available

2009-10-21 Thread Mark McLoughlin
For now, we just add an empty header before writing and strip the header after reading. We really only want IFF_VNET_HDR when virtio_net is using it, but it would significantly complicate matters to try and do that. There should be little or no performance impact with always adding headers. Signe

[Qemu-devel] [PATCH 02/19] net: import linux tap ioctl definitions

2009-10-21 Thread Mark McLoughlin
Making features dependent on the availability of newer versions if_tun.h is going to get seriously clumsy, so let's just import the definitions we need. It's only a small handful. If and when we're comfortable depending on 2.6.30 headers, we can remove this again. Signed-off-by: Mark McLoughlin

[Qemu-devel] [PATCH 06/19] net: add a vnet_hdr=on|off parameter

2009-10-21 Thread Mark McLoughlin
This allows people to disable the IFF_VNET_HDR flag, e.g. for debugging purposes or if they know they may migrate the guest to a machine without IFF_VNET_HDR support. It also allows making the lack of IFF_VNET_HDR support an error condition, e.g. in the case where a guest is being migrated from a

[Qemu-devel] [PATCH 07/19] net: add a client type code

2009-10-21 Thread Mark McLoughlin
This is so as to allow APIs which operate on specific client types without having to add a function table entry which is only implemented by a single client type. Signed-off-by: Mark McLoughlin --- hw/dp8393x.c |3 ++- hw/etraxfs_eth.c |3 ++- hw/mcf_fec.c |3 ++- hw/mipsnet.

[Qemu-devel] [PATCH 13/19] net: implement tap support for receive_raw()

2009-10-21 Thread Mark McLoughlin
tap_receive_raw() always prepends a vnet header if IFF_VNET_HDR is enabled. tap_receive() only prepends when the a header is required but the NIC doesn't supply one. Signed-off-by: Mark McLoughlin --- net.c | 23 +++ 1 files changed, 19 insertions(+), 4 deletions(-) diff

[Qemu-devel] [PATCH 05/19] net: refactor tap initialization

2009-10-21 Thread Mark McLoughlin
Re-factor things so that there is only one call site for net_tap_fd_init(). Two concerns about the QemuOpts usage here - firstly, we set the script arguments to their default value and, secondly, we set the ifname value to the name allocated by the kernel if none is supplied. Are we okay with such

[Qemu-devel] [PATCH 15/19] net: add tap_set_offload()

2009-10-21 Thread Mark McLoughlin
This API allows virtio-net to enable various offload features on a tap interface - e.g. to tell the host kernel it can pass up partial checksums to userspace. Signed-off-by: Mark McLoughlin --- net.c | 24 net.h |1 + tap-linux.h |7 +++ 3 files

[Qemu-devel] [PATCH 14/19] virtio-net: add vnet_hdr support

2009-10-21 Thread Mark McLoughlin
With '-netdev tap,id=foo -nic model=virtio,netdev=foo' virtio-net can detect that its peer (i.e. the tap backend) supports vnet headers and advertise to the guest that it can send packets with partial checksums and/or TSO packets. One complication is that if we're migrating and the source host sup

[Qemu-devel] [PATCH 19/19] virtio-net: add tap_has_ufo flag to saved state

2009-10-21 Thread Mark McLoughlin
If we tell the guest we support UFO and then migrate to host which doesn't support it, we will find ourselves in grave difficulties. Prevent this scenario by adding a flag to virtio-net's savevm format which indicates whether the device requires host UFO support. Signed-off-by: Mark McLoughlin -

[Qemu-devel] [PATCH 10/19] net: add an API for 'raw' packets

2009-10-21 Thread Mark McLoughlin
In the case where a NIC and backend agree on a packet header format, this API allows injecting packets which lack the agreed upon header. We need this for sending our gratuitous ARP. Signed-off-by: Mark McLoughlin --- net-queue.h |1 + net.c | 37 +---

[Qemu-devel] [PATCH 12/19] net: use qemu_send_packet_raw() in qemu_announce_self()

2009-10-21 Thread Mark McLoughlin
From: Gleb Natapov Use qemu_send_packet_raw to send gratuitous arp. This will ensure that vnet header is handled properly. Also, avoid sending the gratuitous packet to the guest. There doesn't appear to be any reason for doing that and the code will currently just crash if the NIC is not associa

[Qemu-devel] [PATCH 09/19] net: add flags parameter to packet queue interface

2009-10-21 Thread Mark McLoughlin
This allows for the addition of a raw flag, and leaves the way open for other flags too. Signed-off-by: Mark McLoughlin --- net-queue.c | 26 ++ net-queue.h |6 ++ net.c | 14 -- 3 files changed, 36 insertions(+), 10 deletions(-) diff --git

[Qemu-devel] [PATCH 16/19] virtio-net: enable tap offload if guest supports it

2009-10-21 Thread Mark McLoughlin
We query the guest's feature set to see if it supports offload and, if so, we enable those features on the tap interface. Signed-off-by: Mark McLoughlin --- hw/virtio-net.c | 18 ++ 1 files changed, 18 insertions(+), 0 deletions(-) diff --git a/hw/virtio-net.c b/hw/virtio-net.

[Qemu-devel] [PATCH 17/19] Work around dhclient brokenness

2009-10-21 Thread Mark McLoughlin
From: Anthony Liguori With the latest GSO/csum offload patches, any guest using an unpatched version of dhclient (any Ubuntu guest, for instance), will no longer be able to get a DHCP address. dhclient is actually at fault here. It uses AF_PACKET to receive DHCP responses but does not check aux

[Qemu-devel] [PATCH 18/19] Enable UFO on virtio-net and tap devices

2009-10-21 Thread Mark McLoughlin
From: Sridhar Samudrala Enable UFO on the host tap device if supported and allow setting UFO on virtio-net in the guest. Signed-off-by: Sridhar Samudrala Signed-off-by: Mark McLoughlin --- hw/virtio-net.c | 11 +-- net.c | 36 net.h

[Qemu-devel] [PATCH 11/19] net: add receive_raw parameter to qemu_new_vlan_client()

2009-10-21 Thread Mark McLoughlin
Trivial patch to allow supplying a receive_raw function. A future cleanup should combine this function pointer parameters into a table. Signed-off-by: Mark McLoughlin --- hw/dp8393x.c |2 +- hw/etraxfs_eth.c |2 +- hw/mcf_fec.c |2 +- hw/mipsnet.c |2 +- hw/qdev.c

[Qemu-devel] New machine type

2009-10-21 Thread Johnny Giacomoni
Hi ! I need to create a new machine type with QEMU (QEMUMachine). Is it something I can find to do that ? What do I need exactly ? Thanks for help. Have a nice day ! -- Johnny Giacomoni Alternant en Electronique Informatique et Systèmes 1ère année du cycle ingénieur ESISAR Valence

[Qemu-devel] [PATCH 04/22] qdev: add vlan property

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/qdev-properties.c | 39 +++ hw/qdev.h|6 ++ 2 files changed, 45 insertions(+), 0 deletions(-) diff --git a/hw/qdev-properties.c b/hw/qdev-properties.c index 76925c8..c9843a2 100644 --- a/hw/qdev-proper

[Qemu-devel] [PATCH 01/22] net: add macaddr type.

2009-10-21 Thread Gerd Hoffmann
Add new type for mac addresses. Add function which sets the qemu default mac address if it finds the mac address uninitialized (i.e. all zeros). Signed-off-by: Gerd Hoffmann --- net.c | 15 +++ net.h |5 + qemu-common.h |1 + 3 files changed, 21 inserti

[Qemu-devel] [PATCH 01/22] qdev-ify network cards

2009-10-21 Thread Gerd Hoffmann
Hi, Now the first non-RfC version of this series. Changes compared to last RfC patch: * Added some common helper code so we have less code duplication and the actual driver changes are smaller. * All network drivers are converted now. * Some final cleanups which zap dead code. With

[Qemu-devel] [PATCH 03/22] qdev: add netdev property

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/qdev-properties.c | 36 hw/qdev.h|4 net.c|2 +- net.h|1 + 4 files changed, 42 insertions(+), 1 deletions(-) diff --git a/hw/qdev-properties.c b/hw/qdev-prope

[Qemu-devel] [PATCH 02/22] qdev: mac addr property fixups

2009-10-21 Thread Gerd Hoffmann
Make the mac property use the newly added type for the mac address. Signed-off-by: Gerd Hoffmann --- hw/qdev-properties.c | 31 +-- hw/qdev.h|3 ++- 2 files changed, 23 insertions(+), 11 deletions(-) diff --git a/hw/qdev-properties.c b/hw/qdev-prope

[Qemu-devel] [PATCH 07/22] qdev: add qdev_prop_exists()

2009-10-21 Thread Gerd Hoffmann
Function test whenever a driver has a specific property. Signed-off-by: Gerd Hoffmann --- hw/qdev-properties.c |5 + hw/qdev.h|1 + 2 files changed, 6 insertions(+), 0 deletions(-) diff --git a/hw/qdev-properties.c b/hw/qdev-properties.c index c9843a2..370f356 100644 ---

[Qemu-devel] [PATCH 08/22] prepare pci nic init path for qdev property configuration.

2009-10-21 Thread Gerd Hoffmann
Initialization path will work with both converted and not-converted drivers, so we can convert drivers one by one. Signed-off-by: Gerd Hoffmann --- hw/pci.c | 10 -- 1 files changed, 8 insertions(+), 2 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index abf07ca..fe2c4bd 100644 --- a/h

[Qemu-devel] [PATCH 05/22] qdev/net: common nic property bits

2009-10-21 Thread Gerd Hoffmann
Add a new type for properties common to all nics. Add helper functions and macros to deal with it. Signed-off-by: Gerd Hoffmann --- hw/qdev.c |9 + net.h | 14 ++ 2 files changed, 23 insertions(+), 0 deletions(-) diff --git a/hw/qdev.c b/hw/qdev.c index 20f931c..b3

[Qemu-devel] [PATCH 09/22] ne2k_pci: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/ne2000.c | 39 --- 1 files changed, 32 insertions(+), 7 deletions(-) diff --git a/hw/ne2000.c b/hw/ne2000.c index 7ce56ff..41893b3 100644 --- a/hw/ne2000.c +++ b/hw/ne2000.c @@ -25,6 +25,7 @@ #include "pci.h" #include "

[Qemu-devel] [PATCH 06/22] ne2k_isa: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/ne2000-isa.c | 17 +++-- hw/ne2000.c |6 +++--- hw/ne2000.h |2 +- 3 files changed, 11 insertions(+), 14 deletions(-) diff --git a/hw/ne2000-isa.c b/hw/ne2000-isa.c index e346731..1da0d54 100644 --- a/hw/ne2000-isa.c +++ b/hw/ne2

[Qemu-devel] [PATCH 11/22] pcnet: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/pcnet.c | 64 +--- hw/sun4m.c |2 +- 2 files changed, 49 insertions(+), 17 deletions(-) diff --git a/hw/pcnet.c b/hw/pcnet.c index fecbff7..45ca6f3 100644 --- a/hw/pcnet.c +++ b/hw/pcnet.c @@ -38,6

[Qemu-devel] [PATCH 10/22] e1000: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/e1000.c | 46 -- 1 files changed, 36 insertions(+), 10 deletions(-) diff --git a/hw/e1000.c b/hw/e1000.c index f123bda..301997b 100644 --- a/hw/e1000.c +++ b/hw/e1000.c @@ -25,6 +25,7 @@ #include "hw.h" #include

[Qemu-devel] [PATCH 13/22] rtl8139: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/rtl8139.c | 54 +- 1 files changed, 33 insertions(+), 21 deletions(-) diff --git a/hw/rtl8139.c b/hw/rtl8139.c index 10daeb2..de60246 100644 --- a/hw/rtl8139.c +++ b/hw/rtl8139.c @@ -47,6 +47,7 @@ #includ

[Qemu-devel] [PATCH 14/22] virtio: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/qdev.c |4 hw/syborg.c|4 ++-- hw/syborg_virtio.c | 16 +--- hw/virtio-net.c| 43 --- hw/virtio-pci.c| 33 +++-- hw/virtio.h|

[Qemu-devel] [PATCH 12/22] pcnet: split away lance.c (sparc32 code).

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- Makefile.target |2 +- hw/lance.c | 146 hw/pcnet.c | 154 +++--- hw/pcnet.h | 39 ++ 4 files changed, 195 insertions(+), 146 d

[Qemu-devel] [PATCH 19/22] musicpal: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/musicpal.c | 14 +- 1 files changed, 9 insertions(+), 5 deletions(-) diff --git a/hw/musicpal.c b/hw/musicpal.c index 02d4c70..cb1ac6d 100644 --- a/hw/musicpal.c +++ b/hw/musicpal.c @@ -152,6 +152,7 @@ typedef struct mv88w8618_eth_state { u

[Qemu-devel] [PATCH 21/22] kill dead nic unplug code.

2009-10-21 Thread Gerd Hoffmann
Cleanup on unplug happens via qdev->exit() callback now. Signed-off-by: Gerd Hoffmann --- hw/acpi.c |3 --- hw/device-hotplug.c | 16 hw/pci-hotplug.c| 25 - sysemu.h|4 4 files changed, 0 insertions(+), 48 delet

[Qemu-devel] [PATCH 17/22] xilinx_ethlite: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/xilinx.h |2 +- hw/xilinx_ethlite.c | 16 ++-- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/hw/xilinx.h b/hw/xilinx.h index 5e6aeea..705ff5b 100644 --- a/hw/xilinx.h +++ b/hw/xilinx.h @@ -40,7 +40,7 @@ xilinx_ethlit

[Qemu-devel] [PATCH 22/22] pc.c: only load e1000 rom.

2009-10-21 Thread Gerd Hoffmann
The other pxe roms are loaded by the drivers individual drivers now. Signed-off-by: Gerd Hoffmann --- hw/pc.c |9 - 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/hw/pc.c b/hw/pc.c index 408d6d6..4cd8ec6 100644 --- a/hw/pc.c +++ b/hw/pc.c @@ -1163,6 +1163,11 @@ static

[Qemu-devel] [PATCH 15/22] eepro100: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/eepro100.c | 75 +++-- 1 files changed, 62 insertions(+), 13 deletions(-) diff --git a/hw/eepro100.c b/hw/eepro100.c index 62207da..277759f 100644 --- a/hw/eepro100.c +++ b/hw/eepro100.c @@ -194,11 +194,11

[Qemu-devel] [PATCH 16/22] smc91c111: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/smc91c111.c | 28 +++- 1 files changed, 19 insertions(+), 9 deletions(-) diff --git a/hw/smc91c111.c b/hw/smc91c111.c index d58821a..4006035 100644 --- a/hw/smc91c111.c +++ b/hw/smc91c111.c @@ -19,6 +19,7 @@ typedef struct { Sy

[Qemu-devel] [PATCH 18/22] stellaris_enet: use qdev properties for configuration.

2009-10-21 Thread Gerd Hoffmann
Signed-off-by: Gerd Hoffmann --- hw/stellaris.c |2 +- hw/stellaris_enet.c | 40 +--- 2 files changed, 26 insertions(+), 16 deletions(-) diff --git a/hw/stellaris.c b/hw/stellaris.c index 1628914..44c9eee 100644 --- a/hw/stellaris.c +++ b/hw/stella

[Qemu-devel] [PATCH 20/22] zap DeviceState->nd

2009-10-21 Thread Gerd Hoffmann
No users left. Also cleanup obsolete helper functions. Signed-off-by: Gerd Hoffmann --- hw/pci.c |9 + hw/qdev.c | 22 -- hw/qdev.h |1 - net.h |7 --- 4 files changed, 1 insertions(+), 38 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index fe2

Re: [Qemu-devel] [PATCH] properly save kvm system time msr registers

2009-10-21 Thread Gerd Hoffmann
On 10/20/09 16:04, Glauber Costa wrote: Currently, the msrs involved in setting up pvclock are not saved over migration and/or save/restore. This patch puts their value in special fields in our CPUState, and deal with them using vmstate. kvm also has to account for it, by including them in the m

[Qemu-devel] [PATCH 00/12] S/390 support

2009-10-21 Thread Ulrich Hecht
Here's the patches again, split and fixed as suggested by Aurelien. It should now be possible to apply host and target support separately. See the individual patches for details on what has changed. CU Uli Ulrich Hecht (12): TCG "sync" op S/390 disassembler fixes S/390 CPU emulation S/390

[Qemu-devel] [PATCH 06/12] S/390 host support for TCG

2009-10-21 Thread Ulrich Hecht
S/390 TCG code generator as posted before improvements since last time: - don't use R0 (often means "zero", not "register zero") - optimized add_i32 immediate - formatted for better compliance with the QEMU coding style Signed-off-by: Ulrich Hecht --- dyngen-exec.h |2 +- linux-user

[Qemu-devel] [PATCH 05/12] S/390 target build system support

2009-10-21 Thread Ulrich Hecht
changes to configure and makefiles for S/390 target support --- configure |9 +++-- 1 files changed, 7 insertions(+), 2 deletions(-) diff --git a/configure b/configure index df984a3..64be51f 100755 --- a/configure +++ b/configure @@ -793,6 +793,7 @@ sh4eb-linux-user \ sparc-linux-user \

[Qemu-devel] [PATCH 02/12] S/390 disassembler fixes

2009-10-21 Thread Ulrich Hecht
enable zArch (64-bit) instructions enable disassembler for both s390 and s390x Signed-off-by: Ulrich Hecht --- configure |2 +- disas.c|3 +++ s390-dis.c |4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/configure b/configure index ca6d45c..350c742 100755 -

[Qemu-devel] [PATCH 01/12] TCG "sync" op

2009-10-21 Thread Ulrich Hecht
sync allows concurrent accesses to locations in memory through different TCG variables. This comes in handy when you are emulating CPU registers that can be used as either 32 or 64 bit, as TCG doesn't know anything about aliases. See the s390x target for an example. Fixed sync_i64 build failure on

[Qemu-devel] [PATCH 11/12] linux-user: getpriority errno fix

2009-10-21 Thread Ulrich Hecht
getpriority returned wrong errno; fixes LTP test getpriority02. Signed-off-by: Ulrich Hecht --- linux-user/syscall.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index da6f2e1..455c3fd 100644 --- a/linux-user/syscall.c +++

[Qemu-devel] [PATCH 04/12] S/390 host build system support

2009-10-21 Thread Ulrich Hecht
changes to configure and makefiles for S/390 host support --- configure | 11 --- 1 files changed, 8 insertions(+), 3 deletions(-) diff --git a/configure b/configure index 350c742..df984a3 100755 --- a/configure +++ b/configure @@ -157,9 +157,12 @@ case "$cpu" in parisc|parisc64)

[Qemu-devel] [PATCH 12/12] enable CPU_QuadU for s390x

2009-10-21 Thread Ulrich Hecht
Signed-off-by: Ulrich Hecht --- cpu-all.h |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/cpu-all.h b/cpu-all.h index ebe8bfb..d245dd2 100644 --- a/cpu-all.h +++ b/cpu-all.h @@ -138,7 +138,7 @@ typedef union { uint64_t ll; } CPU_DoubleU; -#ifdef TARGET_SPARC +#if

[Qemu-devel] [PATCH 09/12] linux-user: dup3, fallocate syscalls

2009-10-21 Thread Ulrich Hecht
implementations of dup3 and fallocate that are good enough to fool LTP dup3 check, fallocate check fixed use compile_prog Signed-off-by: Ulrich Hecht --- configure| 36 linux-user/syscall.c | 10 ++ 2 files changed, 46 insertions(+),

[Qemu-devel] [PATCH 08/12] linux-user: don't do locking in single-threaded processes

2009-10-21 Thread Ulrich Hecht
Skips setting the tb_lock if a process doesn't have more than one thread, which is usually the case. Results in about 20% performance gain (measured with the s390x target, but the effect should be similar with other targets). Signed-off-by: Ulrich Hecht --- cpu-defs.h |8

[Qemu-devel] [PATCH 07/12] linux-user: S/390 64-bit (s390x) support

2009-10-21 Thread Ulrich Hecht
code for running 64-bit S/390 Linux binaries use CPU_DoubleU for FP regs proper specification exception (SIGILL) handling Signed-off-by: Ulrich Hecht --- linux-user/elfload.c | 18 ++ linux-user/main.c| 89 ++ linux-user/s390x/syscall.h | 25 +++

[Qemu-devel] [PATCH 10/12] linux-user: define a couple of syscalls for non-uid16 targets

2009-10-21 Thread Ulrich Hecht
Quite a number of syscalls are only defined on systems with USE_UID16 defined; this patch defines them on other systems as well. Fixes a large number of uid/gid-related testcases on the s390x target (and most likely on other targets as well) Signed-off-by: Ulrich Hecht --- linux-user/syscall.c

Re: [Qemu-devel] [PATCH] new SDL keyboard shortcuts to start and stop VM

2009-10-21 Thread Glauber Costa
On Wed, Oct 21, 2009 at 5:27 AM, Kevin Wolf wrote: > Am 20.10.2009 19:08, schrieb Daniel P. Berrange: >> On Tue, Oct 20, 2009 at 12:40:08PM +0200, Kevin Wolf wrote: >>> Am 20.10.2009 00:20, schrieb Anthony Liguori: Mulyadi Santosa wrote: > IMO, it would be faster if we provide keyboard sh

[Qemu-devel] [GIT PULL] linux-user updates

2009-10-21 Thread Riku Voipio
Hi, Added to the previous list of patches is Uli's KD/VT/FB ioctl adding patch, which was sent to the list earlier. The following changes since commit 544f4f0b5aa659f858f384677d4767d8fcecb27d: Blue Swirl (1): bsd-user: fix breakage by 78cfb07fe0dc556cae662a0fab5fe1bd33daabdb are availa

Re: [Qemu-devel] [PATCH 1/9] Export function for VA defined ram allocation

2009-10-21 Thread Anthony Liguori
Alexander Graf wrote: S390 requires vmas for guests to be < 256 GB. So we need to directly export mmaps "try to use this vma as start address" feature to not accidently get over that limit. Signed-off-by: Alexander Graf --- cpu-common.h |1 + exec.c | 15 +-- 2 files ch

Re: [Qemu-devel] [PATCH] properly save kvm system time msr registers

2009-10-21 Thread Glauber Costa
On Wed, Oct 21, 2009 at 03:38:31PM +0200, Gerd Hoffmann wrote: > On 10/20/09 16:04, Glauber Costa wrote: >> Currently, the msrs involved in setting up pvclock are not saved over >> migration and/or save/restore. This patch puts their value in special >> fields in our CPUState, and deal with them us

Re: [Qemu-devel] [PATCH] properly save kvm system time msr registers

2009-10-21 Thread Glauber Costa
On Wed, Oct 21, 2009 at 04:52:00PM +0200, Gerd Hoffmann wrote: > On 10/21/09 16:32, Glauber Costa wrote: >> On Wed, Oct 21, 2009 at 03:38:31PM +0200, Gerd Hoffmann wrote: >>> On 10/20/09 16:04, Glauber Costa wrote: Currently, the msrs involved in setting up pvclock are not saved over migr

  1   2   >