[Qemu-devel] [RFC qom-cpu v2 02/28] target-alpha: Update AlphaCPU to QOM realizefn

2013-01-19 Thread Andreas Färber
Update the alpha_cpu_realize() signature and hook up to DeviceClass::realize. Set realized = true in cpu_alpha_init(). qapi/error.h is included through qdev now and no longer needed. Signed-off-by: Andreas Färber --- target-alpha/cpu-qom.h |2 ++ target-alpha/cpu.c | 21 ++

[Qemu-devel] [RFC qom-cpu v2 28/28] target-xtensa: Move TCG initialization to XtensaCPU initfn

2013-01-19 Thread Andreas Färber
Combine this with breakpoint handler registration, guarding both with tcg_enabled() to suppress also TCG init for qtest. Rename the handler to xtensa_breakpoint_handler() since it needs to become global. Signed-off-by: Andreas Färber --- target-xtensa/cpu.c|7 +++ target-xtensa/cpu.h

Re: [Qemu-devel] [PATCH] bsd-user: avoid conflict with qemu_vmalloc

2013-01-19 Thread Andreas Färber
Am 19.01.2013 11:19, schrieb Blue Swirl: > Rename qemu_vmalloc() to bsd_vmalloc(), adjust the only user. > > Remove #ifdeffery in oslib-posix.c. > > Signed-off-by: Blue Swirl Tested-by: Andreas Färber Fixes the build on OpenBSD 5.2 for me. Thanks, Andreas

[Qemu-devel] [RFC qom-cpu v2 27/28] target-unicore32: Move TCG initialization to UniCore32CPU initfn

2013-01-19 Thread Andreas Färber
Normalize the "inited" logic and add a tcg_enabled() check to suppress it for qtest. Ensures that a QOM-created UniCore32CPU is usable. Signed-off-by: Andreas Färber --- target-unicore32/cpu.c|6 ++ target-unicore32/helper.c |6 -- 2 Dateien geändert, 6 Zeilen hinzugefügt(+)

[Qemu-devel] [RFC qom-cpu v2 21/28] target-microblaze: Move TCG initialization to MicroBlazeCPU initfn

2013-01-19 Thread Andreas Färber
Split off TCG initialization from cpu_mb_init() into mb_tcg_init() to call it from the initfn. Ensures that a QOM-created MicroBlazeCPU is usable. Signed-off-by: Andreas Färber --- target-microblaze/cpu.c |6 ++ target-microblaze/cpu.h |1 + target-microblaze/translate.c

[Qemu-devel] [RFC qom-cpu v2 26/28] target-sparc: Move TCG initialization to SPARCCPU initfn

2013-01-19 Thread Andreas Färber
Signed-off-by: Andreas Färber --- target-sparc/cpu.c |8 1 Datei geändert, 4 Zeilen hinzugefügt(+), 4 Zeilen entfernt(-) diff --git a/target-sparc/cpu.c b/target-sparc/cpu.c index a92822d..10dc709 100644 --- a/target-sparc/cpu.c +++ b/target-sparc/cpu.c @@ -114,10 +114,6 @@ SPARCCPU

[Qemu-devel] [RFC qom-cpu v2 17/28] target-arm: Move TCG initialization to ARMCPU initfn

2013-01-19 Thread Andreas Färber
Ensures that a QOM-created ARMCPU is usable. Signed-off-by: Andreas Färber --- target-arm/cpu.c|6 ++ target-arm/helper.c |6 -- 2 Dateien geändert, 6 Zeilen hinzugefügt(+), 6 Zeilen entfernt(-) diff --git a/target-arm/cpu.c b/target-arm/cpu.c index 19d5ae4..8615068 100644 -

[Qemu-devel] [RFC qom-cpu v2 25/28] target-sh4: Move TCG initialization to SuperHCPU initfn

2013-01-19 Thread Andreas Färber
Add a tcg_enabled() check to suppress it for qtest. Signed-off-by: Andreas Färber --- target-sh4/cpu.c |4 target-sh4/cpu.h |1 + target-sh4/translate.c |3 +-- 3 Dateien geändert, 6 Zeilen hinzugefügt(+), 2 Zeilen entfernt(-) diff --git a/target-sh4/cpu.c b/target-

[Qemu-devel] [RFC qom-cpu v2 19/28] target-lm32: Move TCG initialization to LM32CPU initfn

2013-01-19 Thread Andreas Färber
Signed-off-by: Andreas Färber --- target-lm32/cpu.c|6 ++ target-lm32/helper.c |6 -- 2 Dateien geändert, 6 Zeilen hinzugefügt(+), 6 Zeilen entfernt(-) diff --git a/target-lm32/cpu.c b/target-lm32/cpu.c index 6a84f51..5f16734 100644 --- a/target-lm32/cpu.c +++ b/target-lm32/c

[Qemu-devel] [RFC qom-cpu v2 13/28] target-sh4: Introduce QOM realizefn for SuperHCPU

2013-01-19 Thread Andreas Färber
Introduce a realizefn and set realized = true in cpu_sh4_init(). Signed-off-by: Andreas Färber --- target-sh4/cpu-qom.h |2 ++ target-sh4/cpu.c | 15 +++ target-sh4/translate.c |5 +++-- 3 Dateien geändert, 20 Zeilen hinzugefügt(+), 2 Zeilen entfernt(-) diff --git

[Qemu-devel] [RFC qom-cpu v2 10/28] target-microblaze: Introduce QOM realizefn for MicroBlazeCPU

2013-01-19 Thread Andreas Färber
Introduce realizefn and set realized = true from cpu_mb_init(). Signed-off-by: Andreas Färber --- target-microblaze/cpu-qom.h |2 ++ target-microblaze/cpu.c | 15 +++ target-microblaze/translate.c |3 +-- 3 Dateien geändert, 18 Zeilen hinzugefügt(+), 2 Zeilen entfer

[Qemu-devel] [RFC qom-cpu v2 14/28] target-sparc: Introduce QOM realizefn for SPARCCPU

2013-01-19 Thread Andreas Färber
Introduce realizefn and set realized = true in cpu_sparc_init(). Signed-off-by: Andreas Färber --- target-sparc/cpu-qom.h |2 ++ target-sparc/cpu.c | 17 - 2 Dateien geändert, 18 Zeilen hinzugefügt(+), 1 Zeile entfernt(-) diff --git a/target-sparc/cpu-qom.h b/target-sp

[Qemu-devel] [RFC qom-cpu v2 00/28] CPUState QOM realizefn support

2013-01-19 Thread Andreas Färber
Hello, This series cleans up cpu_init() by moving code to QOM realizefn and initfn. As a result, the following target CPUs become fully QOM-instantiatable: arm, microblaze, openrisc, ppc, s390x and unicore32. The other targets are still in need of model-specific CPU subclasses. v2 fixes a bug wit

[Qemu-devel] [RFC qom-cpu v2 05/28] target-openrisc: Update OpenRISCCPU to QOM realizefn

2013-01-19 Thread Andreas Färber
Update the openrisc_cpu_realize() signature, hook it up to DeviceClass::realize and set realized = true in cpu_openrisc_init(). qapi/error.h is now included through qdev and no longer needed. Signed-off-by: Andreas Färber --- target-openrisc/cpu.c | 13 ++--- target-openrisc/cpu.h |

[Qemu-devel] [RFC qom-cpu v2 11/28] target-mips: Introduce QOM realizefn for MIPSCPU

2013-01-19 Thread Andreas Färber
Introduce a realizefn and set realized = true from cpu_mips_init(). Signed-off-by: Andreas Färber --- target-mips/cpu-qom.h |2 ++ target-mips/cpu.c | 15 +++ target-mips/translate.c |5 +++-- 3 Dateien geändert, 20 Zeilen hinzugefügt(+), 2 Zeilen entfernt(-) diff

[Qemu-devel] [RFC qom-cpu v2 01/28] cpu: Prepare QOM realizefn

2013-01-19 Thread Andreas Färber
Overwrite the default implementation with a no-op, no longer attempting to call DeviceClass::init. Signed-off-by: Andreas Färber --- qom/cpu.c |5 + 1 Datei geändert, 5 Zeilen hinzugefügt(+) diff --git a/qom/cpu.c b/qom/cpu.c index 49e5134..cbc2d01 100644 --- a/qom/cpu.c +++ b/qom/cpu.c

[Qemu-devel] [PATCH v4 2/3] net: split eth_mac_addr for better error handling

2013-01-19 Thread akong
From: Stefan Hajnoczi When we set mac address, software mac address in system and hardware mac address all need to be updated. Current eth_mac_addr() doesn't allow callers to implement error handling nicely. This patch split eth_mac_addr() to prepare part and real commit part, then we can prepar

Re: [Qemu-devel] [PATCH v3 2/2] virtio-net: introduce a new control to set macaddr

2013-01-19 Thread Amos Kong
On Fri, Jan 18, 2013 at 12:00:42PM +0100, Stefan Hajnoczi wrote: > On Thu, Jan 17, 2013 at 06:40:12PM +0800, ak...@redhat.com wrote: > > diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c > > index 395ab4f..837c978 100644 > > --- a/drivers/net/virtio_net.c > > +++ b/drivers/net/virtio

[Qemu-devel] [PATCH v4 0/3] make mac programming for virtio net more robust

2013-01-19 Thread akong
From: Amos Kong Currenly mac is programmed byte by byte. This means that we have an intermediate step where mac is wrong. Third patch introduced a new vq control command to set mac address, it's atomic. V2: check return of sending command, delay eth_mac_addr() V3: restore software address when

[Qemu-devel] [PATCH v4 1/3] move virtnet_send_command() above virtnet_set_mac_address()

2013-01-19 Thread akong
From: Amos Kong We want to send vq command to set mac address in virtnet_set_mac_address(), so do this function moving. Fixed a little issue of coding style. Signed-off-by: Amos Kong --- drivers/net/virtio_net.c | 89 1 file changed, 44 insertio

[Qemu-devel] [PATCH v4 3/3] virtio-net: introduce a new control to set macaddr

2013-01-19 Thread akong
From: Amos Kong Currently we write MAC address to pci config space byte by byte, this means that we have an intermediate step where mac is wrong. This patch introduced a new control command to set MAC address, it's atomic. VIRTIO_NET_F_CTRL_MAC_ADDR is a new feature bit for compatibility. Signe

[Qemu-devel] [PATCH qom-cpu for-1.4] target-openrisc: Clean up triple QOM casts

2013-01-19 Thread Andreas Färber
Instead of calling openrisc_env_get_cpu(), casting to CPU() via the ENV_GET_CPU() compatibility macro and casting back to OPENRISC_CPU(), just call openrisc_env_get_cpu() directly. ENV_GET_CPU() is meant as workaround for target-independent code only. Signed-off-by: Andreas Färber --- target-op

[Qemu-devel] [Bug 548346] Re: import qemu-user-static from debian

2013-01-19 Thread Adam Conrad
qemu-user-static has been in universe for quite a while now, closing this bug. ** Changed in: qemu (Ubuntu) Status: New => Fix Released -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/548346 Ti

[Qemu-devel] [PATCH for-1.4] target-microblaze: Drop unused cpu_mb_close() prototype

2013-01-19 Thread Andreas Färber
Such a function never existed. Signed-off-by: Andreas Färber --- Peter, can you ack this? Or feel free to commit, Edgar. As for cris, I am going to base v2 of my CPU realizefn series on this cleanup. Thanks, Andreas target-microblaze/cpu.h |1 - 1 Datei geändert, 1 Zeile entfernt(-) dif

[Qemu-devel] [PATCH for-1.4] target-cris: Drop unused cpu_cris_close() prototype

2013-01-19 Thread Andreas Färber
Such a function never existed. Signed-off-by: Andreas Färber --- Edgar, can you commit or ack? I'd like to base v2 of my CPU realizefn series on this. Thanks, Andreas target-cris/cpu.h |1 - 1 Datei geändert, 1 Zeile entfernt(-) diff --git a/target-cris/cpu.h b/target-cris/cpu.h index 63

[Qemu-devel] [PATCH 2/3] net/bitbang_mdio: Never set PHY RST and ANEG_RST bits on register write

2013-01-19 Thread Grant Likely
The RST and ANEG_RST bits are commands, not settings. An operating system will get confused (or at least u-boot does) if those bits remain set after writing to them. Therefore, mask them out on write. Cc: Peter Maydell Cc: Paul Brook Cc: Edgar E. Iglesias Cc: Anthony Liguori Signed-off-by: Gra

[Qemu-devel] [PATCH 1/3] net/bitbang_mdio: Generalize etraxfs MDIO bitbanging emulation

2013-01-19 Thread Grant Likely
The etraxfs Ethernet model implements quite a nice bitbanging core. The change splits it out into a separate .c file. There are no functional changes here, just movement of code and reformatting to match qemu coding standards. Cc: Peter Maydell Cc: Paul Brook Cc: Edgar E. Iglesias Cc: Anthony L

[Qemu-devel] [PATCH 3/3] net/bitbang_mdio: Use bitbang core for smc91c111 network device

2013-01-19 Thread Grant Likely
The smc91c111 device has bitbanged MDIO access, but the model doesn't yet implement it. This patch uses the generalized bitbang MDIO support pulled out of etraxfs Ethernet driver. The MDIO state machine is driven by changes in state to the clock control bit in the management register. The PHY mode

[Qemu-devel] [PATCH 0/3] Generalize bitbang MDIO and use for versatile-pb

2013-01-19 Thread Grant Likely
This series extracts the MDIO bitbang code from the etraxfs driver and makes it usable on targets using the smc9 Ethernet controller. I've tested this using u-boot on the versatile-pb model. net/bitbang_mdio: Generalize etraxfs MDIO bitbanging emulation net/bitbang_mdio: Never set PHY RST and

Re: [Qemu-devel] [PATCH][v2] linux-user: correct setsockopt()

2013-01-19 Thread Laurent Vivier
ping ? Le mardi 01 janvier 2013 à 19:24 +0100, Laurent Vivier a écrit : > From: Laurent Vivier > > SO_SNDTIMEO and SO_RCVTIMEO take a struct timeval, not an int > > To test this, you can use : > > QEMU_STRACE= ping localhost 2>&1 |grep TIMEO > 568 setsockopt(3,SOL_SOCKET,SO_SNDTIMEO,{1,0},8) =

Re: [Qemu-devel] [PATCH] linux-user: correct msgrcv()

2013-01-19 Thread Laurent Vivier
Le mercredi 02 janvier 2013 à 00:03 +, Peter Maydell a écrit : > On 20 December 2012 21:00, Laurent Vivier wrote: > > All parameters must be swapped before the call of do_msgrcv(). > > --- a/linux-user/syscall.c > > +++ b/linux-user/syscall.c > > @@ -2901,7 +2901,7 @@ static inline abi_long do

Re: [Qemu-devel] [PATCH][v2] linux-user: correct semctl() and shmctl()

2013-01-19 Thread Laurent Vivier
ping ? Le mercredi 02 janvier 2013 à 21:38 +0100, Laurent Vivier a écrit : > The parameter "union semun" of semctl() is not a value > but a pointer to the value. > > Moreover, all fields of target_su must be swapped (if needed). > > The third argument of shmctl is a pointer. > > WITHOUT this pa

Re: [Qemu-devel] [PATCH 1/4] build: move around libcacard-y definition

2013-01-19 Thread Andreas Färber
Am 19.01.2013 23:01, schrieb Paolo Bonzini: > Il 19/01/2013 19:05, Andreas Färber ha scritto: >> Am 19.01.2013 11:06, schrieb Paolo Bonzini: It is also needed if !CONFIG_SOFTMMU, unlike everything that surrounds it. >> Why? linux-user should not depend on it - bad wording only? > > It is need

Re: [Qemu-devel] [PATCH][v2] linux-user: correct reboot()

2013-01-19 Thread Laurent Vivier
Le lundi 07 janvier 2013 à 21:46 +, Peter Maydell a écrit : > On 7 January 2013 21:40, Laurent Vivier wrote: > > According to man reboot(2), the 4th argument is only used with > > LINUX_REBOOT_CMD_RESTART2. In other cases, trying to convert > > the value can generate EFAULT. > > > > Signed-off

Re: [Qemu-devel] [PATCH for 1.4 0/4] Simplify Makefile.objs some more

2013-01-19 Thread Andreas Färber
Am 19.01.2013 23:06, schrieb Paolo Bonzini: > Il 19/01/2013 19:11, Andreas Färber ha scritto: The patches are mostly mechanical substitutions, and there is no user-visible change---neither in total build time, nor in the files that are linked into the executables. >> Without having t

[Qemu-devel] [PATCH 3/3] scripts: A script to create linux container using qemu-linux-user.

2013-01-19 Thread Laurent Vivier
sudo qemu-create-lxc.sh This script mixes linux container, binfmt and qemu to create hybrid linux container : container on an host kernel. It will create "light" emulated virtual machine with several steps : - create a linux-user qemu- - define it as the binfmt interpreter (using qemu-update-bi

[Qemu-devel] [PATCH 1/3] scripts: extract ELF magics from qemu-binfmt-conf.sh

2013-01-19 Thread Laurent Vivier
Signed-off-by: Laurent Vivier --- scripts/binfmts-magic | 93 ++ scripts/qemu-binfmt-conf.sh | 104 +++ 2 files changed, 140 insertions(+), 57 deletions(-) create mode 100644 scripts/binfmts-magic mode change 1

[Qemu-devel] [PATCH 2/3] scripts: define qemu-update-binfmt

2013-01-19 Thread Laurent Vivier
qemu-update-binfmt uses update-binfmts to set qemu as an ELF interpreter for a given cpu type. Signed-off-by: Laurent Vivier --- scripts/qemu-update-binfmt | 59 1 file changed, 59 insertions(+) create mode 100755 scripts/qemu-update-binfmt diff -

Re: [Qemu-devel] [PATCH] link seccomp only with softmmu targets

2013-01-19 Thread Doug Goldstein
On Sat, Jan 19, 2013 at 8:58 AM, Michael Tokarev wrote: > Now, if seccomp is detected, it is linked into every executable, > but is used only by softmmu targets (from vl.c). So link it > only where it is actually needed. > > Signed-off-by: Michael Tokarev > --- > configure |2 +- > 1 file c

Re: [Qemu-devel] [PATCH for 1.4 0/4] Simplify Makefile.objs some more

2013-01-19 Thread Paolo Bonzini
Il 19/01/2013 23:06, Paolo Bonzini ha scritto: > The only dependency is > > #if !defined(CONFIG_USER_ONLY) > int kvm_fd; > bool kvm_vcpu_dirty; > #endif > struct KVMState *kvm_state; > struct kvm_run *kvm_run; > > Plenty of other fields are meaningless for !CONFIG_USER_ONLY but ar

Re: [Qemu-devel] [PATCH for 1.4 0/4] Simplify Makefile.objs some more

2013-01-19 Thread Paolo Bonzini
Il 19/01/2013 19:11, Andreas Färber ha scritto: >> > The patches are mostly mechanical substitutions, and there is no >> > user-visible change---neither in total build time, nor in the files that >> > are linked into the executables. > Without having tested this yet I want to remind that it is nece

Re: [Qemu-devel] [PATCH 1/4] build: move around libcacard-y definition

2013-01-19 Thread Paolo Bonzini
Il 19/01/2013 19:05, Andreas Färber ha scritto: > Am 19.01.2013 11:06, schrieb Paolo Bonzini: >> > It is also needed if !CONFIG_SOFTMMU, unlike everything that surrounds it. > Why? linux-user should not depend on it - bad wording only? It is needed by libcacard/Makefile. You can build it even if

Re: [Qemu-devel] [PATCH] tci: Fix broken build (regression)

2013-01-19 Thread Blue Swirl
Thanks, applied. On Sat, Jan 19, 2013 at 7:23 PM, Stefan Weil wrote: > > s390x-linux-user now also uses GETPC. Instead of adding it to the list of > targets which use GETPC, the macro is now defined unconditionally. > > This avoids future build regressions like this one: > > CCs390x-linux-u

[Qemu-devel] [PATCH] tci: Fix broken build (regression)

2013-01-19 Thread Stefan Weil
s390x-linux-user now also uses GETPC. Instead of adding it to the list of targets which use GETPC, the macro is now defined unconditionally. This avoids future build regressions like this one: CCs390x-linux-user/target-s390x/int_helper.o cc1: warnings being treated as errors qemu/target-s39

Re: [Qemu-devel] [PATCH V20 8/8] Add fd parameter for TPM passthrough driver

2013-01-19 Thread Stefan Berger
On 01/19/2013 10:31 AM, Eric Blake wrote: On 01/18/2013 05:55 PM, Stefan Berger wrote: On 01/18/2013 07:14 PM, Stefan Berger wrote: On 01/18/2013 01:18 PM, Eric Blake wrote: On 01/18/2013 09:02 AM, Stefan Berger wrote: When libvirt forks, the child process inherits the file descriptors, among

Re: [Qemu-devel] [PATCH for 1.4 0/4] Simplify Makefile.objs some more

2013-01-19 Thread Andreas Färber
Am 19.01.2013 11:06, schrieb Paolo Bonzini: > This small series makes some more simplifications to Makefile.objs, > removing two more variables: universal-obj-y and extra-obj-y, all > unified into common-obj-y. It also removes what remains of user-obj-y, > unifying that into common-obj-y as well.

Re: [Qemu-devel] [PATCH RFC for-1.4] qemu-thread-posix: Fix build for OpenBSD

2013-01-19 Thread Andreas Färber
Am 19.01.2013 10:44, schrieb Blue Swirl: > On Fri, Jan 18, 2013 at 4:16 PM, Paolo Bonzini wrote: >> Il 18/01/2013 17:07, Andreas Färber ha scritto: >>> Am 18.01.2013 17:05, schrieb Paolo Bonzini: Il 18/01/2013 16:58, Andreas Färber ha scritto: > Avoid an undefined reference to sem_timedwa

Re: [Qemu-devel] [PATCH 2/4] build: use -$(CONFIG_SECCOMP) instead of ifeq

2013-01-19 Thread Andreas Färber
Am 19.01.2013 11:06, schrieb Paolo Bonzini: > Signed-off-by: Paolo Bonzini Acked-by: Andreas Färber Andreas -- SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

Re: [Qemu-devel] [PATCH 1/4] build: move around libcacard-y definition

2013-01-19 Thread Andreas Färber
Am 19.01.2013 11:06, schrieb Paolo Bonzini: > It is also needed if !CONFIG_SOFTMMU, unlike everything that surrounds it. Why? linux-user should not depend on it - bad wording only? Andreas > Signed-off-by: Paolo Bonzini > --- > Makefile.objs | 18 +- > 1 files changed, 9 inse

Re: [Qemu-devel] [PATCH 0/3] Purge the silly GLib Basic Types

2013-01-19 Thread Anthony Liguori
Michael Tokarev writes: > 19.01.2013 13:33, Blue Swirl wrote: >> On Fri, Jan 18, 2013 at 4:17 PM, Anthony Liguori >> wrote: >>> Markus Armbruster writes: >>> See PATCH 1/3 for rationale. Markus Armbruster (3): Purge the silly GLib "Basic Types", except for gboolean

Re: [Qemu-devel] [PATCH for-1.4] block/raw-posix: Make hdev_aio_discard() available outside Linux

2013-01-19 Thread Blue Swirl
Thanks, applied. I must have deleted this by accident. On Fri, Jan 18, 2013 at 3:43 PM, Andreas Färber wrote: > Fixes the build on OpenBSD among others. > > Suggested-by: Kevin Wolf > Signed-off-by: Andreas Färber > Cc: Paolo Bonzini > --- > block/raw-posix.c | 26 +

[Qemu-devel] [PATCH] tests: add fuzzing to visitor tests

2013-01-19 Thread Blue Swirl
Perform input tests on random data. Improvement to code coverage for qapi/string-input-visitor.c is about 3 percentage points. Signed-off-by: Blue Swirl --- tests/test-string-input-visitor.c | 49 + 1 files changed, 49 insertions(+), 0 deletions(-) diff --

Re: [Qemu-devel] [Openstack][Sheepdog][Libvirt][Qemu]Add a new block storage driver by Libvirt/Qemu way for Openstack

2013-01-19 Thread harryxiyou
On Sat, Jan 19, 2013 at 10:04 PM, MORITA Kazutaka wrote: > At Sat, 19 Jan 2013 16:47:37 +0800, [...] > If you do the above work, I think you can use your file system with > OpenStack. > Thanks for your review ;-) > But I suggest doing them step by step. If your file system is not > supported in

Re: [Qemu-devel] [PATCH V20 8/8] Add fd parameter for TPM passthrough driver

2013-01-19 Thread Eric Blake
On 01/18/2013 05:55 PM, Stefan Berger wrote: > On 01/18/2013 07:14 PM, Stefan Berger wrote: >> On 01/18/2013 01:18 PM, Eric Blake wrote: >>> On 01/18/2013 09:02 AM, Stefan Berger wrote: >> When libvirt forks, the child process inherits the file descriptors, >> among them those of the taps and /dev/

Re: [Qemu-devel] [PATCH] link seccomp only with softmmu targets

2013-01-19 Thread Paolo Bonzini
Il 19/01/2013 16:04, Michael Tokarev ha scritto: > >> Now, if seccomp is detected, it is linked into every executable, >> but is used only by softmmu targets (from vl.c). So link it >> only where it is actually needed. > > Note this is not just a cleanup. For some reason, at least > debian pack

Re: [Qemu-devel] [PATCH for-1.4] tcg/target-arm: Add missing parens to assertions

2013-01-19 Thread Peter Maydell
Thanks. cc'd qemu-stable since IIRC this bug went into the stable branch. Personally I don't care about ARM hosts in -stable branches, especially since we're nearly at 1.4 release, but somebody else might so perhaps this patch should go in 1.3 stable. -- PMM On 19 January 2013 14:00, Blue Swirl

Re: [Qemu-devel] [PATCH] sheepdog: add support for connecting to unix domain socket

2013-01-19 Thread MORITA Kazutaka
At Wed, 16 Jan 2013 15:21:09 +0100, Stefan Hajnoczi wrote: > > On Tue, Jan 15, 2013 at 11:12:40PM +0900, MORITA Kazutaka wrote: > > +static int set_nodelay(int fd) > > +{ > > +int opt = 1; > > +return setsockopt(fd, IPPROTO_TCP, TCP_NODELAY, (char *)&opt, > > sizeof(opt)); > > +} > > + >

Re: [Qemu-devel] [PATCH] link seccomp only with softmmu targets

2013-01-19 Thread Michael Tokarev
19.01.2013 18:58, Michael Tokarev wrote: Now, if seccomp is detected, it is linked into every executable, but is used only by softmmu targets (from vl.c). So link it only where it is actually needed. Note this is not just a cleanup. For some reason, at least debian package of seccomp lacks st

[Qemu-devel] [PATCH] link seccomp only with softmmu targets

2013-01-19 Thread Michael Tokarev
Now, if seccomp is detected, it is linked into every executable, but is used only by softmmu targets (from vl.c). So link it only where it is actually needed. Signed-off-by: Michael Tokarev --- configure |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configur

Re: [Qemu-devel] [PATCH V20 5/8] Add a TPM Passthrough backend driver implementation

2013-01-19 Thread Stefan Berger
On 01/19/2013 04:18 AM, Blue Swirl wrote: Summary: dprintf->DPRINTF replacement : done __attribute__((packed)) -> QEMU_PACKED replacement : done Thanks and regards, Stefan

Re: [Qemu-devel] [PATCH] virtio-s390: add a reset function to virtio-s390 devices

2013-01-19 Thread Alexander Graf
On 19.01.2013, at 15:10, Paolo Bonzini wrote: > Il 10/01/2013 15:40, Paolo Bonzini ha scritto: >> virtio-s390 devices are not being reset when their bus is. To fix >> this, add a reset method that forwards to virtio_reset. This is >> only needed because of the "strange" modeling of virtio devic

Re: [Qemu-devel] [PATCH] define qemukvm-1.2 machine type

2013-01-19 Thread Paolo Bonzini
> On Fri, Jan 18, 2013 at 12:34:57PM -0500, Paolo Bonzini wrote: > > > > version_id and minimum_version_id should be changed to 2, as the > > > > comment indicates. > > > > > > But won't that mean we have to carry that patch forever, and > > > while we carry > > > that patch we can never migrate f

Re: [Qemu-devel] OpenBSD build broken by 8238010b

2013-01-19 Thread Paolo Bonzini
> I'm getting this error: > CC block/raw-posix.o > /src/qemu/block/raw-posix.c:1458: error: 'hdev_aio_discard' > undeclared here (not in a function) > > It looks like the function is only defined for Linux. Andreas already sent a small patch to fix this. http://permalink.gmane.org/gmane.comp.em

[Qemu-devel] OpenBSD build broken by 8238010b

2013-01-19 Thread Blue Swirl
I'm getting this error: CCblock/raw-posix.o /src/qemu/block/raw-posix.c:1458: error: 'hdev_aio_discard' undeclared here (not in a function) It looks like the function is only defined for Linux.

Re: [Qemu-devel] [PATCH] virtio-s390: add a reset function to virtio-s390 devices

2013-01-19 Thread Paolo Bonzini
Il 10/01/2013 15:40, Paolo Bonzini ha scritto: > virtio-s390 devices are not being reset when their bus is. To fix > this, add a reset method that forwards to virtio_reset. This is > only needed because of the "strange" modeling of virtio devices; > the ->vdev link is being handled manually rathe

Re: [Qemu-devel] [Openstack][Sheepdog][Libvirt][Qemu]Add a new block storage driver by Libvirt/Qemu way for Openstack

2013-01-19 Thread MORITA Kazutaka
At Sat, 19 Jan 2013 16:47:37 +0800, harryxiyou wrote: > > Hi all, > > I wanna add a new block storage driver by Libvirt/Qemu way for Openstack, > which > is as same as Sheepdog driver for Openstack. So i think the theories > are like this. > > 1, In the Openstack Nova branch, Openstck driver ca

Re: [Qemu-devel] [PATCH] usb: Fix compilation for MinGW (regression)

2013-01-19 Thread Blue Swirl
Thanks, applied. On Fri, Jan 18, 2013 at 10:48 PM, Stefan Weil wrote: > 84f2d0ea added an argument to function usb_host_info. > The stub function must match the declaration in usb.h. > > Signed-off-by: Stefan Weil > --- > hw/usb/host-stub.c |2 +- > 1 file changed, 1 insertion(+), 1 deletio

Re: [Qemu-devel] [PATCH qom-cpu for-1.4] cpu-defs.h: Drop qemu_work_item prototype

2013-01-19 Thread Blue Swirl
Thanks, applied. On Fri, Jan 18, 2013 at 6:30 PM, Andreas Färber wrote: > Commit c64ca8140e9c21cd0d44c10fbe1247cb4ade8e6e (cpu: Move > queued_work_{first,last} to CPUState) moved the qemu_work_item fields > away. Clean up the now unused prototype. > > Signed-off-by: Andreas Färber > --- > inclu

Re: [Qemu-devel] [PATCH for-1.4] tcg/target-arm: Add missing parens to assertions

2013-01-19 Thread Blue Swirl
Thanks, applied. On Thu, Jan 17, 2013 at 8:04 PM, Peter Maydell wrote: > Silence a (legitimate) complaint about missing parentheses: > > tcg/arm/tcg-target.c: In function ‘tcg_out_qemu_ld’: > tcg/arm/tcg-target.c:1148:5: error: suggest parentheses around > comparison in operand of ‘&’ [-Werror=pa

Re: [Qemu-devel] [PATCH] Replace non-portable asprintf by g_strdup_printf

2013-01-19 Thread Blue Swirl
Thanks, applied. This fixes a warning on mingw32. On Wed, Jan 16, 2013 at 5:37 PM, Stefan Weil wrote: > g_strdup_printf already handles OOM errors, so some error handling in > QEMU code can be removed. > > Signed-off-by: Stefan Weil > --- > > TODO: > > * hardware_address is set, but obviously ne

Re: [Qemu-devel] [PATCH 0/8] Fixes and cleanups around fw_cfg

2013-01-19 Thread Blue Swirl
Thanks, applied all. On Thu, Jan 17, 2013 at 1:16 PM, Gleb Natapov wrote: > On Wed, Jan 16, 2013 at 02:50:21PM +0100, Markus Armbruster wrote: >> Markus Armbruster (8): >> fw_cfg: Replace debug prints by tracepoints >> fw_cfg: Dumb down fw_cfg_add_*() not to return success / failure >> fw_c

Re: [Qemu-devel] [PATCH 0/3] tcg-optimize with known-zero bits

2013-01-19 Thread Blue Swirl
Thanks, applied all. On Fri, Jan 11, 2013 at 11:42 PM, Richard Henderson wrote: > This patch set is extracted from Paolo's target-i386 eflags2 > optimization branch: > > git://github.com/bonzini/qemu.git eflags2 > > I've cherry-picked 3 patches and rebased them vs master. I've > made a few tri

Re: [Qemu-devel] [PULL 0/9] ppc patch queue 2013-01-18

2013-01-19 Thread Blue Swirl
Thanks, pulled. On Fri, Jan 18, 2013 at 6:13 PM, Alexander Graf wrote: > Hi Blue / Aurelien, > > This is my current patch queue for ppc. Please pull. > > Alex > > > The following changes since commit ddc01bf16e9f04b3e72c1b946b0b8efeb7a545d2: > Anthony Liguori (1): > Merge remote-tracki

Re: [Qemu-devel] [PULL 0/8] s390 patch queue 2013-01-18

2013-01-19 Thread Blue Swirl
Thanks, pulled. On Fri, Jan 18, 2013 at 6:12 PM, Alexander Graf wrote: > Hi Blue / Aurelien, > > This is my current patch queue for s390. Please pull. > > Alex > > > The following changes since commit ddc01bf16e9f04b3e72c1b946b0b8efeb7a545d2: > Anthony Liguori (1): > Merge remote-track

Re: [Qemu-devel] [PULL 0/2] alpha-linux-user patch queue

2013-01-19 Thread Blue Swirl
Thanks, pulled. On Wed, Jan 16, 2013 at 4:28 PM, Richard Henderson wrote: > The following changes since commit 249d41720b7dfbb5951b430b9eefdbee7464f515: > > qdev: Prepare "realized" property (2013-01-15 18:27:00 -0600) > > are available in the git repository at: > > git://github.com/rth7680/q

Re: [Qemu-devel] Merging xen fixes and other fixes for 1.3.1

2013-01-19 Thread Michael Tokarev
19.01.2013 17:26, Fabio Fantoni пишет: I see that is started merging for qemu 1.3.1, if is this the actual 1.3 stable branch (https://github.com/mdroth/qemu/commits/stable-1.3-staging) probably is good add also other fixes. My last test build was based on this: http://xenbits.xen.org/gitweb/?p=

[Qemu-devel] Merging xen fixes and other fixes for 1.3.1

2013-01-19 Thread Fabio Fantoni
I see that is started merging for qemu 1.3.1, if is this the actual 1.3 stable branch (https://github.com/mdroth/qemu/commits/stable-1.3-staging) probably is good add also other fixes. My last test build was based on this: http://xenbits.xen.org/gitweb/?p=qemu-upstream-unstable.git;a=summary Th

Re: [Qemu-devel] [PATCH 0/3] Purge the silly GLib Basic Types

2013-01-19 Thread Blue Swirl
On Sat, Jan 19, 2013 at 10:35 AM, Michael Tokarev wrote: > 19.01.2013 13:33, Blue Swirl wrote: >> >> On Fri, Jan 18, 2013 at 4:17 PM, Anthony Liguori >> wrote: >>> >>> Markus Armbruster writes: >>> See PATCH 1/3 for rationale. Markus Armbruster (3): Purge the silly GLib "B

Re: [Qemu-devel] [PULL 00/27] More source reorganization and build system TLC

2013-01-19 Thread Paolo Bonzini
Il 19/01/2013 11:21, Blue Swirl ha scritto: >> > Does the function really needs to be called qemu_vmalloc? If not, >> > having the same name for two different things is bad. > I've just sent a patch to fix this. > > But new code could be introduced that used qemu_vmalloc() so I'm not > sure this

Re: [Qemu-devel] [PATCH 0/3] Purge the silly GLib Basic Types

2013-01-19 Thread Michael Tokarev
19.01.2013 13:33, Blue Swirl wrote: On Fri, Jan 18, 2013 at 4:17 PM, Anthony Liguori wrote: Markus Armbruster writes: See PATCH 1/3 for rationale. Markus Armbruster (3): Purge the silly GLib "Basic Types", except for gboolean Purge GLib's gboolean, it's a trap for the unwary checkp

Re: [Qemu-devel] [PULL 00/27] More source reorganization and build system TLC

2013-01-19 Thread Blue Swirl
On Sat, Jan 19, 2013 at 10:17 AM, Paolo Bonzini wrote: > Il 18/01/2013 19:03, Andreas Färber ha scritto: >> I believe this broke bsd-user: util/oslib-posix.c has qemu_vmalloc() >> guarded with >> #if !defined(CONFIG_BSD_USER) >> which now no longer shields it from the qemu_vmalloc() reimplementati

[Qemu-devel] [PATCH 1/4] build: move around libcacard-y definition

2013-01-19 Thread Paolo Bonzini
It is also needed if !CONFIG_SOFTMMU, unlike everything that surrounds it. Signed-off-by: Paolo Bonzini --- Makefile.objs | 18 +- 1 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Makefile.objs b/Makefile.objs index d465a72..3548f9b 100644 --- a/Makefile.objs +++ b

[Qemu-devel] [PATCH] bsd-user: avoid conflict with qemu_vmalloc

2013-01-19 Thread Blue Swirl
Rename qemu_vmalloc() to bsd_vmalloc(), adjust the only user. Remove #ifdeffery in oslib-posix.c. Signed-off-by: Blue Swirl --- bsd-user/mmap.c|4 ++-- util/oslib-posix.c |3 --- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/bsd-user/mmap.c b/bsd-user/mmap.c index 5

Re: [Qemu-devel] [PULL 00/27] More source reorganization and build system TLC

2013-01-19 Thread Paolo Bonzini
Il 18/01/2013 19:03, Andreas Färber ha scritto: > I believe this broke bsd-user: util/oslib-posix.c has qemu_vmalloc() > guarded with > #if !defined(CONFIG_BSD_USER) > which now no longer shields it from the qemu_vmalloc() reimplementation > in bsd-user/mmap.c. > > Any suggestion how to fix? Does

[Qemu-devel] [PATCH 4/4] build: remove extra-obj-y

2013-01-19 Thread Paolo Bonzini
extra-obj-y is somewhat complicated to understand. Replace it with a special CONFIG_ALL symbol that is defined only at toplevel. This limits the case of directories defining more than one *-obj-y target. Signed-off-by: Paolo Bonzini --- Makefile |3 ++- Makefile.objs|

Re: [Qemu-devel] [PATCH RFC for-1.4] qemu-thread-posix: Fix build for OpenBSD

2013-01-19 Thread Peter Maydell
On 18 January 2013 16:05, Paolo Bonzini wrote: > Il 18/01/2013 16:58, Andreas Färber ha scritto: >> Avoid an undefined reference to sem_timedwait. > This was reverted recently. Apparently your OpenBSD is too old compared > to what Brad wants to support... I suggest getting rid of all the os ifd

[Qemu-devel] [PATCH 3/4] build: remove universal-obj-y

2013-01-19 Thread Paolo Bonzini
All of universal-obj-y, user-obj-y (right now unused) and common-obj-y can be unified into common-obj-y if we take care of defining CONFIG_SOFTMMU and CONFIG_USER_ONLY in the toplevel makefile. This is similar to how we define symbols for hardware components. Signed-off-by: Paolo Bonzini --- Ma

[Qemu-devel] [PATCH 2/4] build: use -$(CONFIG_SECCOMP) instead of ifeq

2013-01-19 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- Makefile.objs |6 +- 1 files changed, 1 insertions(+), 5 deletions(-) diff --git a/Makefile.objs b/Makefile.objs index 3548f9b..3bdb248 100644 --- a/Makefile.objs +++ b/Makefile.objs @@ -80,11 +80,7 @@ common-obj-$(CONFIG_SLIRP) += slirp/ common-obj-y

[Qemu-devel] [PATCH for 1.4 0/4] Simplify Makefile.objs some more

2013-01-19 Thread Paolo Bonzini
This small series makes some more simplifications to Makefile.objs, removing two more variables: universal-obj-y and extra-obj-y, all unified into common-obj-y. It also removes what remains of user-obj-y, unifying that into common-obj-y as well. To achieve this, the CONFIG_SOFTMMU and CONFIG_USER

Re: [Qemu-devel] [PATCH RFC for-1.4] qemu-thread-posix: Fix build for OpenBSD

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 4:16 PM, Paolo Bonzini wrote: > Il 18/01/2013 17:07, Andreas Färber ha scritto: >> Am 18.01.2013 17:05, schrieb Paolo Bonzini: >>> Il 18/01/2013 16:58, Andreas Färber ha scritto: Avoid an undefined reference to sem_timedwait. Signed-off-by: Andreas Färber >>

Re: [Qemu-devel] [PATCH 0/3] Purge the silly GLib Basic Types

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 4:17 PM, Anthony Liguori wrote: > Markus Armbruster writes: > >> See PATCH 1/3 for rationale. >> >> Markus Armbruster (3): >> Purge the silly GLib "Basic Types", except for gboolean >> Purge GLib's gboolean, it's a trap for the unwary >> checkpatch: Keep out the GLib

Re: [Qemu-devel] [PATCH V20 5/8] Add a TPM Passthrough backend driver implementation

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 4:02 PM, Stefan Berger wrote: > From Andreas Niederl's original posting with adaptations where necessary: > > This patch is based of off version 9 of Stefan Berger's patch series > "QEMU Trusted Platform Module (TPM) integration" > and adds a new backend driver for it. >

Re: [Qemu-devel] [PATCH] util: Fix compilation of envlist.c for MinGW

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 8:36 AM, Paolo Bonzini wrote: > Il 17/01/2013 22:18, Blue Swirl ha scritto: >> On Thu, Jan 17, 2013 at 8:54 PM, Stefan Weil wrote: >>> Am 17.01.2013 21:45, schrieb Blue Swirl: >>> On Wed, Jan 16, 2013 at 6:04 PM, Stefan Weil wrote: > > MinGW has no strtok_r,

Re: [Qemu-devel] Go along with glib's basic type typedef silliness?

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 3:36 PM, Markus Armbruster wrote: > Blue Swirl writes: > >> On Mon, Jan 14, 2013 at 7:01 PM, Markus Armbruster wrote: >>> [Thread hijack, dropping cc: qemu-trivial, qemu-ppc] >>> >>> Andreas Färber writes: >>> Am 14.01.2013 13:19, schrieb Markus Armbruster: > An

Re: [Qemu-devel] [PATCH] readline: avoid memcpy() of overlapping regions

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 11:04 AM, Stefan Hajnoczi wrote: > On Thu, Jan 17, 2013 at 08:13:38PM +, Blue Swirl wrote: >> On Mon, Jan 14, 2013 at 9:09 AM, Stefan Hajnoczi wrote: >> > On Sat, Jan 12, 2013 at 10:46:18AM +, Blue Swirl wrote: >> >> On Thu, Jan 10, 2013 at 12:43 PM, Stefan Hajnocz

Re: [Qemu-devel] [PATCH 02/18] hw: add QEMU model for Faraday APB DMA

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 6:28 AM, Dante wrote: > Signed-off-by: Kuo-Jung Su > --- > hw/ftapbbrg020.c | 485 > ++ > hw/ftapbbrg020.h | 43 + > 2 files changed, 528 insertions(+) > create mode 100644 hw/ftapbbrg020.c > create mode 100644

[Qemu-devel] [Openstack][Sheepdog][Libvirt][Qemu]Add a new block storage driver by Libvirt/Qemu way for Openstack

2013-01-19 Thread harryxiyou
Hi all, I wanna add a new block storage driver by Libvirt/Qemu way for Openstack, which is as same as Sheepdog driver for Openstack. So i think the theories are like this. 1, In the Openstack Nova branch, Openstck driver call libvirt client and send parameters to libvirt client.(From this point,

Re: [Qemu-devel] [PATCH] dataplane: support viostor virtio-pci status bit setting

2013-01-19 Thread Vadim Rozenfeld
On Friday, January 18, 2013 05:59:37 PM Stefan Hajnoczi wrote: > On Thu, Jan 17, 2013 at 04:46:54PM +0100, Stefan Hajnoczi wrote: > > The viostor virtio-blk driver for Windows does not use the > > VIRTIO_CONFIG_S_DRIVER bit. It only sets the VIRTIO_CONFIG_S_DRIVER_OK > > bit. Will be added in the

Re: [Qemu-devel] [PATCH 04/18] hw: add QEMU model for Faraday 1Gbps Ethernet MAC

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 6:28 AM, Dante wrote: > Signed-off-by: Kuo-Jung Su > --- > hw/ftgmac100.c | 621 > > hw/ftgmac100.h | 191 + > 2 files changed, 812 insertions(+) > create mode 100644 hw/ftgmac100.c > create mod

Re: [Qemu-devel] [PATCH 01/18] hw: add Faraday a369 SoC platform support

2013-01-19 Thread Blue Swirl
On Fri, Jan 18, 2013 at 6:28 AM, Dante wrote: > Faraday A369, is an ARM SoC prototype chip, highly integrated with common SoC > features, including a 533MHz ARM v5TE master CPU, a 133MHz ARM v5TE slave CPU, > a 32-bit DDR-2 533MHz memory controller, 2 USB 2.0 host/OTG ports, SATA > host/device por

  1   2   >