Re: [RFC PATCH v2 03/21][SeaBIOS] acpi-dsdt: Implement functions for memory hotplug

2012-07-17 Thread Wen Congyang
At 07/11/2012 06:31 PM, Vasilis Liaskovitis Wrote: Extend the DSDT to include methods for handling memory hot-add and hot-remove notifications and memory device status requests. These functions are called from the memory device SSDT methods. Signed-off-by: Vasilis Liaskovitis

Re: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Alexander Graf
On 17.07.2012, at 03:02, Scott Wood scottw...@freescale.com wrote: On 07/16/2012 12:18 PM, Alexander Graf wrote: +/* + * Return the number of jiffies until the next timeout. If the timeout is + * longer than the NEXT_TIMER_MAX_DELTA, that then? return NEXT_TIMER_MAX_DELTA + *

Re: [PATCH RFC V4 2/3] kvm: Note down when cpu relax intercepted or pause loop exited

2012-07-17 Thread Avi Kivity
On 07/16/2012 08:24 PM, Raghavendra K T wrote: So are you saying allow vcpu to spin in non over-commit scenarios? So that we avoid all yield_to etc... ( Or even in some other place where it is useful). When is yielding useful, if you're not overcommitted? -- error compiling committee.c:

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Asias He
On 07/16/2012 07:58 PM, Stefan Hajnoczi wrote: On Thu, Jul 12, 2012 at 4:35 PM, Asias He as...@redhat.com wrote: This patchset adds vhost-blk support. vhost-blk is a in kernel virito-blk device accelerator. Compared to userspace virtio-blk implementation, vhost-blk gives about 5% to 15%

Re: [PATCH RFC V4 3/3] kvm: Choose better candidate for directed yield

2012-07-17 Thread Avi Kivity
On 07/16/2012 07:10 PM, Rik van Riel wrote: On 07/16/2012 06:07 AM, Avi Kivity wrote: +{ +bool eligible; + +eligible = !vcpu-ple.cpu_relax_intercepted || +(vcpu-ple.cpu_relax_intercepted + vcpu-ple.dy_eligible); + +if (vcpu-ple.cpu_relax_intercepted)

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Paolo Bonzini
Il 17/07/2012 10:29, Asias He ha scritto: So, vhost-blk at least saves ~6 syscalls for us in each request. Are they really 6? If I/O is coalesced by a factor of 3, for example (i.e. each exit processes 3 requests), it's really 2 syscalls per request. Also, is there anything we can improve?

Re: [PATCH RFC V4 3/3] kvm: Choose better candidate for directed yield

2012-07-17 Thread Raghavendra K T
On 07/17/2012 01:59 PM, Avi Kivity wrote: On 07/16/2012 07:10 PM, Rik van Riel wrote: On 07/16/2012 06:07 AM, Avi Kivity wrote: +{ +bool eligible; + +eligible = !vcpu-ple.cpu_relax_intercepted || +(vcpu-ple.cpu_relax_intercepted + vcpu-ple.dy_eligible); + +

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Asias He
On 07/17/2012 04:52 PM, Paolo Bonzini wrote: Il 17/07/2012 10:29, Asias He ha scritto: So, vhost-blk at least saves ~6 syscalls for us in each request. Are they really 6? If I/O is coalesced by a factor of 3, for example (i.e. each exit processes 3 requests), it's really 2 syscalls per

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Paolo Bonzini
Il 17/07/2012 11:21, Asias He ha scritto: It depends. Like vhost-scsi, vhost-blk has the problem of a crippled feature set: no support for block device formats, non-raw protocols, etc. This makes it different from vhost-net. Data-plane qemu also has this cripppled feature set problem, no?

Re: [RFC/PATCH] Use kernel supplied MMU info for kvm tool

2012-07-17 Thread Matt Evans
Hi Michael, On 2012-07-17 06:00, Michael Ellerman wrote: This is a series for kvmtool that uses a newish kernel API to get MMU info, which is then fed to the guest. Currently we just make a good guess based on the PVR, but that is potentially flakey in a few ways. The most notable is that if

Re: qemu fails to build with glibc-2.15

2012-07-17 Thread X O
On Mon, Jul 16, 2012 at 6:35 PM, X O bex...@gmail.com wrote: On Mon, Jul 16, 2012 at 5:14 PM, Avi Kivity a...@redhat.com wrote: (fixed mailing list) On 07/16/2012 03:37 PM, X O wrote: [...] Is there a way to compile qemu with glibc-2.15? [...] ~~~ CCi386-linux-user/syscall.o

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 10:52:10AM +0200, Paolo Bonzini wrote: Il 17/07/2012 10:29, Asias He ha scritto: So, vhost-blk at least saves ~6 syscalls for us in each request. Are they really 6? If I/O is coalesced by a factor of 3, for example (i.e. each exit processes 3 requests), it's really

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 11:32:45AM +0200, Paolo Bonzini wrote: Il 17/07/2012 11:21, Asias He ha scritto: It depends. Like vhost-scsi, vhost-blk has the problem of a crippled feature set: no support for block device formats, non-raw protocols, etc. This makes it different from vhost-net.

Re: [Qemu-devel] qemu fails to build with glibc-2.15

2012-07-17 Thread Peter Maydell
On 17 July 2012 10:38, X O bex...@gmail.com wrote: On Mon, Jul 16, 2012 at 6:35 PM, X O bex...@gmail.com wrote: On Mon, Jul 16, 2012 at 5:14 PM, Avi Kivity a...@redhat.com wrote: (fixed mailing list) On 07/16/2012 03:37 PM, X O wrote: [...] Is there a way to compile qemu with glibc-2.15?

RE: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Bhushan Bharat-R65777
-Original Message- From: kvm-ppc-ow...@vger.kernel.org [mailto:kvm-ppc-ow...@vger.kernel.org] On Behalf Of Alexander Graf Sent: Tuesday, July 17, 2012 12:50 PM To: Wood Scott-B07421 Cc: Bhushan Bharat-R65777; kvm-...@vger.kernel.org; kvm@vger.kernel.org; bharatb.ya...@gmail.com;

Re: [Qemu-devel] qemu fails to build with glibc-2.15

2012-07-17 Thread X O
On Tue, Jul 17, 2012 at 11:51 AM, Peter Maydell peter.mayd...@linaro.org wrote: On 17 July 2012 10:38, X O bex...@gmail.com wrote: On Mon, Jul 16, 2012 at 6:35 PM, X O bex...@gmail.com wrote: On Mon, Jul 16, 2012 at 5:14 PM, Avi Kivity a...@redhat.com wrote: (fixed mailing list) On

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Mon, Jul 16, 2012 at 02:34:03PM -0600, Alex Williamson wrote: This is an alternative to kvm_set_irq(,,,0) which returns the previous assertion state of the interrupt and does nothing if it isn't changed. Signed-off-by: Alex Williamson alex.william...@redhat.com ---

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Paolo Bonzini
Il 17/07/2012 11:45, Michael S. Tsirkin ha scritto: So it begs the question, is it going to be used in production, or just a useful reference tool? Sticking to raw already makes virtio-blk faster, doesn't it? In that vhost-blk looks to me like just another optimization option. Ideally I

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Mon, Jul 16, 2012 at 02:34:03PM -0600, Alex Williamson wrote: This is an alternative to kvm_set_irq(,,,0) which returns the previous assertion state of the interrupt and does nothing if it isn't changed. Signed-off-by: Alex Williamson alex.william...@redhat.com ---

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Michael S. Tsirkin
On Mon, Jul 16, 2012 at 02:33:55PM -0600, Alex Williamson wrote: + if (args-flags KVM_EOIFD_FLAG_LEVEL_IRQFD) { + struct _irqfd *irqfd = _irqfd_fdget_lock(kvm, args-irqfd); + if (IS_ERR(irqfd)) { + ret = PTR_ERR(irqfd); +

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 12:14:33PM +0200, Paolo Bonzini wrote: Il 17/07/2012 11:45, Michael S. Tsirkin ha scritto: So it begs the question, is it going to be used in production, or just a useful reference tool? Sticking to raw already makes virtio-blk faster, doesn't it? In that

RE: [PATCH v9 13/16] ARM: KVM: Emulation framework and CP15 emulation

2012-07-17 Thread Min-gyu Kim
Why does the cache operation need to happen on the same CPU while the L1 caches between cores are coherent? As you know, cache operations usually operate for a range and it iterates without disabling preemption. Therefore, though you enclose the vcpu_run and handle_exit with preemption

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Paolo Bonzini
Il 17/07/2012 12:49, Michael S. Tsirkin ha scritto: Ok, that would make more sense. One difference between vhost-blk and vhost-net is that for vhost-blk there are also management actions that would trigger the switch, for example a live snapshot. So a prerequisite for vhost-blk would be that

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 12:56:31PM +0200, Paolo Bonzini wrote: Il 17/07/2012 12:49, Michael S. Tsirkin ha scritto: Ok, that would make more sense. One difference between vhost-blk and vhost-net is that for vhost-blk there are also management actions that would trigger the switch, for

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Stefan Hajnoczi
On Tue, Jul 17, 2012 at 10:21 AM, Asias He as...@redhat.com wrote: On 07/17/2012 04:52 PM, Paolo Bonzini wrote: Il 17/07/2012 10:29, Asias He ha scritto: So, vhost-blk at least saves ~6 syscalls for us in each request. Are they really 6? If I/O is coalesced by a factor of 3, for example

Re: [Qemu-devel] [PATCH 2/5] scsi-disk: report resized disk via sense codes

2012-07-17 Thread Kevin Wolf
Am 16.07.2012 16:25, schrieb Paolo Bonzini: Linux will not use these, but a very similar mechanism will be used to report the condition via virtio-scsi events. Signed-off-by: Paolo Bonzini pbonz...@redhat.com --- hw/scsi-bus.c |5 + hw/scsi-disk.c | 15 +++

Re: [Qemu-devel] [PATCH 2/5] scsi-disk: report resized disk via sense codes

2012-07-17 Thread Paolo Bonzini
Il 17/07/2012 13:14, Kevin Wolf ha scritto: -if (s-features (1 SCSI_DISK_F_REMOVABLE)) { -bdrv_set_dev_ops(s-qdev.conf.bs, scsi_cd_block_ops, s); -} +bdrv_set_dev_ops(s-qdev.conf.bs, scsi_disk_block_ops, s); Are you aware of this code? bool

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 12:11:15PM +0100, Stefan Hajnoczi wrote: On Tue, Jul 17, 2012 at 10:21 AM, Asias He as...@redhat.com wrote: On 07/17/2012 04:52 PM, Paolo Bonzini wrote: Il 17/07/2012 10:29, Asias He ha scritto: So, vhost-blk at least saves ~6 syscalls for us in each request.

RE: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Bhushan Bharat-R65777
-Original Message- From: Wood Scott-B07421 Sent: Tuesday, July 17, 2012 6:32 AM To: Alexander Graf Cc: Bhushan Bharat-R65777; kvm-...@vger.kernel.org; kvm@vger.kernel.org; bharatb.ya...@gmail.com; Bhushan Bharat-R65777; Benjamin Herrenschmidt; Kumar Gala Subject: Re: [PATCH 2/2

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Stefan Hajnoczi
On Tue, Jul 17, 2012 at 9:29 AM, Asias He as...@redhat.com wrote: On 07/16/2012 07:58 PM, Stefan Hajnoczi wrote: Does the vhost-blk implementation do anything fundamentally different from userspace? Where is the overhead that userspace virtio-blk has? Currently, no. But we could play with

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Stefan Hajnoczi
On Tue, Jul 17, 2012 at 12:26 PM, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Jul 17, 2012 at 12:11:15PM +0100, Stefan Hajnoczi wrote: On Tue, Jul 17, 2012 at 10:21 AM, Asias He as...@redhat.com wrote: On 07/17/2012 04:52 PM, Paolo Bonzini wrote: Il 17/07/2012 10:29, Asias He ha

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Stefan Hajnoczi
On Tue, Jul 17, 2012 at 12:42 PM, Stefan Hajnoczi stefa...@gmail.com wrote: On Tue, Jul 17, 2012 at 12:26 PM, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Jul 17, 2012 at 12:11:15PM +0100, Stefan Hajnoczi wrote: On Tue, Jul 17, 2012 at 10:21 AM, Asias He as...@redhat.com wrote: On

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 12:42:13PM +0100, Stefan Hajnoczi wrote: On Tue, Jul 17, 2012 at 12:26 PM, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Jul 17, 2012 at 12:11:15PM +0100, Stefan Hajnoczi wrote: On Tue, Jul 17, 2012 at 10:21 AM, Asias He as...@redhat.com wrote: On 07/17/2012

Re: How to get the real device in guest os after attached a disk?

2012-07-17 Thread Stefan Hajnoczi
On Tue, Jul 17, 2012 at 4:40 AM, Wangpan hzwang...@corp.netease.com wrote: I have a question as the subject above, the reason I want to know this is that, if I attach some disks on the guest, for example, I specified /dev/vdc/dev/vdd(target device) at the cmd line by using 'virsh

[PATCH] KVM: PIC: call ack notifiers for irqs that are dropped form irr

2012-07-17 Thread Gleb Natapov
After commit 242ec97c358256 PIT interrupts are no longer delivered after PIC reset. It happens because PIT injects interrupt only if previous one was acked, but since on PIC reset it is dropped from irr it will never be delivered and hence acknowledged. Fix that by calling ack notifier on PIC

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Stefan Hajnoczi
On Tue, Jul 17, 2012 at 12:54 PM, Michael S. Tsirkin m...@redhat.com wrote: Knowing the answer to that is important before anyone can say whether this approach is good or not. Stefan Why is it? Because there might be a fix to kvmtool which closes the gap. It would be embarassing if

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 01:03:39PM +0100, Stefan Hajnoczi wrote: On Tue, Jul 17, 2012 at 12:54 PM, Michael S. Tsirkin m...@redhat.com wrote: Knowing the answer to that is important before anyone can say whether this approach is good or not. Stefan Why is it? Because there might be

Re: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Alexander Graf
On 07/17/2012 11:57 AM, Bhushan Bharat-R65777 wrote: -Original Message- From: kvm-ppc-ow...@vger.kernel.org [mailto:kvm-ppc-ow...@vger.kernel.org] On Behalf Of Alexander Graf Sent: Tuesday, July 17, 2012 12:50 PM To: Wood Scott-B07421 Cc: Bhushan Bharat-R65777; kvm-...@vger.kernel.org;

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Paolo Bonzini
Il 17/07/2012 14:48, Michael S. Tsirkin ha scritto: On Tue, Jul 17, 2012 at 01:03:39PM +0100, Stefan Hajnoczi wrote: On Tue, Jul 17, 2012 at 12:54 PM, Michael S. Tsirkin m...@redhat.com wrote: Knowing the answer to that is important before anyone can say whether this approach is good or not.

RE: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Bhushan Bharat-R65777
-Original Message- From: kvm-ppc-ow...@vger.kernel.org [mailto:kvm-ppc-ow...@vger.kernel.org] On Behalf Of Alexander Graf Sent: Tuesday, July 17, 2012 6:22 PM To: Bhushan Bharat-R65777 Cc: Wood Scott-B07421; kvm-...@vger.kernel.org; kvm@vger.kernel.org; bharatb.ya...@gmail.com;

Re: [PATCH 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 03:02:45PM +0200, Paolo Bonzini wrote: Il 17/07/2012 14:48, Michael S. Tsirkin ha scritto: On Tue, Jul 17, 2012 at 01:03:39PM +0100, Stefan Hajnoczi wrote: On Tue, Jul 17, 2012 at 12:54 PM, Michael S. Tsirkin m...@redhat.com wrote: Knowing the answer to that is

Re: KVM call agenda for Tuesday, July 17

2012-07-17 Thread Juan Quintela
Juan Quintela quint...@redhat.com wrote: Hi Please send in any agenda items you are interested in covering. There are no topics, so no call. Enjoy the day, Juan. -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a message to majord...@vger.kernel.org More

[PATCH 1/9] KVM: x86: remvoe unnecessary mark_page_dirty

2012-07-17 Thread Xiao Guangrong
fix: [ 132.474633] 3.5.0-rc1+ #50 Not tainted [ 132.474634] --- [ 132.474635] include/linux/kvm_host.h:369 suspicious rcu_dereference_check() usage! [ 132.474636] [ 132.474636] other info that might help us debug this: [ 132.474636] [ 132.474638] [ 132.474638]

[PATCH 2/9] KVM: x86: simplify read_emulated

2012-07-17 Thread Xiao Guangrong
No need split mmio read region into 8-bits pieces since we do it in emulator_read_write_onepage Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- arch/x86/kvm/emulate.c | 29 - 1 files changed, 12 insertions(+), 17 deletions(-) diff --git

[PATCH 3/9] KVM: x86: introduce set_mmio_exit_info

2012-07-17 Thread Xiao Guangrong
Introduce set_mmio_exit_info to cleanup the common code Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- arch/x86/kvm/x86.c | 33 + 1 files changed, 17 insertions(+), 16 deletions(-) diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index

[PATCH 4/9] KVM: MMU: track the refcount when unmap the page

2012-07-17 Thread Xiao Guangrong
It will trigger a WARN_ON if the page has been freed but it is still used in mmu, it can help us to detect mm bug early Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- arch/x86/kvm/mmu.c |8 1 files changed, 8 insertions(+), 0 deletions(-) diff --git

[PATCH 5/9] KVM: MMU: fask check write-protect for direct mmu

2012-07-17 Thread Xiao Guangrong
If it have no indirect shadow pages we need not protect any gfn, this is always true for direct mmu without nested Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- arch/x86/kvm/mmu.c |3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/arch/x86/kvm/mmu.c

[PATCH 6/9] KVM: using get_fault_pfn to get the fault pfn

2012-07-17 Thread Xiao Guangrong
Using get_fault_pfn to cleanup the code Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- arch/x86/kvm/mmu.c |6 ++ include/linux/kvm_host.h |5 + virt/kvm/kvm_main.c | 13 - 3 files changed, 7 insertions(+), 17 deletions(-) diff --git

[PATCH 7/9] KVM: mark do not extern bad_pfn

2012-07-17 Thread Xiao Guangrong
bad_pfn is not used out of kvm_main.c, so mark it static, also move it near hwpoison_pfn and fault_pfn Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- include/linux/kvm_host.h |1 - virt/kvm/kvm_main.c |6 +++--- 2 files changed, 3 insertions(+), 4 deletions(-)

[PATCH 8/9] KVM: remove is_error_hpa

2012-07-17 Thread Xiao Guangrong
Remove them since they are not used anymore Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- include/linux/kvm_host.h |4 1 files changed, 0 insertions(+), 4 deletions(-) diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h index bafcc56..f1ef5fc 100644

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 13:14 +0300, Michael S. Tsirkin wrote: On Mon, Jul 16, 2012 at 02:34:03PM -0600, Alex Williamson wrote: This is an alternative to kvm_set_irq(,,,0) which returns the previous assertion state of the interrupt and does nothing if it isn't changed. Signed-off-by: Alex

[PATCH 9/9] KVM: remove the unused parameter of gfn_to_pfn_memslot

2012-07-17 Thread Xiao Guangrong
The parameter, 'kvm', is not used in gfn_to_pfn_memslot, we can happily remove it Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- arch/powerpc/kvm/e500_tlb.c |2 +- arch/x86/kvm/mmu.c |2 +- include/linux/kvm_host.h|5 ++--- virt/kvm/iommu.c

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 13:21 +0300, Michael S. Tsirkin wrote: On Mon, Jul 16, 2012 at 02:33:55PM -0600, Alex Williamson wrote: + if (args-flags KVM_EOIFD_FLAG_LEVEL_IRQFD) { + struct _irqfd *irqfd = _irqfd_fdget_lock(kvm, args-irqfd); + if (IS_ERR(irqfd)) { +

Re: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Alexander Graf
On 07/17/2012 03:15 PM, Bhushan Bharat-R65777 wrote: -Original Message- From: kvm-ppc-ow...@vger.kernel.org [mailto:kvm-ppc-ow...@vger.kernel.org] On Behalf Of Alexander Graf Sent: Tuesday, July 17, 2012 6:22 PM To: Bhushan Bharat-R65777 Cc: Wood Scott-B07421; kvm-...@vger.kernel.org;

Re: [PATCH 0/8] KVM: Optimize MMU notifier's THP page invalidation -v4

2012-07-17 Thread Takuya Yoshikawa
On Thu, 5 Jul 2012 10:08:07 -0300 Marcelo Tosatti mtosa...@redhat.com wrote: Neat. Andrea can you please ACK? ping -- To unsubscribe from this list: send the line unsubscribe kvm in the body of a message to majord...@vger.kernel.org More majordomo info at

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 07:56:09AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 13:14 +0300, Michael S. Tsirkin wrote: On Mon, Jul 16, 2012 at 02:34:03PM -0600, Alex Williamson wrote: This is an alternative to kvm_set_irq(,,,0) which returns the previous assertion state of the

Re: [RFC/PATCH] Use kernel supplied MMU info for kvm tool

2012-07-17 Thread Pekka Enberg
On Tue, Jul 17, 2012 at 12:33 PM, Matt Evans m...@ozlabs.org wrote: Just had a look, all good. Thanks for tidying some old FIXMEs, especially the page/segment DT props encoding grot -- and the designated inits in the cpuinfo struct, whew, I heard the scream on IRC. Sorry. ;-) Acked-by: Matt

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 07:59:16AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 13:21 +0300, Michael S. Tsirkin wrote: On Mon, Jul 16, 2012 at 02:33:55PM -0600, Alex Williamson wrote: + if (args-flags KVM_EOIFD_FLAG_LEVEL_IRQFD) { + struct _irqfd *irqfd =

RE: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Bhushan Bharat-R65777
-Original Message- From: kvm-ppc-ow...@vger.kernel.org [mailto:kvm-ppc-ow...@vger.kernel.org] On Behalf Of Alexander Graf Sent: Tuesday, July 17, 2012 7:31 PM To: Bhushan Bharat-R65777 Cc: Wood Scott-B07421; kvm-...@vger.kernel.org; kvm@vger.kernel.org; bharatb.ya...@gmail.com;

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 17:08 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 07:56:09AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 13:14 +0300, Michael S. Tsirkin wrote: On Mon, Jul 16, 2012 at 02:34:03PM -0600, Alex Williamson wrote: This is an alternative to

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 17:10 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 07:59:16AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 13:21 +0300, Michael S. Tsirkin wrote: On Mon, Jul 16, 2012 at 02:33:55PM -0600, Alex Williamson wrote: + if (args-flags

Re: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Alexander Graf
On 07/17/2012 04:13 PM, Bhushan Bharat-R65777 wrote: -Original Message- From: kvm-ppc-ow...@vger.kernel.org [mailto:kvm-ppc-ow...@vger.kernel.org] On Behalf Of Alexander Graf Sent: Tuesday, July 17, 2012 7:31 PM To: Bhushan Bharat-R65777 Cc: Wood Scott-B07421; kvm-...@vger.kernel.org;

[PATCH 01/10] KVM: fix missing check for memslot flags

2012-07-17 Thread Xiao Guangrong
Check flags when memslot is registered from userspace as Avi's suggestion Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- virt/kvm/kvm_main.c | 12 1 files changed, 12 insertions(+), 0 deletions(-) diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c index

[PATCH 02/10] KVM: hide KVM_MEMSLOT_INVALID from userspace

2012-07-17 Thread Xiao Guangrong
Quote Avi's comment: | KVM_MEMSLOT_INVALID is actually an internal symbol, not used by | userspace. Please move it to kvm_host.h. Also, move KVM_MEMSLOT_INVALID to the highest bit Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- include/linux/kvm.h |1 -

[PATCH 03/10] KVM: introduce gfn_to_pfn_memslot_atomic

2012-07-17 Thread Xiao Guangrong
It can instead of hva_to_pfn_atomic Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- arch/x86/kvm/mmu.c |5 + include/linux/kvm_host.h |3 ++- virt/kvm/kvm_main.c | 14 -- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 08:29:43AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:10 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 07:59:16AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 13:21 +0300, Michael S. Tsirkin wrote: On Mon, Jul 16, 2012 at 02:33:55PM

[PATCH 04/10] KVM: introduce gfn_to_hva_read/kvm_read_hva/kvm_read_hva_atomic

2012-07-17 Thread Xiao Guangrong
This set of functions is only used to read data from host space, in the later patch, we will only get a readonly hva in gfn_to_hva_read, and the function name is a good hint to let gfn_to_hva_read to pair with kvm_read_hva()/kvm_read_hva_atomic() Signed-off-by: Xiao Guangrong

[PATCH 05/10] KVM: reorganize hva_to_pfn

2012-07-17 Thread Xiao Guangrong
We do too many things in hva_to_pfn, this patch reorganize the code, let it be better readable Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- virt/kvm/kvm_main.c | 161 +++ 1 files changed, 99 insertions(+), 62 deletions(-)

[PATCH 06/10] KVM: use 'writable' as a hint to map writable pfn

2012-07-17 Thread Xiao Guangrong
In current code, we always map writable pfn for the read-fault, in order to support readonly memslot, we map writable pfn only if 'writable' is not NULL Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- virt/kvm/kvm_main.c | 24 +++- 1 files changed, 23

[PATCH 07/10] KVM: introduce readonly_fault_pfn

2012-07-17 Thread Xiao Guangrong
Introduce readonly_fault_pfn, in the later patch, it indicates failure when we try to get a writable pfn from the readonly memslot Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- include/linux/kvm_host.h |1 + virt/kvm/kvm_main.c | 92

[PATCH 08/10] KVM: introduce readonly_bad_hva

2012-07-17 Thread Xiao Guangrong
In the later patch, it indicates failure when we try to get a writable hva from the readonly slot Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- virt/kvm/kvm_main.c | 12 +++- 1 files changed, 11 insertions(+), 1 deletions(-) diff --git a/virt/kvm/kvm_main.c

[PATCH 09/10] KVM: introduce readonly memslot

2012-07-17 Thread Xiao Guangrong
In current code, if we map a readonly memory space from host to guest and the page is not currently mapped in the host, we will get a fault-pfn and async is not allowed, then the vm will crash We introduce readonly memory region to map ROM/ROMD to the guest, read access is happy for readonly

[PATCH 10/10] KVM: indicate readonly access fault

2012-07-17 Thread Xiao Guangrong
Introduce write_readonly_mem in mmio-exit-info to indicate this exit is caused by write access on readonly memslot Signed-off-by: Xiao Guangrong xiaoguangr...@linux.vnet.ibm.com --- arch/x86/kvm/x86.c | 12 include/linux/kvm.h |3 +++ include/linux/kvm_host.h |1

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 08:21:51AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:08 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 07:56:09AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 13:14 +0300, Michael S. Tsirkin wrote: On Mon, Jul 16, 2012 at 02:34:03PM

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 17:42 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:29:43AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:10 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 07:59:16AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 13:21 +0300,

Re: [RFC-v2 0/4] tcm_vhost+cmwq fabric driver code for-3.6

2012-07-17 Thread Michael S. Tsirkin
On Wed, Jul 11, 2012 at 09:15:00PM +, Nicholas A. Bellinger wrote: From: Nicholas Bellinger n...@linux-iscsi.org Hi folks, The following is a RFC-v2 series of tcm_vhost target fabric driver code currently in-flight for-3.6 mainline code. After last week's developments along with the

Re: [PATCH RESEND 0/5] Add vhost-blk support

2012-07-17 Thread Michael S. Tsirkin
On Fri, Jul 13, 2012 at 04:55:06PM +0800, Asias He wrote: Hi folks, [I am resending to fix the broken thread in the previous one.] This patchset adds vhost-blk support. vhost-blk is a in kernel virito-blk device accelerator. Compared to userspace virtio-blk implementation, vhost-blk

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 08:57:04AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:42 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:29:43AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:10 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 07:59:16AM

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 17:53 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:21:51AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:08 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 07:56:09AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 13:14 +0300,

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 09:20:11AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:53 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:21:51AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:08 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 07:56:09AM

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 18:13 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:57:04AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:42 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:29:43AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:10 +0300,

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 18:36 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:20:11AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:53 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:21:51AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:08 +0300,

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 09:41:09AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:13 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:57:04AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:42 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:29:43AM

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 09:51:41AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:36 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:20:11AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:53 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:21:51AM

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Gleb Natapov
On Tue, Jul 17, 2012 at 06:57:01PM +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:51:41AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:36 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:20:11AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:53

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 18:53 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:41:09AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:13 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:57:04AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:42 +0300,

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 18:57 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:51:41AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:36 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:20:11AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 17:53 +0300,

RE: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Bhushan Bharat-R65777
-Original Message- From: Alexander Graf [mailto:ag...@suse.de] Sent: Tuesday, July 17, 2012 8:05 PM To: Bhushan Bharat-R65777 Cc: Wood Scott-B07421; kvm-...@vger.kernel.org; kvm@vger.kernel.org; bharatb.ya...@gmail.com; Benjamin Herrenschmidt; Kumar Gala; Avi Kivity Subject: Re:

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 10:08:21AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:57 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:51:41AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:36 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:20:11AM

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 19:14 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 10:08:21AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:57 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:51:41AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:36 +0300,

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 10:06:01AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:53 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:41:09AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:13 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 08:57:04AM

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 10:17:03AM -0600, Alex Williamson wrote: And current code looks buggy if yes we need to fix it somehow. Which to me seems to indicate this should be handled as a separate effort. A separate patchset, sure. But likely a

Re: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Scott Wood
On 07/17/2012 09:35 AM, Alexander Graf wrote: On 07/17/2012 04:13 PM, Bhushan Bharat-R65777 wrote: -Original Message- From: kvm-ppc-ow...@vger.kernel.org [mailto:kvm-ppc-ow...@vger.kernel.org] On Behalf Of Alexander Graf Sent: Tuesday, July 17, 2012 7:31 PM To: Bhushan

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Michael S. Tsirkin
On Tue, Jul 17, 2012 at 10:08:21AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:57 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:51:41AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:36 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:20:11AM

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 19:21 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 10:17:03AM -0600, Alex Williamson wrote: And current code looks buggy if yes we need to fix it somehow. Which to me seems to indicate this should be handled as a

Re: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Alexander Graf
On 07/17/2012 06:27 PM, Scott Wood wrote: On 07/17/2012 09:35 AM, Alexander Graf wrote: On 07/17/2012 04:13 PM, Bhushan Bharat-R65777 wrote: -Original Message- From: kvm-ppc-ow...@vger.kernel.org [mailto:kvm-ppc-ow...@vger.kernel.org] On Behalf Of Alexander Graf Sent: Tuesday, July 17,

Re: [PATCH v5 2/4] kvm: KVM_EOIFD, an eventfd for EOIs

2012-07-17 Thread Alex Williamson
On Tue, 2012-07-17 at 19:19 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 10:06:01AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:53 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:41:09AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:13 +0300,

RE: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Bhushan Bharat-R65777
-Original Message- From: Wood Scott-B07421 Sent: Tuesday, July 17, 2012 10:08 PM To: Bhushan Bharat-R65777 Cc: Wood Scott-B07421; Alexander Graf; kvm-...@vger.kernel.org; kvm@vger.kernel.org; bharatb.ya...@gmail.com; Benjamin Herrenschmidt; Kumar Gala Subject: Re: [PATCH 2/2 v2]

Re: [PATCH 2/2 v2] KVM: PPC: booke: Add watchdog emulation

2012-07-17 Thread Scott Wood
On 07/17/2012 11:56 AM, Bhushan Bharat-R65777 wrote: -Original Message- From: Wood Scott-B07421 Sent: Tuesday, July 17, 2012 10:08 PM To: Bhushan Bharat-R65777 Cc: Wood Scott-B07421; Alexander Graf; kvm-...@vger.kernel.org; kvm@vger.kernel.org; bharatb.ya...@gmail.com; Benjamin

Re: [PATCH v5 3/4] kvm: Create kvm_clear_irq()

2012-07-17 Thread Gleb Natapov
On Tue, Jul 17, 2012 at 07:36:49PM +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 10:08:21AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:57 +0300, Michael S. Tsirkin wrote: On Tue, Jul 17, 2012 at 09:51:41AM -0600, Alex Williamson wrote: On Tue, 2012-07-17 at 18:36

  1   2   >