[Qemu-devel] [PATCH] fix qemu compile error with --enable-debug

2012-07-03 Thread Wanpeng Li
From: Wanpeng Li l...@linux.vnet.ibm.com CC i386-softmmu/target-i386/translate.o /home/kernel/qemu/target-i386/translate.c: In function ‘gen_sse’: /home/kernel/qemu/target-i386/translate.c:3571:27: error: assignment from incompatible pointer type [-Werror] /home/kernel/qemu/target-i386

Re: [Qemu-devel] [PATCH] fix qemu compile error with --enable-debug

2012-07-03 Thread Wanpeng Li
On Wed, Jul 04, 2012 at 10:51:25AM +0800, Dunrong Huang wrote: There have been two discussions about this error: http://lists.nongnu.org/archive/html/qemu-devel/2012-06/msg04858.html and http://lists.nongnu.org/archive/html/qemu-devel/2012-06/msg04728.html Oh, thank you! 2012/7/4 Wanpeng Li

[Qemu-devel] [PATCH] cleanup pc_vga_init function

2012-07-04 Thread Wanpeng Li
From: Wanpeng Li l...@linux.vnet.ibm.com Since function pc_vga_init doesn't need to return DeviceState any more, just cleanup. Signed-off-by: Wanpneg Li liwp.li...@gmail.com --- hw/pc.c | 18 +++--- hw/pc.h |2 +- 2 files changed, 8 insertions(+), 12 deletions(-) diff --git

[Qemu-devel] [BUG] guest os oops when run in upstream qemu x86_64

2012-07-05 Thread Wanpeng Li
) during guest os boot no --enable-kvm has -m 1024 guest os will block during guest os boot has --enable-kvm no -m guest os will block during guest os boot has --enable-kvm has -m 1024 run normally Regards, Wanpeng Li

[Qemu-devel] [PATCH v4 3/5] convert pci-host to QOM

2012-07-18 Thread Wanpeng Li
[CCing ML] From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/pci_host.c | 26 ++ hw/pci_host.h |5 + 2 files changed, 31 insertions(+), 0 deletions(-) diff

[Qemu-devel] [PATCH v4 2/5] convert MemoryRegion to QOM

2012-07-18 Thread Wanpeng Li
[CCing ML] From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- memory.c | 94 ++ memory.h |8 + 2 files changed, 78 insertions

[Qemu-devel] [PATCH v4 4/5] prepare to create HPET, RTC and i8254 through composition

2012-07-18 Thread Wanpeng Li
it in the PIIX is rational. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/hpet.c | 39 ++- hw/hpet_emul.h | 41 + hw/i8254.c |2

[Qemu-devel] [PATCH v4 1/5] eliminate piix_pci.c and module i440fx and piix3

2012-07-18 Thread Wanpeng Li
the fact that the PMC is contained within the i440fx which we will now reflect in composition in the next few changesets. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/i386/Makefile.objs |2 +- hw/i440fx.c | 434

[Qemu-devel] [PATCH v4 0/5] refactor PC machine, i440fx and piix3 to take advantage of QOM

2012-07-18 Thread Wanpeng Li
in the device model. This lets you set properties of the parent and its children. realize() (which is still called DeviceState::init today) will be called right before the guest starts up for the first time. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw

[Qemu-devel] [PATCH v4 5/5] merge pc_piix.c to pc.c

2012-07-18 Thread Wanpeng Li
[CCing ML] From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/i386/Makefile.objs |1 - hw/pc.c | 753 +++-- hw/pc.h

Re: [Qemu-devel] [PATCH v4 4/5] prepare to create HPET, RTC and i8254 through composition

2012-07-19 Thread Wanpeng Li
On Thu, Jul 19, 2012 at 03:23:32PM -0500, Anthony Liguori wrote: Wanpeng Li liw...@linux.vnet.ibm.com writes: [CCing ML] From: Anthony Liguori aligu...@us.ibm.com Each of these devices should be a separate patch. Please don't just send patches from branches of mine. Spend some time

[Qemu-devel] [PATCH v5 0/3] refactor PC machine, i440fx and piix3 to take advantage of QOM

2012-07-23 Thread Wanpeng Li
::init today) will be called right before the guest starts up for the first time. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com Change in v5: * drop patch convert MemoryRegion to QOM and prepare to create HPET, RTC and i8254 through composition

[Qemu-devel] [PATCH v5 3/3] convert pci-host to QOM

2012-07-23 Thread Wanpeng Li
From: Anthony Liguori aligu...@us.ibm.com makes pci_host a proper QOM type. Changelog: * against Andreas pci_host branch * make host bridge TypeInfos const * use PCI_HOST_BRIDGE() where appropriate Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw

[Qemu-devel] [PATCH v5 2/3] merge pc_piix.c to pc.c

2012-07-23 Thread Wanpeng Li
From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/i386/Makefile.objs |1 - hw/pc.c | 695 + hw/pc.h | 46

[Qemu-devel] [PATCH v5 1/3] eliminate piix_pci.c and module i440fx and piix3

2012-07-23 Thread Wanpeng Li
the fact that the PMC is contained within the i440fx which we will now reflect in composition in the next few changesets. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/i386/Makefile.objs |2 +- hw/i440fx.c | 434

Re: [Qemu-devel] [PATCH v5 3/3] convert pci-host to QOM

2012-07-23 Thread Wanpeng Li
On Mon, Jul 23, 2012 at 02:57:20PM +0200, Andreas Färber wrote: Am 23.07.2012 14:35, schrieb Wanpeng Li: From: Anthony Liguori aligu...@us.ibm.com makes pci_host a proper QOM type. Changelog: * against Andreas pci_host branch * make host bridge TypeInfos const * use PCI_HOST_BRIDGE

[Qemu-devel] [PATCH 2/6] convert MemoryRegion to QOM

2012-03-25 Thread Wanpeng Li
From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- memory.c | 94 ++ memory.h |8 + 2 files changed, 78 insertions(+), 24

[Qemu-devel] [PATCH 4/6] prepare to create HPET, RTC and i8254 through composition

2012-03-25 Thread Wanpeng Li
it in the PIIX is rational. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/hpet.c | 39 ++- hw/hpet_emul.h | 41 + hw/i8254_internal.h |2 +- hw

[Qemu-devel] [PATCH 3/6] convert pci-host to QOM

2012-03-25 Thread Wanpeng Li
From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pci_host.c | 26 ++ hw/pci_host.h |5 + 2 files changed, 31 insertions(+), 0 deletions(-) diff --git a/hw

[Qemu-devel] [PATCH 0/6] refactor PC machine, i440fx and piix3 to take advantage of QOM

2012-03-25 Thread Wanpeng Li
-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- Makefile.target |3 +- hw/hpet.c | 39 +--- hw/hpet_emul.h | 41 +++ hw/i440fx.c | 431 ++ hw/i440fx.h | 78 + hw/i8254_internal.h |2 +- hw/mc146818rtc.c| 26 -- hw

[Qemu-devel] [PATCH 6/6] make some functions static

2012-03-25 Thread Wanpeng Li
From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pc.c | 22 +++--- hw/pc.h | 26 -- 2 files changed, 11 insertions(+), 37 deletions(-) diff --git

[Qemu-devel] [PATCH 5/6] merge pc_piix.c to pc.c

2012-03-25 Thread Wanpeng Li
From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- Makefile.target |1 - hw/pc.c | 816 +-- hw/pc.h | 20 +- hw/pc_piix.c

[Qemu-devel] [PATCH 1/6] eliminate piix_pci.c and module i440fx and piix3

2012-03-25 Thread Wanpeng Li
that the PMC is contained within the i440fx which we will now reflect in composition in the next few changesets. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- Makefile.target |2 +- hw/i440fx.c | 431

[Qemu-devel] [PATCH 3/6] convert pci-host to QOM

2012-03-26 Thread Wanpeng Li
From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pci_host.c | 26 ++ hw/pci_host.h |5 + 2 files changed, 31 insertions(+), 0 deletions(-) diff --git a/hw

Re: [Qemu-devel] [PATCH 3/6] convert pci-host to QOM

2012-03-26 Thread Wanpeng Li
On Mon, Mar 26, 2012 at 10:06:45AM +0800, Wanpeng Li wrote: From: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pci_host.c | 26 ++ hw/pci_host.h |5 + 2 files

Re: [Qemu-devel] [PATCH 0/6] refactor PC machine, i440fx and piix3 to take advantage of QOM

2012-03-26 Thread Wanpeng Li
On Mon, Mar 26, 2012 at 02:47:19PM +0200, Andreas Färber wrote: Am 26.03.2012 04:06, schrieb Wanpeng Li: From: Anthony Liguori aligu...@us.ibm.com Resending an old cover letter is not a good idea. This looks like a v2, so please mark it as such in the subjects; it's missing a Change Log against

[Qemu-devel] RFC: options parsing in vl.c should be module

2012-03-30 Thread Wanpeng Li
Hi all: Consider of the options parsing process in main function of vl.c is too long. It should be module into single function to clear Ideas, strengthen the source code management, and increase code readability. Regards, Wanpeng Li -- LTC China, IBM, Shanghai

[Qemu-devel] script

2012-03-30 Thread Wanpeng Li
Hi all: Are there any materials introduce how to use the scripts under scripts/ ? Regards, Wanpeng Li -- LTC China, IBM, Shanghai

Re: [Qemu-devel] script

2012-03-30 Thread Wanpeng Li
On Fri, Mar 30, 2012 at 11:28:53AM +0200, Andreas Färber wrote: Am 30.03.2012 09:11, schrieb Wanpeng Li: Are there any materials introduce how to use the scripts under scripts/ ? Is this a general question about improving our scripts' documentation, or are you asking about one or more specific

[Qemu-devel] [PATCH] RFC: options parse in vl.c should be moduled

2012-03-30 Thread Wanpeng Li
in order to not influence command-line invocations. Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- vl.c | 159 ++--- 1 files changed, 83 insertions(+), 76 deletions(-) diff --git a/vl.c b/vl.c index 0fccf50..fa4d0a9 100644

Re: [Qemu-devel] [PATCH] RFC: options parse in vl.c should be moduled

2012-03-30 Thread Wanpeng Li
On Fri, Mar 30, 2012 at 01:53:14PM +0100, Daniel P. Berrange wrote: On Fri, Mar 30, 2012 at 08:36:43PM +0800, Wanpeng Li wrote: Consider of the options parse process in main function of vl.c is too long.It should be module into single function to clear ideas, strengthen the source code

[Qemu-devel] [PATCH] remove useless comments in dma

2012-04-06 Thread Wanpeng Li
This comment is useless, just removes it and makes the codes clear. Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- dma.h |1 - 1 files changed, 0 insertions(+), 1 deletions(-) diff --git a/dma.h b/dma.h index 20e86d2..5bd1fc8 100644 --- a/dma.h +++ b/dma.h @@ -11,7 +11,6 @@ #define

[Qemu-devel] [PATCH] PCI Using macro definition instead of a simple digit

2012-03-03 Thread Wanpeng Li
PCI_CLASS_DISPLAY_VGA has already defined in hw/pci_ids.h, so use the macro definition instead of a simple digit. Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pci.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index fe71666..274d86d

[Qemu-devel] [PATCH] PCI Using macro definition instead of a simple digit

2012-03-03 Thread Wanpeng Li
PCI_CLASS_DISPLAY_VGA has already defined in hw/pci_ids.h, so use the macro definition instead of a simple digit. Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pci.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/hw/pci.c b/hw/pci.c index fe71666..274d86d

[Qemu-devel] questions about pci

2012-03-04 Thread WanPeng Li
ioport write/read, I have traced this function, but I haven't found it has any relationship with pci read/write configuration space functions like i440fx_write_config and piix3_write_config.So how does it emulate pci configuration space access when not use passthrough? thanks Wanpeng Li LTC China

[Qemu-devel] [PATCH] fix bug of isa_bus irq

2012-03-10 Thread Wanpeng Li
ISA bus only use IRQ 0~15, so don't need to give an array qemu_irq 0~24, just array qemu_irq i8259 is ok. Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pc_piix.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/hw/pc_piix.c b/hw/pc_piix.c index 63dba4e

[Qemu-devel] [PATCH] fix bug of isa_bus irq

2012-03-10 Thread Wanpeng Li
ISA bus only use IRQ 0~15, so don't need to give an array qemu_irq 0~23, just array qemu_irq i8259 is ok. Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pc_piix.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/hw/pc_piix.c b/hw/pc_piix.c index 63dba4e

Re: [Qemu-devel] [PATCH] fix bug of isa_bus irq

2012-03-12 Thread Wanpeng Li
On Sun, Mar 11, 2012 at 08:46:38AM +0100, Jan Kiszka wrote: On 2012-03-11 08:04, Wanpeng Li wrote: ISA bus only use IRQ 0~15, so don't need to give an array qemu_irq 0~23, just array qemu_irq i8259 is ok. Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/pc_piix.c |3 ++- 1

[Qemu-devel] main-system-bus

2012-03-13 Thread Wanpeng Li
Hi all: I am confused with what's the meaning of main-system-bus, it emulates physical bus like FSB(front side bus) or just a virtual bus as the root of device tree. Regards, Wanpeng Li

Re: [Qemu-devel] [PATCH] remove useless comments in dma

2012-04-08 Thread Wanpeng Li
On Sat, Apr 07, 2012 at 02:23:43PM +, Blue Swirl wrote: On Fri, Apr 6, 2012 at 07:52, Wanpeng Li l...@linux.vnet.ibm.com wrote: This comment is useless, just removes it and makes the codes clear. Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com Thanks, applied. Patches like these could

[Qemu-devel] relationship between vmport vmmouse i8042 port92

2012-04-08 Thread Wanpeng Li
Hi all: I know i8042 is a chip in southbridge which control keyboard and mouse. Keboard is emulated by i8042 in qemu and mouse is emulated by vmmouse. But what are port92 and vmport, what's the relationship among these four stuff ? Regards, Wanpeng Li -- LTC China, IBM, Shanghai

[Qemu-devel] [PATCH] avoid repeating contain header file

2012-04-09 Thread Wanpeng Li
Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/ps2.h | 29 + 1 files changed, 29 insertions(+), 0 deletions(-) diff --git a/hw/ps2.h b/hw/ps2.h index 32a4231..d19c226 100644 --- a/hw/ps2.h +++ b/hw/ps2.h @@ -1,3 +1,30 @@ +/* + * QEMU PS/2 keyboard/mouse

[Qemu-devel] [PATCH] avoid repeating contain header file

2012-04-10 Thread Wanpeng Li
Signed-off-by: Wanpeng Li l...@linux.vnet.ibm.com --- hw/ps2.h | 29 + 1 files changed, 29 insertions(+), 0 deletions(-) diff --git a/hw/ps2.h b/hw/ps2.h index 32a4231..d19c226 100644 --- a/hw/ps2.h +++ b/hw/ps2.h @@ -1,3 +1,30 @@ +/* + * QEMU PS/2 keyboard/mouse

[Qemu-devel] [PATCH v5 0/3] refactor PC machine, i440fx and piix3 to take advantage of QOM

2012-11-07 Thread Wanpeng Li
This series aggressively refactors the PC machine initialization to be more modelled and less ad-hoc. The highlights of this series are: 1) Things like -m and -bios-name are now device model properties 2) The i440fx and piix3 are now modelled in a thorough fashion 3) i440fx_init is trivialized

[Qemu-devel] [PATCH v5 3/3] convert pci-host to QOM

2012-11-07 Thread Wanpeng Li
Take advantage of Andreas's pci-host patchset, add instance_init function to fully implement convert pci-host to QOM. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/pci_host.c |9 + 1 files changed, 9 insertions(+), 0

[Qemu-devel] [PATCH 01/10] convert RTC as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert RTC as piix3 proper QOM child. RTC creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw

[Qemu-devel] [PATCH 04/10] convert PCSPK as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert PCSPK as piix3 proper QOM child. PCSPK creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/pcspk.c | 19 +-- hw/pcspk.h

[Qemu-devel] [PATCH 06/10] convert i8042 as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert i8042 as piix3 proper QOM child. I8042 creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/pc.c|9 ++--- hw/pckbd.c | 24

[Qemu-devel] [PATCH 07/10] convert VMPORT as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert VMPORT as piix3 proper QOM child. VMPORT creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/pc.c |1 - hw/pc.h |5 - hw

[Qemu-devel] [PATCH 08/10] convert VMMOUSE as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert VMMOUSE as piix3 proper QOM child. VMMOUSE creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/pc.c | 15 ++- hw/piix3.c

[Qemu-devel] [PATCH 10/10] convert IOAPIC as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert IOAPIC as piix3 proper QOM child. IOAPIC creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/ioapic.c |2 +- hw/ioapic.h

[Qemu-devel] [PATCH v5 2/3] merge pc_piix.c to pc.c

2012-11-07 Thread Wanpeng Li
things worse. Making things proper objects and using composition is the right way to share common devices. By pulling these files back together, we can start to fix some of this mess. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/i386

[Qemu-devel] [PATCH 02/10] convert HPET as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert HPET as piix3 proper QOM child. HPET creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw

[Qemu-devel] [PATCH 05/10] convert PORT92 as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert PORT92 as piix3 proper QOM child. PORT92 creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/pc.c| 25 - hw

[Qemu-devel] [PATCH 00/10] piix3: create all child devices as proper QOM children

2012-11-07 Thread Wanpeng Li
child device in the PIIX3 ::init function. Anthony Liguori (3): convert RTC as piix3 proper QOM child convert HPET as piix3 proper QOM child convert PIT as piix3 proper QOM child Wanpeng Li (7): convert PCSPK as piix3 proper QOM child convert PORT92 as piix3 proper QOM child convert I8042

[Qemu-devel] [PATCH 03/10] convert PIT as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert PIT as piix3 proper QOM child. PIT creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Anthony Liguori aligu...@us.ibm.com Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw

[Qemu-devel] [PATCH 09/10] convert IDE as piix3 proper QOM child

2012-11-07 Thread Wanpeng Li
convert IDE as piix3 proper QOM child. IDE creation for the PIIX3 is done by calling object_init() with qdev_init() being called for each child device in the PIIX3 ::init function. Signed-off-by: Wanpeng Li liw...@linux.vnet.ibm.com --- hw/i440fx.c |6 ++ hw/ide.h |6

Re: [Qemu-devel] [PATCH v5 0/3] refactor PC machine, i440fx and piix3 to take advantage of QOM

2012-11-14 Thread Wanpeng Li
On Thu, Nov 08, 2012 at 01:36:09PM +0800, Wanpeng Li wrote: This series aggressively refactors the PC machine initialization to be more modelled and less ad-hoc. The highlights of this series are: 1) Things like -m and -bios-name are now device model properties 2) The i440fx and piix3 are now

Re: [Qemu-devel] QEMU NUMA and memory allocation problem

2013-05-19 Thread Wanpeng Li
, Wanpeng Li Thanks, Wanlong Gao Hi, We just met a problem of QEMU memory allocation. Here is the description: On my host, I have two nodes, # numactl -H available: 2 nodes (0-1) node 0 cpus: 0 2 node 0 size: 4010 MB node 0 free: 3021 MB node 1 cpus: 1 3 node 1 size: 4030 MB node 1

Re: [Qemu-devel] [question] Is there a plan to introduce a unified co-scheduling mechanism to CFS ?

2014-10-10 Thread Wanpeng Li
desired when several cooperating threads/task is running in guest. Is there a plane for this work? Please refer to gang scheduler. Regards, Wanpeng Li Thanks, Zhang Haoyu -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a message to majord...@vger.kernel.org More

[Qemu-devel] [PATCH] target-i386: Intel xsaves

2014-12-02 Thread Wanpeng Li
Add xsaves related definition, it also add corresponding part to kvm_get/put, and vmstate. Signed-off-by: Wanpeng Li wanpeng...@linux.intel.com --- target-i386/cpu.h | 2 ++ target-i386/kvm.c | 15 +++ target-i386/machine.c | 3 ++- 3 files changed, 19 insertions(+), 1

[Qemu-devel] [PATCH v2] target-i386: Intel xsaves

2014-12-02 Thread Wanpeng Li
Add xsaves related definition, it also adds corresponding part to kvm_get/put, and vmstate. Signed-off-by: Wanpeng Li wanpeng...@linux.intel.com --- v1 - v2: * use a subsection instead of bumping the version number. target-i386/cpu.h | 2 ++ target-i386/kvm.c | 15

[Qemu-devel] [PATCH RESCEND v2] target-i386: Intel xsaves

2014-12-02 Thread Wanpeng Li
Add xsaves related definition, it also adds corresponding part to kvm_get/put, and vmstate. Signed-off-by: Wanpeng Li wanpeng...@linux.intel.com --- v1 - v2: * use a subsection instead of bumping the version number. target-i386/cpu.h | 2 ++ target-i386/kvm.c | 15

Re: [Qemu-devel] [PATCH v5] i386: Introduce ARAT CPU feature

2015-06-23 Thread Wanpeng Li
to stopping of the timer in certain power states (which we do not even emulate IIRC). In that case, the OS is under risk of sleeping forever, thus need to look for a different wakeup source. HPET will always be the default broadcast event device I think. Regards, Wanpeng Li Live-migration or VM pausing

Re: [Qemu-devel] [PATCH 7/12] kvm/x86: added hyper-v crash data and ctl msr's get/set'ers

2015-08-18 Thread Wanpeng Li
the KVM_CAP_HYPERV_MSR_CRASH in this patchset. :( Regards, Wanpeng Li

Re: [Qemu-devel] [PATCH v1 0/7] KVM: Hyper-V SynIC timers

2015-11-25 Thread Wanpeng Li
format message > to the configured SynIC message slot and triggering the corresponding > synthetic interrupt. Could you post a link for this specification? Regards, Wanpeng Li

Re: [Qemu-devel] [PATCH v1 0/7] KVM: Hyper-V SynIC timers

2015-12-01 Thread Wanpeng Li
2015-11-26 16:34 GMT+08:00 Andrey Smetanin <asmeta...@virtuozzo.com>: > > > On 11/26/2015 08:28 AM, Wanpeng Li wrote: >> >> 2015-11-25 23:20 GMT+08:00 Andrey Smetanin <asmeta...@virtuozzo.com>: >>> >>> Per Hyper-V specification (and as required

Re: [Qemu-devel] [PATCH v1 0/7] KVM: Hyper-V SynIC timers

2015-11-26 Thread Wanpeng Li
2015-11-26 16:34 GMT+08:00 Andrey Smetanin <asmeta...@virtuozzo.com>: > > > On 11/26/2015 08:28 AM, Wanpeng Li wrote: >> >> 2015-11-25 23:20 GMT+08:00 Andrey Smetanin <asmeta...@virtuozzo.com>: >>> >>> Per Hyper-V specification (and as required

Re: [Qemu-devel] [QEMU PATCH v2] kvmclock: advance clock by time window between vm_stop and pre_save

2017-02-07 Thread Wanpeng Li
ers dont? > > If you are correlating the clocks, then yes. > > Older Linux guests get upset (marking the TSC clocksource unstable > because the watchdog checks TSC vs kvmclock), but there is a workaround for it > in newer guests > (kvmclock interface to notify watchdog to not compl

Re: [Qemu-devel] [PATCH v3 kernel 0/7] Extend virtio-balloon for fast (de)inflating & fast live migration

2016-08-31 Thread Wanpeng Li
feature will increase downtime when acquire the benefit of reducing total time, maybe it will be more acceptable if there is no downside for downtime. Regards, Wanpeng Li

Re: [Qemu-devel] [PATCH v3 kernel 0/7] Extend virtio-balloon for fast (de)inflating & fast live migration

2016-09-01 Thread Wanpeng Li
migration downtime to avoid customers' >> perception than total time, however, this feature will increase downtime >> when acquire the benefit of reducing total time, maybe it will be more >> acceptable if there is no downside for downtime. >> >> Regards, >> Wanpeng Li

[Qemu-devel] [PATCH] pc: apic: introduce APIC macro

2016-09-14 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> Introduce a new APIC macro to replace APIC_COMMON macro in hw/intc/apic.c in order to capture access LAPIC in qemu even if LAPIC is emulated in kvm. Suggested-by: Paolo Bonzini <pbonz...@redhat.com> Cc: Paolo Bonzini <pbonz...@redhat

[Qemu-devel] [PATCH] pc: apic: fix touch LAPIC when irqchip is split

2016-09-13 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> Add -kernel_irqchip=split ./x86-run x86/eventinj.flat qemu-system-x86_64 -enable-kvm -machine kernel_irqchip=split -cpu host -device pc-testdev -device isa-debug-exit,iobase=0xf4,iosize=0x4 -vnc none -serial stdio -device pci-testdev -kern

Re: [Qemu-devel] [PATCH] pc: apic: fix touch LAPIC when irqchip is split

2016-09-13 Thread Wanpeng Li
: pc: apic: fix touch LAPIC when irqchip is split... >> ERROR: suspect code indent for conditional statements (4, 9) >> #90: FILE: hw/i386/pc.c:164: >> +if (!kvm_irqchip_in_kernel()) { >> + intno = apic_get_interrupt(cpu->apic_state); > ^ > Should be 4 spaces here. > >> >> ERROR: suspect code indent for conditional statements (9, 13) >> #92: FILE: hw/i386/pc.c:166: >> + if (intno >= 0) { >> + return intno; > > Then this and later will be indented back by 1 column. You are right, thanks Fam. Regards, Wanpeng Li

[Qemu-devel] [PATCH v2] pc: apic: fix touch LAPIC when irqchip is split

2016-09-13 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> Add -kernel_irqchip=split ./x86-run x86/eventinj.flat qemu-system-x86_64 -enable-kvm -machine kernel_irqchip=split -cpu host -device pc-testdev -device isa-debug-exit,iobase=0xf4,iosize=0x4 -vnc none -serial stdio -device pci-testdev -kern

Re: [Qemu-devel] [PATCH] pc: apic: introduce APIC macro

2016-09-15 Thread Wanpeng Li
gt; "apic" in apic.c by TYPE_APIC. Will do, thanks for your review. Regards, Wanpeng Li

[Qemu-devel] [PATCH v2] pc: apic: introduce APIC macro

2016-09-15 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> Introduce a new APIC macro to replace APIC_COMMON macro in hw/intc/apic.c in order to capture access LAPIC in qemu even if LAPIC is emulated in kvm. Suggested-by: Paolo Bonzini <pbonz...@redhat.com> Reviewed-by: Michael S. Tsirkin <m...

[Qemu-devel] [PATCH] hmp: fix qemu crash due to ioapic state dump w/ split irqchip

2016-09-22 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> The qemu will crash when info ioapic through hmp if irqchip is split. Below message is splat: KVM_GET_IRQCHIP failed: Unknown error -6 This patch fix it by dumping the ioapic state from the qemu emulated ioapic if irqchip is split. Cc: Paolo B

[Qemu-devel] [PATCH] target-i386: fix losing XCR0 processor state component bits

2016-09-27 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> Commit 96193c22a "target-i386: Move xsave component mask to features array" leverages features array to handle XCR0 processor state component bits, however, it introduces a regression: warning: host doesn't support requested feature: CP

[Qemu-devel] [PATCH v2] target-i386: fix losing XCR0 processor state component bits

2016-09-28 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> Commit 96193c22a "target-i386: Move xsave component mask to features array" leverages features array to handle XCR0 processor state component bits, however, it introduces a regression: warning: host doesn't support requested feature: CP

Re: [Qemu-devel] [PATCH] target-i386: fix losing XCR0 processor state component bits

2016-09-28 Thread Wanpeng Li
2016-09-28 15:54 GMT+08:00 Paolo Bonzini <bonz...@gnu.org>: [...] > I think the right place to add the test is x86_cpu_get_migratable_flags. I just sent out v2 to handle this, thanks for pointing out. Regards, Wanpeng Li

Re: [Qemu-devel] [PATCH] target-i386: Report known CPUID[EAX=0xD, ECX=0]:EAX bits as migratable

2016-09-29 Thread Wanpeng Li
features by >> default. >> >> This adds a new field to FeatureWordInfo: migratable_flags, which >> will make those features be reported as migratable even if they >> don't have a property name defined. >> >> Reported-by: Wanpeng Li <wanpeng...@hotmail.com> >>

Re: [Qemu-devel] [PATCH v2] target-i386: fix losing XCR0 processor state component bits

2016-09-28 Thread Wanpeng Li
2016-09-29 1:05 GMT+08:00 Eduardo Habkost <ehabk...@redhat.com>: > On Wed, Sep 28, 2016 at 04:36:14PM +0800, Wanpeng Li wrote: [...] > > We still need to report unknown xstate components as unmigratable > (otherwise -cpu host will enable them automatically). See the fix > I

Re: [Qemu-devel] [PATCH] target-i386 : fix a race condition result to lost INIT

2017-07-30 Thread Wanpeng Li
. Why we touch INIT pending if INIT is not latched in SMM? Regards, Wanpeng Li > > Signed-off-by: Peng Hao <peng.h...@zte.com.cn> > --- > target/i386/kvm.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/target/i386/kvm.c b/target/i386/kvm.c

Re: [Qemu-devel] [PATCH v3] target-i386/cpu: Add new EPYC CPU model

2017-08-16 Thread Wanpeng Li
ed in kvm/qemu? Regards, Wanpeng Li > > Removed: xop, fma4, tbm > > Cc: Paolo Bonzini <pbonz...@redhat.com> > Cc: Richard Henderson <r...@twiddle.net> > Cc: Eduardo Habkost <ehabk...@redhat.com> > Cc: Tom Lendacky <thomas.lenda...@amd.com> > Signed-

[Qemu-devel] [PATCH v3] KVM: Add async pf flag to KVM_GET/SET_VCPU_EVENTS interface

2017-06-28 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> This patch adds async page fault flag to KVM_GET/SET_VCPU_EVENTS interface. Cc: Paolo Bonzini <pbonz...@redhat.com> Cc: Radim Krčmář <rkrc...@redhat.com> Signed-off-by: Wanpeng Li <wanpeng...@hotmail.com> --- v2 -> v3: * ne

Re: [Qemu-devel] About QEMU BQL and dirty log switch in Migration

2017-05-12 Thread Wanpeng Li
2017-05-11 22:18 GMT+08:00 Zhoujian (jay) <jianjay.z...@huawei.com>: > Hi Wanpeng, > >> 2017-05-11 21:43 GMT+08:00 Wanpeng Li <kernel...@gmail.com>: >> > 2017-05-11 20:24 GMT+08:00 Paolo Bonzini <pbonz...@redhat.com>: >> >> &g

Re: [Qemu-devel] About QEMU BQL and dirty log switch in Migration

2017-05-11 Thread Wanpeng Li
ld->flags & KVM_MEM_LOG_DIRTY_PAGES) && >> - !(new->flags & KVM_MEM_LOG_DIRTY_PAGES)) >> - kvm_mmu_zap_collapsible_sptes(kvm, new); This is an unlikely branch(unless guest live migration fails and continue to run on the source machi

Re: [Qemu-devel] About QEMU BQL and dirty log switch in Migration

2017-05-11 Thread Wanpeng Li
2017-05-11 21:43 GMT+08:00 Wanpeng Li <kernel...@gmail.com>: > 2017-05-11 20:24 GMT+08:00 Paolo Bonzini <pbonz...@redhat.com>: >> >> >> On 11/05/2017 14:07, Zhoujian (jay) wrote: >>> -* Scan sptes if dirty logging has been stopped, dropping t

Re: [Qemu-devel] About QEMU BQL and dirty log switch in Migration

2017-05-16 Thread Wanpeng Li
misses #9.52% of all iTLB > cache hits (16.67%) > 1,152,784 iTLB-loads > (33.32%) > > 10.000703078 seconds time elapsed > ** Could you comment out the original "lazy collapse small spte

Re: [Qemu-devel] About QEMU BQL and dirty log switch in Migration

2017-05-17 Thread Wanpeng Li
ll drop during live migration, it will keep a small value if live migration fails and w/o "lazy collapse small sptes into large sptes" codes, however, it will increase gradually if w/ the "lazy collapse small sptes into large sptes" codes. Regards, Wanpeng Li

[Qemu-devel] [PATCH] KVM: Add async pf flag to KVM_GET/SET_VCPU_EVENTS interface

2017-06-20 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> This patch adds async pf flag to KVM_GET/SET_VCPU_EVENTS interface. Signed-off-by: Wanpeng Li <wanpeng...@hotmail.com> --- linux-headers/asm-x86/kvm.h | 2 ++ target/i386/cpu.h | 1 + target/i386/kvm.c | 6 +- 3 file

Re: [Qemu-devel] [PATCH] KVM: Add async pf flag to KVM_GET/SET_VCPU_EVENTS interface

2017-06-21 Thread Wanpeng Li
2017-06-22 0:28 GMT+08:00 Radim Krčmář <rkrc...@redhat.com>: > 2017-06-20 20:14-0700, Wanpeng Li: >> From: Wanpeng Li <wanpeng...@hotmail.com> >> >> This patch adds async pf flag to KVM_GET/SET_VCPU_EVENTS interface. >> >> Signed-off-by: Wanpeng Li

[Qemu-devel] [PATCH v2] KVM: Add async pf flag to KVM_GET/SET_VCPU_EVENTS interface

2017-06-21 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> This patch adds async page fault flag to KVM_GET/SET_VCPU_EVENTS interface. Cc: Paolo Bonzini <pbonz...@redhat.com> Cc: Radim Krčmář <rkrc...@redhat.com> Signed-off-by: Wanpeng Li <wanpeng...@hotmail.com> --- v1

[Qemu-devel] qemu core file size

2017-11-06 Thread Wanpeng Li
Hi all, qemu core dump, max_core="unlimited", dump_guest_core=0, kill -11 pid to generate a qemu core file, the Rss of qemu itself is ~40MB, the core file is almost ~40MB in centos 6.x, but ~400MB in cents 7.x, any idea? Regards, Wanpeng Li

Re: [Qemu-devel] qemu core file size

2017-11-06 Thread Wanpeng Li
ely are not in the RSS. Do you mean not use Memory API will avoid the fragmented heap? Regards, Wanpeng Li

Re: [Qemu-devel] qemu core file size

2017-11-06 Thread Wanpeng Li
2017-11-06 17:41 GMT+08:00 Paolo Bonzini <pbonz...@redhat.com>: > On 06/11/2017 10:11, Wanpeng Li wrote: >> Hi all, >> >> qemu core dump, max_core="unlimited", dump_guest_core=0, kill -11 pid >> to generate a qemu core file, the Rss of qemu itself

Re: [Qemu-devel] qemu core file size

2017-11-06 Thread Wanpeng Li
Hi Alexey, 2017-11-07 13:46 GMT+08:00 Alexey Kardashevskiy <a...@ozlabs.ru>: > On 07/11/17 01:08, Paolo Bonzini wrote: >> On 06/11/2017 13:18, Wanpeng Li wrote: >>> 2017-11-06 20:02 GMT+08:00 Paolo Bonzini <pbonz...@redhat.com>: >>>> On 06/11/2017 12:59

Re: [Qemu-devel] qemu core file size

2017-11-06 Thread Wanpeng Li
2017-11-07 14:12 GMT+08:00 Alexey Kardashevskiy <a...@ozlabs.ru>: > On 07/11/17 17:02, Wanpeng Li wrote: >> Hi Alexey, >> 2017-11-07 13:46 GMT+08:00 Alexey Kardashevskiy <a...@ozlabs.ru>: >>> On 07/11/17 01:08, Paolo Bonzini wrote: >>>> On 06/11/2017

[Qemu-devel] [PATCH] target-i386: adds PV_TLB_FLUSH CPUID feature bit

2017-11-09 Thread Wanpeng Li
From: Wanpeng Li <wanpeng...@hotmail.com> Adds PV_TLB_FLUSH CPUID feature bit. Cc: Paolo Bonzini <pbonz...@redhat.com> Cc: Radim Krčmář <rkrc...@redhat.com> Cc: Richard Henderson <r...@twiddle.net> Cc: Eduardo Habkost <ehabk...@redhat.com> Signed-off-by: Wanp

  1   2   >