[Qemu-devel] [RFC qom-cpu 05/41] cpu: Move mem_io_{pc, vaddr} fields from CPU_COMMON to CPUState

2013-09-04 Thread Andreas Färber
Reset them. Signed-off-by: Andreas Färber afaer...@suse.de --- exec.c | 4 ++-- hw/i386/kvmvapic.c | 2 +- include/exec/cpu-defs.h | 7 --- include/exec/softmmu_template.h | 10 ++ include/qom/cpu.h | 8

[Qemu-devel] [RFC qom-cpu 04/41] cpu: Turn cpu_handle_mmu_fault() into a CPUClass hook

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- include/qom/cpu.h | 3 +++ target-alpha/cpu.c| 4 +++- target-alpha/cpu.h| 5 ++--- target-alpha/helper.c | 12 target-alpha/mem_helper.c | 3 ++- target-arm/cpu.c | 4

[Qemu-devel] [RFC qom-cpu 07/41] cpu: Move icount_extra field from CPU_COMMON to CPUState

2013-09-04 Thread Andreas Färber
Reset it. Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 10 +- cpus.c | 14 +++--- include/exec/cpu-defs.h | 1 - include/qom/cpu.h | 2 ++ qom/cpu.c | 1 + 5 files changed, 15 insertions(+), 13 deletions(-)

[Qemu-devel] [RFC qom-cpu 01/41] cpu: Turn cpu_has_work() into a CPUClass hook

2013-09-04 Thread Andreas Färber
Default to false. Tidy variable naming and inline cast uses while at it. Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 5 - cpus.c | 2 +- include/qom/cpu.h | 12 ++-- qom/cpu.c | 6 ++

[Qemu-devel] [RFC qom-cpu 10/41] cpu: Move jmp_env field from CPU_COMMON to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 8 +--- include/exec/cpu-defs.h | 2 -- include/qom/cpu.h | 2 ++ user-exec.c | 3 ++- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/cpu-exec.c b/cpu-exec.c index 31331dc..39e4f8b

[Qemu-devel] [RFC qom-cpu 03/41] cpu: Turn cpu_get_tb_cpu_state() into a CPUClass hook

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 6 -- exec.c | 10 ++ hw/i386/kvmvapic.c | 8 +--- include/qom/cpu.h | 4 target-alpha/cpu.c | 24 target-alpha/cpu.h

[Qemu-devel] [RFC qom-cpu 13/41] cpu: Drop cpu_model_str from CPU_COMMON

2013-09-04 Thread Andreas Färber
Since this is only read in cpu_copy() and linux-user has a global cpu_model, drop the field from generic code. Signed-off-by: Andreas Färber afaer...@suse.de --- include/exec/cpu-defs.h | 2 -- linux-user/main.c | 4 ++-- target-alpha/cpu.c | 4 target-arm/helper.c

[Qemu-devel] [RFC qom-cpu 09/41] cpu: Move tb_jmp_cache field from CPU_COMMON to CPUState

2013-09-04 Thread Andreas Färber
Clear it on reset. Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 5 +++-- cputlb.c| 2 +- include/exec/cpu-defs.h | 4 include/qom/cpu.h | 4 qom/cpu.c | 1 + translate-all.c | 15 ++- 6 files

[Qemu-devel] [RFC qom-cpu 14/41] cpu: Move opaque field from CPU_COMMON to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- bsd-user/main.c | 2 +- gdbstub.c| 3 +-- include/exec/cpu-defs.h | 3 --- include/qom/cpu.h| 3 +++ linux-user/elfload.c | 10 ++ linux-user/linuxload.c | 3 +--

[Qemu-devel] [RFC qom-cpu 06/41] cpu: Move can_do_io field from CPU_COMMON to CPUState

2013-09-04 Thread Andreas Färber
Rename can_do_io() to cpu_can_do_io() and change argument to CPUState. Signed-off-by: Andreas Färber afaer...@suse.de --- cpus.c | 2 +- include/exec/cpu-defs.h | 1 - include/exec/exec-all.h | 21 + include/exec/gen-icount.h |

[Qemu-devel] [RFC qom-cpu 15/41] cpu: Move watchpoint fields from CPU_COMMON to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 5 +++-- exec.c | 33 - gdbstub.c | 8 include/exec/cpu-defs.h | 10 -- include/qom/cpu.h | 10 ++ linux-user/main.c |

[Qemu-devel] [RFC qom-cpu 16/41] cpu: Move breakpoints field from CPU_COMMON to CPUState

2013-09-04 Thread Andreas Färber
Most targets were using offsetof(CPUFooState, breakpoints) to determine how much of CPUFooState to clear on reset. Use the next field after CPU_COMMON instead, if any, or sizeof(CPUFooState) otherwise. Signed-off-by: Andreas Färber afaer...@suse.de --- exec.c| 21

[Qemu-devel] [RFC qom-cpu 17/41] cpu: Move tlb_flush_{addr, mask} fields from CPU_COMMON_TLB to CPUState

2013-09-04 Thread Andreas Färber
Change their type to vaddr but keep comparing target_ulongs for now. Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c| 27 ++- include/exec/cpu-defs.h | 2 -- include/qom/cpu.h | 3 +++ 3 files changed, 17 insertions(+), 15 deletions(-)

[Qemu-devel] [RFC qom-cpu 19/41] cpu-exec: Change cpu_loop_exit() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c| 14 ++ exec.c| 2 +- include/exec/exec-all.h | 2 +- target-alpha/helper.c | 4 ++-- target-alpha/mem_helper.c | 4 ++-- target-arm/op_helper.c| 6

[Qemu-devel] [RFC qom-cpu 22/41] translate-all: Change tb_check_watchpoint() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- exec.c | 2 +- translate-all.c | 4 ++-- translate-all.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/exec.c b/exec.c index 06fb881..0a81967 100644 --- a/exec.c +++ b/exec.c @@ -1480,7 +1480,7 @@ static void

[Qemu-devel] [RFC qom-cpu 21/41] translate-all: Change cpu_restore_state_from_tb() argument to CPUState

2013-09-04 Thread Andreas Färber
And normalize the argument order. Signed-off-by: Andreas Färber afaer...@suse.de --- translate-all.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/translate-all.c b/translate-all.c index 5673420..0dd6a60 100644 --- a/translate-all.c +++ b/translate-all.c @@

[Qemu-devel] [RFC qom-cpu 18/41] exec: Change tlb_fill() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- include/exec/exec-all.h | 2 +- include/exec/softmmu_template.h | 4 ++-- target-alpha/mem_helper.c | 8 +--- target-arm/op_helper.c | 12 +++- target-cris/op_helper.c | 7 ---

[Qemu-devel] [RFC qom-cpu 28/41] exec: Change cpu_breakpoint_{insert, remove{, _by_ref, _all}} argument

2013-09-04 Thread Andreas Färber
Use CPUState. Allows to clean up CPUArchState in gdbstub. Signed-off-by: Andreas Färber afaer...@suse.de --- exec.c | 20 gdbstub.c | 20 include/exec/cpu-all.h | 15 --- include/qom/cpu.h | 15

[Qemu-devel] [RFC qom-cpu 26/41] target-ppc: Use PowerPCCPU in PowerPCCPUClass::handle_mmu_fault hook

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- target-ppc/cpu-qom.h| 8 +--- target-ppc/mmu-hash32.c | 5 +++-- target-ppc/mmu-hash32.h | 2 +- target-ppc/mmu-hash64.c | 5 +++-- target-ppc/mmu-hash64.h | 2 +- target-ppc/mmu_helper.c | 2 +- 6 files changed, 14 insertions(+), 10

[Qemu-devel] [RFC qom-cpu 37/41] target-microblaze: Replace DisasContext::env field with MicroBlazeCPU

2013-09-04 Thread Andreas Färber
This cleans up some mb_env_get_cpu() needed for cpu_abort(). Signed-off-by: Andreas Färber afaer...@suse.de --- target-microblaze/translate.c | 84 +-- 1 file changed, 40 insertions(+), 44 deletions(-) diff --git a/target-microblaze/translate.c

[Qemu-devel] [RFC qom-cpu 24/41] translate-all: Change tb_gen_code() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 4 ++-- exec.c | 2 +- hw/i386/kvmvapic.c | 2 +- include/exec/exec-all.h | 2 +- translate-all.c | 9 + 5 files changed, 10 insertions(+), 9 deletions(-) diff --git a/cpu-exec.c

[Qemu-devel] [RFC qom-cpu 27/41] exec: Change cpu_watchpoint_{insert, remove{, _by_ref, _all}} argument

2013-09-04 Thread Andreas Färber
Use CPUState. This lets us drop a few local env usages. Signed-off-by: Andreas Färber afaer...@suse.de --- exec.c| 34 +- gdbstub.c | 17 + include/exec/cpu-all.h| 6 -- include/qom/cpu.h | 7

Re: [Qemu-devel] question about qemu disk cache mode

2013-09-04 Thread xuanmao_001
I understand the physical disk cache and host page cache. I want to the difference between guest disk write cache and host page cache that described with Caching modes in Qemu in https://events.linuxfoundation.org/slides/2011/linuxcon-japan/lcj2011_hajnoczi.pdf give me some more information

[Qemu-devel] [RFC qom-cpu 31/41] exec: Change memory_region_section_get_iotlb() argument to CPUState

2013-09-04 Thread Andreas Färber
It no longer needs CPUArchState since moving watchpoints to CPUState. Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 3 ++- exec.c| 3 +-- include/exec/cputlb.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cputlb.c b/cputlb.c

[Qemu-devel] [RFC qom-cpu 33/41] cputlb: Change tlb_set_page() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 4 ++-- include/exec/exec-all.h| 2 +- target-alpha/helper.c | 2 +- target-arm/helper.c| 2 +- target-cris/helper.c | 2 +- target-i386/helper.c | 2 +- target-lm32/helper.c | 6

[Qemu-devel] [RFC qom-cpu 32/41] cputlb: Change tlb_set_page() argument to CPUState

2013-09-04 Thread Andreas Färber
It no longer needs CPUArchState since moving tlb_flush_* to CPUState. Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/cputlb.c b/cputlb.c index e5b6145..ddcd2cd 100644 --- a/cputlb.c +++ b/cputlb.c @@ -212,10

[Qemu-devel] [RFC qom-cpu 41/41] user-exec: Change exception_action() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- user-exec.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/user-exec.c b/user-exec.c index 3b795c1..bc58056 100644 --- a/user-exec.c +++ b/user-exec.c @@ -38,11 +38,12 @@ //#define DEBUG_SIGNAL -static void

[Qemu-devel] [RFC qom-cpu 36/41] target-lm32: Replace DisasContext::env field with LM32CPU

2013-09-04 Thread Andreas Färber
This cleans up some lm32_env_get_cpu() introduced for cpu_abort(). Signed-off-by: Andreas Färber afaer...@suse.de --- target-lm32/translate.c | 60 - 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/target-lm32/translate.c

[Qemu-devel] [RFC qom-cpu 38/41] target-lm32: Move features field from CPULM32State to LM32CPU

2013-09-04 Thread Andreas Färber
This simplifies the code after conversion to DisasContext::cpu. Signed-off-by: Andreas Färber afaer...@suse.de --- target-lm32/cpu-qom.h | 3 +++ target-lm32/cpu.h | 2 -- target-lm32/helper.c| 2 +- target-lm32/translate.c | 16 4 files changed, 12 insertions(+),

[Qemu-devel] [RFC qom-cpu 40/41] cputlb: Change tlb_flush() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 6 +++--- exec.c | 4 +--- hw/sh4/sh7750.c| 2 +- include/exec/exec-all.h| 4 ++-- target-alpha/cpu.c | 2 +-

[Qemu-devel] [RFC qom-cpu 39/41] cputlb: Change tlb_flush_page() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 4 +-- exec.c | 7 ++ include/exec/exec-all.h | 4 +-- target-alpha/sys_helper.c| 2 +- target-arm/helper.c | 8 -- target-cris/mmu.c| 3 ++-

[Qemu-devel] [PATCH resend] sdl: Reverse support for video mode setting

2013-09-04 Thread Lei Li
Currently, If the setting of video mode failed, qemu will exit. It should go back to the previous setting if the new screen resolution failed. This patch fixes LP#1216368, add support to revert to existing surface for the failure of video mode setting. Reported-by: Sascha Krissler

Re: [Qemu-devel] [RFC] qcow2 journalling draft

2013-09-04 Thread Benoît Canet
+They consist of transactions, which in turn contain operations that +are effectively executed atomically. A qcow2 image can have a main image +journal that deals with cluster management operations, and additional specific +journals can be used by other features like data deduplication.

Re: [Qemu-devel] [RFC] qcow2 journalling draft

2013-09-04 Thread Kevin Wolf
First of all, excuse any inconsistencies in the following mail. I wrote it from top to bottom, and there was some thought process involved in almost every paragraph... Am 04.09.2013 um 10:03 hat Stefan Hajnoczi geschrieben: On Tue, Sep 03, 2013 at 03:45:52PM +0200, Kevin Wolf wrote: @@ -103,7

[Qemu-devel] [RFC qom-cpu 20/41] translate-all: Change cpu_restore_state() argument to CPUState

2013-09-04 Thread Andreas Färber
This lets us drop some local variables in tlb_fill() functions. Signed-off-by: Andreas Färber afaer...@suse.de --- hw/i386/kvmvapic.c| 2 +- include/exec/exec-all.h | 2 +- target-alpha/helper.c | 2 +- target-alpha/mem_helper.c | 7 ++-

[Qemu-devel] [RFC qom-cpu 25/41] translate-all: Change tb_flush_jmp_cache() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 2 +- include/exec/cputlb.h | 2 +- translate-all.c | 3 +-- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/cputlb.c b/cputlb.c index e02663c..3721bfc 100644 --- a/cputlb.c +++ b/cputlb.c @@ -120,7

Re: [Qemu-devel] [PATCH] target-arm: fix ARMv7M stack alignment on reset

2013-09-04 Thread Peter Maydell
On 4 September 2013 10:23, Sebastian Ottlik ott...@fzi.de wrote: When the initial SP is loaded from the vector table on ARMv7M systems the two least significant bits are ignored as the stack is always aligned at a four byte boundary (see ARM DDI 0403C, B1.4.1 and B1.5.5). So far QEMU did not

Re: [Qemu-devel] [PATCH] kvm: fix traces to use %x instead of %d

2013-09-04 Thread Stefan Hajnoczi
On Tue, Sep 03, 2013 at 04:43:46PM +1000, Alexey Kardashevskiy wrote: KVM request types are normally defined using hex constants but QEMU traces print decimal values instead what is not very convinient. This changes the request type format from %d to %x. Signed-off-by: Alexey Kardashevskiy

[Qemu-devel] [RFC qom-cpu 29/41] cpu-exec: Change cpu_resume_from_signal() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 4 +--- exec.c | 3 +-- hw/i386/kvmvapic.c | 3 +-- include/exec/exec-all.h | 2 +- target-i386/helper.c| 2 +- target-xtensa/helper.c | 2 +- translate-all.c | 12 ++--

Re: [Qemu-devel] question about qemu disk cache mode

2013-09-04 Thread Stefan Hajnoczi
On Wed, Sep 04, 2013 at 11:47:04AM +0800, xuanmao_001 wrote: my qemu-kvm version is 1.0.1 I would like to figure out the qemu disk cache mode. I have visited the qemu-options.hx there is two cache that I didn't understand: the host cache page and the qemu disk write cache. Is host page

[Qemu-devel] [RFC qom-cpu 12/41] cpu: Move cpu_copy() into linux-user

2013-09-04 Thread Andreas Färber
It is only used there and is deemed very fragile if not incorrect in its current memcpy() form. Moving it into linux-user will allow to move parts into target_cpu.h headers and only copy what the ABI mandates. Signed-off-by: Andreas Färber afaer...@suse.de --- exec.c| 32

Re: [Qemu-devel] question about qemu disk cache mode

2013-09-04 Thread Kevin Wolf
Am 04.09.2013 um 11:07 hat xuanmao_001 geschrieben: I understand the physical disk cache and host page cache. I want to the difference between guest disk write cache and host page cache that described with Caching modes in Qemu in

[Qemu-devel] [RFC qom-cpu 30/41] cputlb: Change tlb_update_dirty() argument to CPUState

2013-09-04 Thread Andreas Färber
This allows to drop env in tb_invalidate_phys_page_range(). Note that the argument is unused. Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 2 +- include/exec/cputlb.h | 2 +- translate-all.c | 12 ++-- 3 files changed, 4 insertions(+), 12

Re: [Qemu-devel] [RFC] qcow2 journalling draft

2013-09-04 Thread Kevin Wolf
Am 04.09.2013 um 10:32 hat Max Reitz geschrieben: On 2013-09-03 15:45, Kevin Wolf wrote: This contains an extension of the qcow2 spec that introduces journalling to the image format, plus some preliminary type definitions and function prototypes in the qcow2 code. Journalling functionality

[Qemu-devel] [PATCH V12 03/13] NUMA: Add numa_info structure to contain numa nodes info

2013-09-04 Thread Wanlong Gao
Add the numa_info structure to contain the numa nodes memory, VCPUs information and the future added numa nodes host memory policies. Reviewed-by: Eduardo Habkost ehabk...@redhat.com Signed-off-by: Andre Przywara andre.przyw...@amd.com Signed-off-by: Wanlong Gao gaowanl...@cn.fujitsu.com ---

Re: [Qemu-devel] [PATCH v5] powerpc: add PVR mask support

2013-09-04 Thread Alexey Kardashevskiy
On 08/28/2013 09:01 PM, Alexey Kardashevskiy wrote: On 08/28/2013 08:49 PM, Andreas Färber wrote: Am 28.08.2013 12:37, schrieb Alexey Kardashevskiy: IBM POWERPC processors encode PVR as a CPU family in higher 16 bits and a CPU version in lower 16 bits. Since there is no significant change in

[Qemu-devel] [RFC PATCH] spapr: add initial ibm, client-architecture-support rtas call support

2013-09-04 Thread Alexey Kardashevskiy
This is an RFC patch. The modern Linux kernel supports every known POWERPC CPU so when it boots, it can always find a matching cpu_spec from the cpu_specs array. However if the kernel is quite old, it may be missing the definition of the actual CPU. To provide ability for old kernels to work

[Qemu-devel] [RFC qom-cpu 23/41] translate-all: Change cpu_io_recompile() argument to CPUState

2013-09-04 Thread Andreas Färber
Signed-off-by: Andreas Färber afaer...@suse.de --- include/exec/exec-all.h | 2 +- include/exec/softmmu_template.h | 4 ++-- translate-all.c | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/include/exec/exec-all.h b/include/exec/exec-all.h index

[Qemu-devel] [RFC qom-cpu 35/41] target-cris: Replace DisasContext::env field with CRISCPU

2013-09-04 Thread Andreas Färber
This cleans up repeated cris_env_get_cpu() for cpu_abort(). Signed-off-by: Andreas Färber afaer...@suse.de --- target-cris/translate.c | 16 target-cris/translate_v10.c | 16 2 files changed, 16 insertions(+), 16 deletions(-) diff --git

[Qemu-devel] [PATCH] target-arm: fix ARMv7M stack alignment on reset

2013-09-04 Thread Sebastian Ottlik
When the initial SP is loaded from the vector table on ARMv7M systems the two least significant bits are ignored as the stack is always aligned at a four byte boundary (see ARM DDI 0403C, B1.4.1 and B1.5.5). So far QEMU did not ignore these bits leading to a stack alignment inconsitent with real

Re: [Qemu-devel] [PATCH] qemu-iotests: Fixed test case 026

2013-09-04 Thread Stefan Hajnoczi
On Mon, Sep 02, 2013 at 03:07:39PM +0200, Kevin Wolf wrote: Am 02.09.2013 um 14:58 hat Stefan Hajnoczi geschrieben: On Mon, Sep 02, 2013 at 02:42:00PM +0200, Kevin Wolf wrote: diff --git a/tests/qemu-iotests/check b/tests/qemu-iotests/check index 74628ae..42d6955 100755 ---

Re: [Qemu-devel] [RFC] qcow2 journalling draft

2013-09-04 Thread Benoît Canet
I'm not sure if multiple journals will work in practice. Doesn't this re-introduce the need to order update steps and flush between them? This is a question for Benoît, who made this requirement. I asked him the same a while ago and apparently his explanation made some sense to me, or I

Re: [Qemu-devel] [RFC qom-cpu 03/41] cpu: Turn cpu_get_tb_cpu_state() into a CPUClass hook

2013-09-04 Thread Paolo Bonzini
Il 04/09/2013 11:04, Andreas Färber ha scritto: static inline TranslationBlock *tb_find_fast(CPUArchState *env) { +CPUState *cpu = ENV_GET_CPU(env); +CPUClass *cc = CPU_GET_CLASS(cpu); TranslationBlock *tb; -target_ulong cs_base, pc; +vaddr cs_base, pc; int

[Qemu-devel] [PATCH v2] kvm: fix traces to use %x instead of %d

2013-09-04 Thread Alexey Kardashevskiy
KVM request types are normally defined using hex constants but QEMU traces print decimal values instead, which is not very convenient. This changes the request type format from %d to %x. Signed-off-by: Alexey Kardashevskiy a...@ozlabs.ru Reviewed-by: Andreas Färber afaer...@suse.de Reviewed-by:

Re: [Qemu-devel] question about qemu disk cache mode

2013-09-04 Thread xuanmao_001
so, the guest disk write cache just only for none and writeback cache mode? the cache allocate on host for disk file image by qemu? xuanmao_001 From: Kevin Wolf Date: 2013-09-04 17:45 To: xuanmao_001 CC: qemu-devel; qemu-discuss Subject: Re: Re: question about qemu disk cache mode Am

[Qemu-devel] [PATCH] dump-guest-memory: Check for the correct return value

2013-09-04 Thread Aneesh Kumar K.V
From: Aneesh Kumar K.V aneesh.ku...@linux.vnet.ibm.com We should check for error with s-note_size Signed-off-by: Aneesh Kumar K.V aneesh.ku...@linux.vnet.ibm.com --- dump.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dump.c b/dump.c index c0dae2c..80dd9d6 100644 ---

Re: [Qemu-devel] [RFC PATCH] spapr: add initial ibm, client-architecture-support rtas call support

2013-09-04 Thread Alexander Graf
On 04.09.2013, at 12:19, Alexey Kardashevskiy wrote: This is an RFC patch. The modern Linux kernel supports every known POWERPC CPU so when it boots, it can always find a matching cpu_spec from the cpu_specs array. However if the kernel is quite old, it may be missing the definition of

[Qemu-devel] [PATCH 0/6] pci: keep window properties up to date

2013-09-04 Thread Michael S. Tsirkin
w32/w64 properties that we report in QOM are currently static, but this is wrong: guest firmware can select its own windows: optimal placement for w64 is guest-dependent, further, for Q35, w32 is affected by the MCFG base and size. This detects the actual window configuration used by guest and

[Qemu-devel] [PATCH 1/6] q35: make pci window address/size match guest cfg

2013-09-04 Thread Michael S. Tsirkin
For Q35, MMCFG address and size are guest configurable. Update w32 property to make it behave accordingly. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- hw/pci-host/q35.c | 10 ++ 1 file changed, 10 insertions(+) diff --git a/hw/pci-host/q35.c b/hw/pci-host/q35.c index

[Qemu-devel] [PATCH 2/6] range: add Range to typedefs

2013-09-04 Thread Michael S. Tsirkin
will help simplify header dependencies. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- include/qemu/range.h| 2 +- include/qemu/typedefs.h | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/include/qemu/range.h b/include/qemu/range.h index b76cc0d..4a0780d 100644 ---

[Qemu-devel] [PATCH 4/6] pci: add helper to retrieve the 64-bit range

2013-09-04 Thread Michael S. Tsirkin
Signed-off-by: Michael S. Tsirkin m...@redhat.com --- include/hw/pci/pci.h | 1 + hw/pci/pci.c | 43 +++ 2 files changed, 44 insertions(+) diff --git a/include/hw/pci/pci.h b/include/hw/pci/pci.h index 2374aa9..7be93ae 100644 ---

[Qemu-devel] [PATCH 3/6] range: add min/max operations on ranges

2013-09-04 Thread Michael S. Tsirkin
Signed-off-by: Michael S. Tsirkin m...@redhat.com --- include/qemu/range.h | 17 + 1 file changed, 17 insertions(+) diff --git a/include/qemu/range.h b/include/qemu/range.h index 4a0780d..1c688ca 100644 --- a/include/qemu/range.h +++ b/include/qemu/range.h @@ -17,6 +17,23 @@

[Qemu-devel] [PATCH 5/6] q35: use 64 bit window programmed by guest

2013-09-04 Thread Michael S. Tsirkin
Detect the 64 bit window programmed by firmware and configure properties accordingly. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- hw/pci-host/q35.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/hw/pci-host/q35.c b/hw/pci-host/q35.c index 3f1d447..5cb1e8a 100644 ---

[Qemu-devel] [PATCH 6/6] piix: use 64 bit window programmed by guest

2013-09-04 Thread Michael S. Tsirkin
Detect the 64 bit window programmed by firmware and configure properties accordingly. Signed-off-by: Michael S. Tsirkin m...@redhat.com --- hw/pci-host/piix.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/hw/pci-host/piix.c b/hw/pci-host/piix.c index 221d82b..9e7f82a 100644 ---

Re: [Qemu-devel] [Qemu-trivial] [PATCH] cputlb: remove dead function tlb_update_dirty

2013-09-04 Thread Paolo Bonzini
Il 03/09/2013 18:54, Andreas Färber ha scritto: Also, I am seeing Paolo pull in huge memory changes but now pinging the breakage fixes rather than assembling a pull to fix the fallout. ;) Well, I didn't put myself as memory maintainer for a reason. :) But it looks like a pull request is the

Re: [Qemu-devel] [RFC qom-cpu 03/41] cpu: Turn cpu_get_tb_cpu_state() into a CPUClass hook

2013-09-04 Thread Andreas Färber
Am 04.09.2013 12:26, schrieb Paolo Bonzini: Il 04/09/2013 11:04, Andreas Färber ha scritto: static inline TranslationBlock *tb_find_fast(CPUArchState *env) { +CPUState *cpu = ENV_GET_CPU(env); +CPUClass *cc = CPU_GET_CLASS(cpu); TranslationBlock *tb; -target_ulong

[Qemu-devel] [PATCH v2 0/2] qemu-iotests: Fixed test case 026

2013-09-04 Thread Kevin Wolf
Kevin Wolf (2): qemu-iotests: Whitespace cleanup qemu-iotests: Fixed test case 026 tests/qemu-iotests/026.out | 28 +- tests/qemu-iotests/026.out.nocache | 626 + tests/qemu-iotests/check | 240 +++--- tests/qemu-iotests/common

[Qemu-devel] [PATCH v2 2/2] qemu-iotests: Fixed test case 026

2013-09-04 Thread Kevin Wolf
The reference output for test case 026 hasn't been updated in a long time and it's one of the known failing cases. This patch updates the reference output so that unintentional changes can be reliably detected again. The problem with this test case is that it produces different output depending

[Qemu-devel] [PATCH v2 1/2] qemu-iotests: Whitespace cleanup

2013-09-04 Thread Kevin Wolf
These scripts used to have a four characters indentation, with eight consecutive spaces converted into a tab. Convert everything into spaces. Signed-off-by: Kevin Wolf kw...@redhat.com --- tests/qemu-iotests/check | 234 ++--- tests/qemu-iotests/common | 422

Re: [Qemu-devel] [RFC qom-cpu 03/41] cpu: Turn cpu_get_tb_cpu_state() into a CPUClass hook

2013-09-04 Thread Paolo Bonzini
Il 04/09/2013 13:02, Andreas Färber ha scritto: Am 04.09.2013 12:26, schrieb Paolo Bonzini: Another is to change cpu-exec.c into a file that is #included by target-*/helper.c or something like that. This way cpu-exec.c can still use the inline functions. I don't see how that would help

Re: [Qemu-devel] [RFC v2 05/15] Make qcow2_open synchronous

2013-09-04 Thread Stefan Hajnoczi
On Thu, Aug 29, 2013 at 01:43:02PM +0100, Charlie Shepherd wrote: On 29/08/2013 13:33, Stefan Hajnoczi wrote: On Fri, Aug 09, 2013 at 07:43:55PM +0200, Charlie Shepherd wrote: The previous patch convert all .bdrv_open functions to run from a coroutine context. However qcow2's open method is

Re: [Qemu-devel] [RFC PATCH] spapr: add initial ibm, client-architecture-support rtas call support

2013-09-04 Thread Alexey Kardashevskiy
On 09/04/2013 08:42 PM, Alexander Graf wrote: On 04.09.2013, at 12:19, Alexey Kardashevskiy wrote: This is an RFC patch. The modern Linux kernel supports every known POWERPC CPU so when it boots, it can always find a matching cpu_spec from the cpu_specs array. However if the kernel is

[Qemu-devel] public key not found?

2013-09-04 Thread Michael S. Tsirkin
I noticed recent merges of the pci tree have this text: # gpg: Signature made Sun 01 Sep 2013 03:15:36 AM CDT using RSA key # ID D28D5469 # gpg: Can't check signature: public key not found Why is that? Linus seems to have no trouble pulling trees with this signature, and pulls don't

Re: [Qemu-devel] [RFC PATCH] spapr: add initial ibm, client-architecture-support rtas call support

2013-09-04 Thread Benjamin Herrenschmidt
On Wed, 2013-09-04 at 21:40 +1000, Alexey Kardashevskiy wrote: One of the examples (came from Paul) is: the host runs on POWER8, the guest boots a kernel which is capable of POWER7 only + POWER7-compat. We do this reboot tweak and boot in POWER7-compat mode. Then the guest does yum update and

Re: [Qemu-devel] [RFC PATCH] spapr: add initial ibm, client-architecture-support rtas call support

2013-09-04 Thread Alexander Graf
On 04.09.2013, at 13:40, Alexey Kardashevskiy wrote: On 09/04/2013 08:42 PM, Alexander Graf wrote: On 04.09.2013, at 12:19, Alexey Kardashevskiy wrote: This is an RFC patch. The modern Linux kernel supports every known POWERPC CPU so when it boots, it can always find a matching

[Qemu-devel] [PATCH RFC] dataplane: Fix startup race.

2013-09-04 Thread Cornelia Huck
Avoid trying to setup dataplane again if dataplane setup is already in progress. This may happen if an eventfd is triggered during setup. I saw this occasionally with an experimental s390 irqfd implementation: virtio_blk_handle_output - virtio_blk_data_plane_start - virtio_ccw_set_host_notifier

Re: [Qemu-devel] [qemu-devel]question on virtqueue_get_avail_bytes

2013-09-04 Thread Amit Shah
On (Tue) 03 Sep 2013 [14:15:55], Michael S. Tsirkin wrote: On Tue, Sep 03, 2013 at 04:40:21PM +0530, Amit Shah wrote: On (Mon) 19 Aug 2013 [16:30:54], Stefan Hajnoczi wrote: On Mon, Aug 19, 2013 at 05:28:44PM +0800, yinyin wrote: Hi,all: in func virtqueue_get_avail_bytes,

[Qemu-devel] [PATCH] seccomp: adding times() to the whitelist

2013-09-04 Thread Eduardo Otubo
This was causing Qemu process to hang when using -sandbox on. Related RHBZ: https://bugzilla.redhat.com/show_bug.cgi?id=1004175 Signed-off-by: Eduardo Otubo ot...@linux.vnet.ibm.com --- qemu-seccomp.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/qemu-seccomp.c

Re: [Qemu-devel] [PATCH v3 1/2] block: allow live commit of active image

2013-09-04 Thread Stefan Hajnoczi
On Thu, Aug 15, 2013 at 04:14:06PM +0800, Fam Zheng wrote: diff --git a/block/commit.c b/block/commit.c index 2227fc2..b5e024b 100644 --- a/block/commit.c +++ b/block/commit.c @@ -17,14 +17,13 @@ #include block/blockjob.h #include qemu/ratelimit.h -enum { -/* - * Size of

Re: [Qemu-devel] [RFC qom-cpu 01/41] cpu: Turn cpu_has_work() into a CPUClass hook

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:04 PM, Andreas Färber afaer...@suse.de wrote: Default to false. Tidy variable naming and inline cast uses while at it. Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c | 5 - cpus.c | 2 +-

Re: [Qemu-devel] [RFC qom-cpu 02/41] cpu: Turn cpu_mmu_index() into a CPUClass hook

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:04 PM, Andreas Färber afaer...@suse.de wrote: Default to 0. Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 7 +++ include/exec/softmmu_header.h | 4 ++-- include/qom/cpu.h | 15 +++ qom/cpu.c

Re: [Qemu-devel] [PATCH 0/8] [PATCH RFC v3] s390 cpu hotplug

2013-09-04 Thread Andreas Färber
Hello, Am 01.08.2013 16:12, schrieb Jason J. Herne: From: Jason J. Herne jjhe...@us.ibm.com Latest code for cpu Hotplug on S390 architecture. This one is vastly simpler than v2 as we have decided to avoid the command line specification of -device s390-cpu. The last version can be

Re: [Qemu-devel] [RFC qom-cpu 13/41] cpu: Drop cpu_model_str from CPU_COMMON

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:04 PM, Andreas Färber afaer...@suse.de wrote: Since this is only read in cpu_copy() and linux-user has a global cpu_model, drop the field from generic code. Signed-off-by: Andreas Färber afaer...@suse.de --- include/exec/cpu-defs.h | 2 -- linux-user/main.c

Re: [Qemu-devel] [RFC qom-cpu 16/41] cpu: Move breakpoints field from CPU_COMMON to CPUState

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:04 PM, Andreas Färber afaer...@suse.de wrote: Most targets were using offsetof(CPUFooState, breakpoints) to determine how much of CPUFooState to clear on reset. Use the next field after CPU_COMMON instead, if any, or sizeof(CPUFooState) otherwise. Signed-off-by:

Re: [Qemu-devel] [PATCH 0/3 resend v2] Migration fix

2013-09-04 Thread Orit Wasserman
On 09/04/2013 12:02 PM, Lei Li wrote: This small patch series is extracted from localhost migration series that Paolo reviewed positively, send it separately as his request. It fixs wrong initialization in RDMA hook ram_control_load_hook() and gets rid of the negative check for

Re: [Qemu-devel] [RFC qom-cpu 19/41] cpu-exec: Change cpu_loop_exit() argument to CPUState

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:04 PM, Andreas Färber afaer...@suse.de wrote: Signed-off-by: Andreas Färber afaer...@suse.de --- cpu-exec.c| 14 ++ exec.c| 2 +- include/exec/exec-all.h | 2 +- target-alpha/helper.c | 4 ++--

Re: [Qemu-devel] [RFC qom-cpu 18/41] exec: Change tlb_fill() argument to CPUState

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:04 PM, Andreas Färber afaer...@suse.de wrote: Signed-off-by: Andreas Färber afaer...@suse.de --- include/exec/exec-all.h | 2 +- include/exec/softmmu_template.h | 4 ++-- target-alpha/mem_helper.c | 8 +--- target-arm/op_helper.c | 12

Re: [Qemu-devel] [RFC qom-cpu 20/41] translate-all: Change cpu_restore_state() argument to CPUState

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:05 PM, Andreas Färber afaer...@suse.de wrote: This lets us drop some local variables in tlb_fill() functions. Signed-off-by: Andreas Färber afaer...@suse.de --- hw/i386/kvmvapic.c| 2 +- include/exec/exec-all.h | 2 +- target-alpha/helper.c

Re: [Qemu-devel] [RFC qom-cpu 40/41] cputlb: Change tlb_flush() argument to CPUState

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:05 PM, Andreas Färber afaer...@suse.de wrote: Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 6 +++--- exec.c | 4 +--- hw/sh4/sh7750.c| 2 +- include/exec/exec-all.h

Re: [Qemu-devel] [RFC qom-cpu 39/41] cputlb: Change tlb_flush_page() argument to CPUState

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:05 PM, Andreas Färber afaer...@suse.de wrote: Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 4 +-- exec.c | 7 ++ include/exec/exec-all.h | 4 +-- target-alpha/sys_helper.c| 2 +-

Re: [Qemu-devel] [RFC qom-cpu 33/41] cputlb: Change tlb_set_page() argument to CPUState

2013-09-04 Thread Jia Liu
On Wed, Sep 4, 2013 at 5:05 PM, Andreas Färber afaer...@suse.de wrote: Signed-off-by: Andreas Färber afaer...@suse.de --- cputlb.c | 4 ++-- include/exec/exec-all.h| 2 +- target-alpha/helper.c | 2 +- target-arm/helper.c| 2 +- target-cris/helper.c

Re: [Qemu-devel] [RFC qom-cpu 02/41] cpu: Turn cpu_mmu_index() into a CPUClass hook

2013-09-04 Thread Andreas Färber
Am 04.09.2013 14:42, schrieb Jia Liu: On Wed, Sep 4, 2013 at 5:04 PM, Andreas Färber afaer...@suse.de wrote: Default to 0. Signed-off-by: Andreas Färber afaer...@suse.de Paolo has indicated that patches 2 and 3 shouldn't be applied since they touch on TCG hot paths, replacing an inline

Re: [Qemu-devel] [PATCH 0/8] [PATCH RFC v3] s390 cpu hotplug

2013-09-04 Thread Luiz Capitulino
On Wed, 04 Sep 2013 14:45:44 +0200 Andreas Färber afaer...@suse.de wrote: = cpu_num != cpu_index With all that in mind, I'll now need to review the s390 patches again. For the HMP patch I am waiting on feedback from Igor once he returns from his vacation and, if there are no objections,

Re: [Qemu-devel] [RFC PATCH] spapr: add initial ibm, client-architecture-support rtas call support

2013-09-04 Thread Alexey Kardashevskiy
On 09/04/2013 09:54 PM, Benjamin Herrenschmidt wrote: On Wed, 2013-09-04 at 21:40 +1000, Alexey Kardashevskiy wrote: One of the examples (came from Paul) is: the host runs on POWER8, the guest boots a kernel which is capable of POWER7 only + POWER7-compat. We do this reboot tweak and boot in

Re: [Qemu-devel] [PATCH 0/8] [PATCH RFC v3] s390 cpu hotplug

2013-09-04 Thread Andreas Färber
Am 04.09.2013 14:56, schrieb Luiz Capitulino: On Wed, 04 Sep 2013 14:45:44 +0200 Andreas Färber afaer...@suse.de wrote: For the HMP patch I am waiting on feedback from Igor once he returns from his vacation and, if there are no objections, would like to see that patch go through Luiz' queue

[Qemu-devel] [PATCH] Convert ram_list to RCU DQ V3

2013-09-04 Thread Mike Day
Changes from V2: * added rcu reclaim function to free ram blocks * reduced the number of comments * made rcu locking policy consistent for different caller scenarios * rcu updates to ram_block now are protected only by the iothread mutex Changes from V1: * Omitted locks or rcu critical sections

Re: [Qemu-devel] [PATCH RFC] Do not set SO_REUSEADDR on Windows

2013-09-04 Thread Jan Kiszka
On 2013-09-04 16:27, Paolo Bonzini wrote: Il 04/09/2013 16:22, Sebastian Ottlik ha scritto: This patchset disabels all use of SO_REUSEADDR on Windows. On Windows systems the default behavior is equivalent to SO_REUSEADDR on other operating systems. SO_REUSEADDR can still be set but results in

Re: [Qemu-devel] [PATCH RFC] Do not set SO_REUSEADDR on Windows

2013-09-04 Thread Sebastian Ottlik
On 04.09.2013 16:27, Paolo Bonzini wrote: Il 04/09/2013 16:22, Sebastian Ottlik ha scritto: This patchset disabels all use of SO_REUSEADDR on Windows. On Windows systems the default behavior is equivalent to SO_REUSEADDR on other operating systems. SO_REUSEADDR can still be set but results in

Re: [Qemu-devel] [PATCH v2] exec: do tcg_commit only when tcg_enabled

2013-09-04 Thread Richard Henderson
On 09/03/2013 11:37 PM, liguang wrote: Signed-off-by: liguang lig.f...@cn.fujitsu.com --- exec.c |4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/exec.c b/exec.c index 3ca9381..2170295 100644 --- a/exec.c +++ b/exec.c @@ -1824,7 +1824,9 @@ static void

Re: [Qemu-devel] Questions about hvm domU default devices with upstream qemu

2013-09-04 Thread Fabio Fantoni
Il 04/09/2013 15:17, Stefano Stabellini ha scritto: On Wed, 4 Sep 2013, Fabio Fantoni wrote: Il 04/07/2013 15:51, Fabio Fantoni ha scritto: Last year I posted a question about default devices of upstream qemu that differ from qemu traditional, like empty floppy and cdrom in particular. About

  1   2   3   >