Re: [Qemu-devel] qemu-kvm 1.2, after VM cloning, source_VM error

2013-04-28 Thread Shashaankar Reddy
Apologies for the late reply!! Never mind, we figured it out, Since we are doing cloning of VM, at the source(from where cloning is initiated) we are redirecting the disk driver of the VM to a new incremental image (qcow2). Also making the previous disk image as read only, since the cloned VM wil

[Qemu-devel] [PATCH] memory: give name every AddressSpace

2013-04-28 Thread Alexey Kardashevskiy
The "info mtree" command in QEMU console prints only "memory" and "I/O" address spaces while there are actually a lot more other AddressSpace structs created by PCI and VIO devices. Those devices do not normally have names and therefore not present in "info qtree" output. The patch fixes this. Si

Re: [Qemu-devel] [PATCH v2] i.MX: implement a more correct version of EPIT timer.

2013-04-28 Thread Peter Chubb
> "Jean-Christophe" == Jean-Christophe DUBOIS writes: Jean-Christophe> This patch is providing a complete version of the Jean-Christophe> EPIT timer. Note, however that the GPT timer in the Jean-Christophe> same file is still not complete. Looks good. You can add my Reviewed-by: Peter Chu

Re: [Qemu-devel] [PATCH] Extend support of SMBUS(module pm_smbus.c) HST_STS register.

2013-04-28 Thread Peter Maydell
On 28 April 2013 19:26, Maksim Ratnikov wrote: > Previous realization doesn't consider flags in the status register. > Add DS and INTR bits of HST_STS register set after transaction execution. > Update bits resetting in HST_STS register. Update error processing: if > DEV_ERR bit are set > transact

Re: [Qemu-devel] [RFC][PATCH v3 00/24] instrument: Let the user wrap/override specific event tracing routines

2013-04-28 Thread Lluís Vilanova
Stefan Hajnoczi writes: > On Fri, Apr 26, 2013 at 02:15:46PM +0200, Lluís Vilanova wrote: >> Stefan Hajnoczi writes: >> >> > On Wed, Apr 24, 2013 at 02:17:22PM +0200, Lluís Vilanova wrote: >> > Given that the group of users for this feature is so small while the >> > burden of supporting this is

[Qemu-devel] [PATCH] Extend support of SMBUS(module pm_smbus.c) HST_STS register.

2013-04-28 Thread Maksim Ratnikov
Previous realization doesn't consider flags in the status register. Add DS and INTR bits of HST_STS register set after transaction execution. Update bits resetting in HST_STS register. Update error processing: if DEV_ERR bit are set transaction isn't execution. Signed-off-by: Maksim_Ratnikov ---

[Qemu-devel] [PATCH] Makefile: Fix build breakage

2013-04-28 Thread Dunrong Huang
The following error occurs when building dtc module: CHK version_gen.h CC libfdt/fdt.o cc1: error: dtc: No such file or directory [-Werror] cc1: all warnings being treated as errors make[1]: *** [libfdt/fdt.o] Error 1 make: *** [subdir-dtc] Error 2 In rules.mak, "-I$( Cc: Blue Sw

[Qemu-devel] [PATCH qtestfix for-1.5] libqos: Convert fw_cfg values to host endianness

2013-04-28 Thread Andreas Färber
The fw_cfg ABI is Little Endian, so byte-swap the generically read byte array to host endianness. This unbreaks the fw_cfg tests on ppc. Signed-off-by: Andreas Färber --- tests/libqos/fw_cfg.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/libqos/fw_cfg.c b/tes

[Qemu-devel] [PATCH 6/6] pc_sysfw: change rom_only default to 0

2013-04-28 Thread Jordan Justen
Now KVM can support a flash memory. This feature depends on KVM_CAP_READONLY_MEM, which was introduced in Linux 3.7. Signed-off-by: Jordan Justen --- hw/block/pc_sysfw.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/block/pc_sysfw.c b/hw/block/pc_sysfw.c index e88d67e

[Qemu-devel] [PATCH 2/6] kvm: support using KVM_MEM_READONLY flag for readonly regions

2013-04-28 Thread Jordan Justen
A slot that uses KVM_MEM_READONLY can be read from and code can execute from the region, but writes will trap. For regions that are readonly and also not writeable, we force the slot to be removed so reads or writes to the region will trap. (A memory region in this state is not executable within k

[Qemu-devel] [PATCH 5/6] pc_sysfw: allow flash memory to be used with KVM

2013-04-28 Thread Jordan Justen
This requires the KVM READONLY memory capability. Signed-off-by: Jordan Justen --- hw/block/pc_sysfw.c |3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/block/pc_sysfw.c b/hw/block/pc_sysfw.c index aad8614..e88d67e 100644 --- a/hw/block/pc_sysfw.c +++ b/hw/block/pc_sysfw.c @@ -237,6 +

[Qemu-devel] [v1][Qemu-ppc][PATCH 1/1] PPC: e500: correct params->ram_size with ram_size

2013-04-28 Thread Tiejun Chen
We should sync params->ram_size after we fixup memory size on a alignment boundary. Otherwise Guest would exceed the actual memory region. Signed-off-by: Tiejun Chen --- hw/ppc/e500.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c index c1bdb6b..145da0e 10

[Qemu-devel] [PATCH 4/6] pflash_cfi01: memory region should be set to enable readonly mode

2013-04-28 Thread Jordan Justen
This causes any writes to the memory region to trap to the device handler. This is also important for KVM, because this allows the memory region to be set using KVM_MEM_READONLY, which allows the memory region to be read & executed. (Without this, KVM will not support executing from the memory reg

[Qemu-devel] [PATCH 3/6] kvm: workaround a possible KVM bug when using KVM_MEM_READONLY

2013-04-28 Thread Jordan Justen
On a Linux 3.8.0 based kernel, I occasionally saw a situation where the memory region would continue to trap on memory read even though KVM_MEM_READONLY was set. I found that if I set the slot to a size of 0, and before setting the slot, it would then behave as expected. Signed-off-by: Jordan Jus

[Qemu-devel] [PATCH 1/6] kvm: add kvm_readonly_mem_enabled

2013-04-28 Thread Jordan Justen
Signed-off-by: Jordan Justen --- include/sysemu/kvm.h | 10 ++ kvm-all.c|6 ++ kvm-stub.c |1 + 3 files changed, 17 insertions(+) diff --git a/include/sysemu/kvm.h b/include/sysemu/kvm.h index 75bd7d9..c83f51c 100644 --- a/include/sysemu/kvm.h +++ b/in

[Qemu-devel] [PATCH 0/6] KVM flash memory support

2013-04-28 Thread Jordan Justen
git://github.com/jljusten/qemu.git kvm-flash-v1 Utilize KVM_CAP_READONLY_MEM to support PC system flash emulation with KVM. Jordan Justen (6): kvm: add kvm_readonly_mem_enabled kvm: support using KVM_MEM_READONLY flag for readonly regions kvm: workaround a possible KVM bug when using KVM_ME

Re: [Qemu-devel] [PATCH 7/7] fw_cfg: add qtest test case

2013-04-28 Thread Andreas Färber
Am 16.04.2013 16:45, schrieb Anthony Liguori: > This validates some basic characteristics of fw_cfg. > > Signed-off-by: Anthony Liguori > --- > tests/Makefile | 2 + > tests/fw_cfg-test.c | 141 > > 2 files changed, 143 insertions(+) >

[Qemu-devel] [PATCH for-1.5] configure: Pick up libseccomp include path

2013-04-28 Thread Andreas Färber
openSUSE 12.3 has seccomp.h in /usr/include/libseccomp-1.0.1, so add `pkg-config --cflags libseccomp` output to QEMU_CFLAGS. Cc: qemu-sta...@nongnu.org Signed-off-by: Andreas Färber --- configure | 1 + 1 file changed, 1 insertion(+) diff --git a/configure b/configure index 21438d4..643153f 100

Re: [Qemu-devel] [PATCH RFC qom-cpu-next] apic: QOM'ify APICCommonState casts

2013-04-28 Thread Jan Kiszka
On 2013-04-28 15:53, Andreas Färber wrote: > Am 28.04.2013 15:03, schrieb Jan Kiszka: >> On 2013-04-28 13:22, Andreas Färber wrote: >>> Necessary to change the name of ICCDevice's parent object field. >>> >>> Signed-off-by: Andreas Färber --- Could any of >>> the APIC experts please review whether

Re: [Qemu-devel] [PATCH 05/30] PPC: fix hreset_vector for 60x, 7x0, 7x5, G2, MPC8xx, MPC5xx, 7400 and 7450

2013-04-28 Thread Andreas Färber
Am 26.04.2013 20:21, schrieb Alexander Graf: > From: Fabien Chouteau > > According to the different user's manuals, the vector offset for system > reset (both /HRESET and /SRESET) is 0x00100. > > This patch may break support of some executables, as the power-on start > address may change. For a

Re: [Qemu-devel] [PATCH RFC qom-cpu-next] apic: QOM'ify APICCommonState casts

2013-04-28 Thread Andreas Färber
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Am 28.04.2013 15:03, schrieb Jan Kiszka: > On 2013-04-28 13:22, Andreas Färber wrote: >> Necessary to change the name of ICCDevice's parent object field. >> >> Signed-off-by: Andreas Färber --- Could any of >> the APIC experts please review whether I

[Qemu-devel] Debug init on Qemu using gdb

2013-04-28 Thread Muhammad Nouman
Hi ! i am trying to emulate cavium octeon's mips64 linux kernel on Qemu.I am currently having some issues with init code and want to debug init .i am starting the Qemu using -s -S option in the command line and the attaching the gdb using target remote localhost:1234 What i want to ask is there any

Re: [Qemu-devel] [PATCH RFC qom-cpu-next] apic: QOM'ify APICCommonState casts

2013-04-28 Thread Jan Kiszka
On 2013-04-28 13:22, Andreas Färber wrote: > Necessary to change the name of ICCDevice's parent object field. > > Signed-off-by: Andreas Färber > --- > Could any of the APIC experts please review whether I'm touching any hot > path? > Not sure if this was a mix of pre- and post-QOM code or int

Re: [Qemu-devel] [PATCH 1/3] virtio-pci: properly validate address before accessing config

2013-04-28 Thread Petr Matousek
On Sat, Apr 27, 2013 at 01:13:16PM +0800, Jason Wang wrote: > On 04/26/2013 10:27 PM, Petr Matousek wrote: > > On Fri, Apr 26, 2013 at 04:34:02PM +0800, Jason Wang wrote: > >> There are several several issues in the current checking: > >> > >> - The check was based on the minus of unsigned values w

[Qemu-devel] [PATCH RFC qom-cpu-next] apic: QOM'ify APICCommonState casts

2013-04-28 Thread Andreas Färber
Necessary to change the name of ICCDevice's parent object field. Signed-off-by: Andreas Färber --- Could any of the APIC experts please review whether I'm touching any hot path? Not sure if this was a mix of pre- and post-QOM code or intentional... Thanks. hw/i386/kvm/apic.c | 4 ++--

Re: [Qemu-devel] [PATCH prep for-1.5] prep: Add ELF support for -bios

2013-04-28 Thread Andreas Färber
Am 28.04.2013 12:22, schrieb Alexander Graf: > > On 28.04.2013, at 12:16, Andreas Färber wrote: > >> P.S. I am happy about your review comments, but you were not >> intentionally CC'ed on a PReP patch - this is apparently the result of >> Paolo having used hw/ppc/ pattern in the ppc TCG guest cor

Re: [Qemu-devel] [PATCH prep for-1.5] prep: Add ELF support for -bios

2013-04-28 Thread Alexander Graf
On 28.04.2013, at 12:16, Andreas Färber wrote: > Am 28.04.2013 11:44, schrieb Alexander Graf: >> >> On 28.04.2013, at 02:32, Andreas Färber wrote: >> >>> This prepares for switching from OpenHack'Ware to OpenBIOS. >>> >>> Signed-off-by: Andreas Färber >>> --- >>> hw/ppc/prep.c | 21 ++

Re: [Qemu-devel] [PATCH prep for-1.5] prep: Add ELF support for -bios

2013-04-28 Thread Andreas Färber
Am 28.04.2013 11:44, schrieb Alexander Graf: > > On 28.04.2013, at 02:32, Andreas Färber wrote: > >> This prepares for switching from OpenHack'Ware to OpenBIOS. >> >> Signed-off-by: Andreas Färber >> --- >> hw/ppc/prep.c | 21 + >> 1 file changed, 13 insertions(+), 8 deletions

Re: [Qemu-devel] [PATCH v2 5/5] block: add header update capability for VHDX images.

2013-04-28 Thread Fam Zheng
On Tue, 04/23 10:24, Jeff Cody wrote: > if (flags & BDRV_O_RDWR) { > -ret = -ENOTSUP; > -goto fail; > +vhdx_update_headers(bs, s, false); Do we really have to update the header immediately on RW open? I assume when implementing vhdx_co_writev, this is guaranteed to get

Re: [Qemu-devel] [PATCH v2 3/5] block: initial VHDX driver support framework - supports open and probe

2013-04-28 Thread Fam Zheng
On Tue, 04/23 10:24, Jeff Cody wrote: > +/* opens the specified header block from the VHDX file header section */ > +static int vhdx_parse_header(BlockDriverState *bs, BDRVVHDXState *s) > +{ > +int ret = 0; > +vhdx_header *header1; > +vhdx_header *header2; > +uint64_t h1_seq = 0; >

[Qemu-devel] [PATCH] Trivial grammar and spelling fixes

2013-04-28 Thread Stefan Weil
similiar -> similar recieve -> receive transfered -> transferred preperation -> preparation Most changes are in comments, one modifies a parameter name in a function prototype. The spelling fixes were made using codespell. Signed-off-by: Stefan Weil --- More improvements are needed for include

Re: [Qemu-devel] [PATCH prep for-1.5] prep: Add ELF support for -bios

2013-04-28 Thread Alexander Graf
On 28.04.2013, at 02:32, Andreas Färber wrote: > This prepares for switching from OpenHack'Ware to OpenBIOS. > > Signed-off-by: Andreas Färber > --- > hw/ppc/prep.c | 21 + > 1 file changed, 13 insertions(+), 8 deletions(-) > > diff --git a/hw/ppc/prep.c b/hw/ppc/prep.c > in

Re: [Qemu-devel] [PATCH] virtio-net: properly check the vhost status during status set

2013-04-28 Thread Jason Wang
On 04/28/2013 04:25 PM, Michael S. Tsirkin wrote: > On Sun, Apr 28, 2013 at 03:51:32PM +0800, Jason Wang wrote: >> On 04/28/2013 03:32 AM, Michael S. Tsirkin wrote: >>> On Sat, Apr 27, 2013 at 01:11:16PM +0800, Jason Wang wrote: On 04/26/2013 08:26 PM, Michael S. Tsirkin wrote: > On Fri, A

Re: [Qemu-devel] [PATCH 2/3] virtio-ccw: check config length before accessing it

2013-04-28 Thread Jason Wang
On 04/28/2013 04:32 PM, Michael S. Tsirkin wrote: > On Fri, Apr 26, 2013 at 04:34:03PM +0800, Jason Wang wrote: >> virtio-rng-ccw has zero config length, so we need validate the config length >> before trying to access it. Otherwise we may crash since vdev->config is >> NULL. >> >> Cc: Cornelia Hu

Re: [Qemu-devel] [PATCH 3/3] s390-virtio-bus: sync config only when config_len is not zero

2013-04-28 Thread Jason Wang
On 04/28/2013 04:31 PM, Michael S. Tsirkin wrote: > On Fri, Apr 26, 2013 at 04:34:04PM +0800, Jason Wang wrote: >> virtio-rng-s390 has zero config length, so no need to sync its config >> otherwise >> qemu will crash since vdev->config is NULL. >> >> Cc: Alexander Graf >> Cc: Richard Henderson >

Re: [Qemu-devel] [PATCH 1/3] virtio-pci: properly validate address before accessing config

2013-04-28 Thread Michael S. Tsirkin
On Sun, Apr 28, 2013 at 03:54:20PM +0800, Jason Wang wrote: > On 04/28/2013 03:26 AM, Michael S. Tsirkin wrote: > > On Fri, Apr 26, 2013 at 04:34:02PM +0800, Jason Wang wrote: > >> There are several several issues in the current checking: > >> > >> - The check was based on the minus of unsigned val

Re: [Qemu-devel] [PATCH 2/3] virtio-ccw: check config length before accessing it

2013-04-28 Thread Michael S. Tsirkin
On Fri, Apr 26, 2013 at 04:34:03PM +0800, Jason Wang wrote: > virtio-rng-ccw has zero config length, so we need validate the config length > before trying to access it. Otherwise we may crash since vdev->config is NULL. > > Cc: Cornelia Huck > Cc: Richard Henderson > Cc: Alexander Graf > Signed

Re: [Qemu-devel] [PATCH 3/3] s390-virtio-bus: sync config only when config_len is not zero

2013-04-28 Thread Michael S. Tsirkin
On Fri, Apr 26, 2013 at 04:34:04PM +0800, Jason Wang wrote: > virtio-rng-s390 has zero config length, so no need to sync its config > otherwise > qemu will crash since vdev->config is NULL. > > Cc: Alexander Graf > Cc: Richard Henderson > Signed-off-by: Jason Wang Actully, it validates get_co

Re: [Qemu-devel] [PATCH] virtio-net: properly check the vhost status during status set

2013-04-28 Thread Michael S. Tsirkin
On Sun, Apr 28, 2013 at 03:51:32PM +0800, Jason Wang wrote: > On 04/28/2013 03:32 AM, Michael S. Tsirkin wrote: > > On Sat, Apr 27, 2013 at 01:11:16PM +0800, Jason Wang wrote: > >> On 04/26/2013 08:26 PM, Michael S. Tsirkin wrote: > >>> On Fri, Apr 26, 2013 at 06:27:40PM +0800, Jason Wang wrote: >

Re: [Qemu-devel] [PATCH 1/3] virtio-pci: properly validate address before accessing config

2013-04-28 Thread Jason Wang
On 04/28/2013 03:26 AM, Michael S. Tsirkin wrote: > On Fri, Apr 26, 2013 at 04:34:02PM +0800, Jason Wang wrote: >> There are several several issues in the current checking: >> >> - The check was based on the minus of unsigned values which can overflow >> - It was done after .{set|get}_config() whic

Re: [Qemu-devel] [PATCH] virtio-net: properly check the vhost status during status set

2013-04-28 Thread Jason Wang
On 04/28/2013 03:32 AM, Michael S. Tsirkin wrote: > On Sat, Apr 27, 2013 at 01:11:16PM +0800, Jason Wang wrote: >> On 04/26/2013 08:26 PM, Michael S. Tsirkin wrote: >>> On Fri, Apr 26, 2013 at 06:27:40PM +0800, Jason Wang wrote: Commit 32993698 (vhost: disable on tap link down) tries to disabl

Re: [Qemu-devel] [PATCH v2 3/5] block: initial VHDX driver support framework - supports open and probe

2013-04-28 Thread Fam Zheng
> +static void cpu_to_leguids(ms_guid *guid) > +{ > +cpu_to_le32s(&guid->data1); > +cpu_to_le16s(&guid->data2); > +cpu_to_le16s(&guid->data3); > +} This one seems used in 5/5 only, so this patch fails compiling (defined but not used with -Werror=unused-function). Maybe move to 5/5? -