Re: [RFC PATCH 0/6] ARM64: KVM: PMU infrastructure support

2014-11-21 Thread Christoffer Dall
On Thu, Nov 20, 2014 at 08:17:32PM +0530, Anup Patel wrote: > On Wed, Nov 19, 2014 at 8:59 PM, Christoffer Dall > wrote: > > On Tue, Nov 11, 2014 at 02:48:25PM +0530, Anup Patel wrote: > >> Hi All, > >> > >> I have second thoughts about rebasing KVM PMU patches > >> to Marc's irq-forwarding patche

Re: [PATCH 3/3] arm/arm64: Enable Dirty Page logging for ARMv8 move log read, tlb flush to generic code

2014-11-21 Thread Christoffer Dall
On Wed, Nov 19, 2014 at 12:15:55PM -0800, Mario Smarduch wrote: > On 11/19/2014 06:39 AM, Christoffer Dall wrote: > > Hi Mario, > > > > On Fri, Nov 07, 2014 at 12:51:39PM -0800, Mario Smarduch wrote: > >> On 11/07/2014 12:20 PM, Christoffer Dall wrote: > >>> On Thu, Oct 09, 2014 at 07:34:07PM -070

Re: Exposing host debug capabilities to userspace

2014-11-21 Thread Christoffer Dall
On Thu, Nov 20, 2014 at 04:55:14PM +, Alex Bennée wrote: > Hi, > > I've almost finished the ARMv8 guest debug support but I have one > problem left to solve. userspace needs to know how many hardware debug > registers are available for GDB to use. This information is available > from the ID_AA

Re: Exposing host debug capabilities to userspace

2014-11-21 Thread Alex Bennée
Christoffer Dall writes: > On Thu, Nov 20, 2014 at 04:55:14PM +, Alex Bennée wrote: >> Hi, >> >> I've almost finished the ARMv8 guest debug support but I have one >> problem left to solve. userspace needs to know how many hardware debug >> registers are available for GDB to use. >> * KVM io

Re: [RFC PATCH 0/6] ARM64: KVM: PMU infrastructure support

2014-11-21 Thread Anup Patel
Hi Christoffer, On Fri, Nov 21, 2014 at 3:29 PM, Christoffer Dall wrote: > On Thu, Nov 20, 2014 at 08:17:32PM +0530, Anup Patel wrote: >> On Wed, Nov 19, 2014 at 8:59 PM, Christoffer Dall >> wrote: >> > On Tue, Nov 11, 2014 at 02:48:25PM +0530, Anup Patel wrote: >> >> Hi All, >> >> >> >> I have

Re: [PATCH 3/3] arm, arm64: KVM: handle potential incoherency of readonly memslots

2014-11-21 Thread Christoffer Dall
Hi Mario, On Wed, Nov 19, 2014 at 03:32:31PM -0800, Mario Smarduch wrote: > Hi Laszlo, > > couple observations. > > I'm wondering if access from qemu and guest won't > result in mixed memory attributes and if that's acceptable > to the CPU. > > Also is if you update memory from qemu you ma

Re: Exposing host debug capabilities to userspace

2014-11-21 Thread Alex Bennée
Christoffer Dall writes: > On Thu, Nov 20, 2014 at 04:55:14PM +, Alex Bennée wrote: >> >> * ptrace(PTRACE_GETREGSET, NT_ARM_HW_WATCH) >> >> This is used by GDB to access the host details in debug-monitors. >> However the ptrace API really wants you to attach to a process before >> calling

Re: [PATCH 1/2] arm/arm64: kvm: drop inappropriate use of kvm_is_mmio_pfn()

2014-11-21 Thread Christoffer Dall
On Mon, Nov 10, 2014 at 09:33:55AM +0100, Ard Biesheuvel wrote: > Instead of using kvm_is_mmio_pfn() to decide whether a host region > should be stage 2 mapped with device attributes, add a new static > function kvm_is_device_pfn() that disregards RAM pages with the > reserved bit set, as those sho

Re: [PATCH 2/2] kvm: fix kvm_is_mmio_pfn() and rename to kvm_is_reserved_pfn()

2014-11-21 Thread Ard Biesheuvel
On 10 November 2014 09:33, Ard Biesheuvel wrote: > This reverts commit 85c8555ff0 ("KVM: check for !is_zero_pfn() in > kvm_is_mmio_pfn()") and renames the function to kvm_is_reserved_pfn. > > The problem being addressed by the patch above was that some ARM code > based the memory mapping attribute

Re: [PATCH 2/2] kvm: fix kvm_is_mmio_pfn() and rename to kvm_is_reserved_pfn()

2014-11-21 Thread Christoffer Dall
Hi Paolo, I think these look good, would you mind queueing them as either a fix or for 3.19 as you see fit, assuming you agree with the content? Thanks, -Christoffer On Mon, Nov 10, 2014 at 09:33:56AM +0100, Ard Biesheuvel wrote: > This reverts commit 85c8555ff0 ("KVM: check for !is_zero_pfn() i

Re: [RFC PATCH 0/6] ARM64: KVM: PMU infrastructure support

2014-11-21 Thread Christoffer Dall
On Fri, Nov 21, 2014 at 04:06:05PM +0530, Anup Patel wrote: > Hi Christoffer, > > On Fri, Nov 21, 2014 at 3:29 PM, Christoffer Dall > wrote: > > On Thu, Nov 20, 2014 at 08:17:32PM +0530, Anup Patel wrote: > >> On Wed, Nov 19, 2014 at 8:59 PM, Christoffer Dall > >> wrote: > >> > On Tue, Nov 11, 2

Re: [PATCH v1] ARM/ARM64: support KVM_IOEVENTFD

2014-11-21 Thread Eric Auger
Hi Ming, for your information there is a series written by Antonios (added in CC) https://lists.cs.columbia.edu/pipermail/kvmarm/2014-March/008416.html exactly on the same topic. The thread was reactivated by Nikolay latterly on Nov (see http://www.gossamer-threads.com/lists/linux/kernel/1886716?

Re: [PATCH 2/2] kvm: fix kvm_is_mmio_pfn() and rename to kvm_is_reserved_pfn()

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 12:46, Christoffer Dall wrote: > Hi Paolo, > > I think these look good, would you mind queueing them as either a fix or > for 3.19 as you see fit, assuming you agree with the content? Ah, I was thinking _you_ would queue them for 3.19. Paolo -- To unsubscribe from this list: send

Re: [PATCH 3.10] vhost-net: backport extend device allocation to 3.10

2014-11-21 Thread Dmitry Petuhov
12.10.2014 13:30, Michael S. Tsirkin пишет: On Thu, Oct 09, 2014 at 08:41:23AM +0400, Dmitry Petuhov wrote: Cc: Michael Mueller Signed-off-by: Romain Francoise Acked-by: Michael S. Tsirkin [mityapetuhov: backport to v3.10: vhost_net_free() in one more place] Signed-off-by: Dmitry Petuhov So

Re: [PATCH 2/2] kvm: fix kvm_is_mmio_pfn() and rename to kvm_is_reserved_pfn()

2014-11-21 Thread Christoffer Dall
On Fri, Nov 21, 2014 at 02:06:40PM +0100, Paolo Bonzini wrote: > > > On 21/11/2014 12:46, Christoffer Dall wrote: > > Hi Paolo, > > > > I think these look good, would you mind queueing them as either a fix or > > for 3.19 as you see fit, assuming you agree with the content? > > Ah, I was thinki

Re: can I make this work… (Foundation for accessibility project)

2014-11-21 Thread Paolo Bonzini
On 20/11/2014 23:22, Eric S. Johansson wrote: > I'll be able to run some tests in about 2 to 3 hours after I finish this > document. Let me know what I should look at? on a side note, a pointer > to an automated install process would be wonderful. GNOME Boxes can pretty much automate the instal

Re: KVM causes #GP on XRSTORS

2014-11-21 Thread Paolo Bonzini
On 20/11/2014 17:34, Nadav Amit wrote: > Fenghua, > > I got KVM (v3.17) crashing on a machine that supports XRSTORS - It appears to > get a #GP when it is trying to load the guest FPU. > One reason for the #GP is that XCOMP_BV[63] is zeroed on the guest_fpu, but I > am not sure it is the only

Re: [PATCH] kvm: x86: move ioapic.c and irq_comm.c back to arch/x86/

2014-11-21 Thread Radim Krčmář
2014-11-20 14:42+0100, Paolo Bonzini: > ia64 does not need them anymore. (Similar for device assignment and iommu, should I prepare patches?) > Signed-off-by: Paolo Bonzini > --- At least one compile-breaker on arches without IOAPIC, > diff --git a/include/linux/kvm_host.h b/include/linux/kvm_

Re: [PATCH] kvm: x86: move ioapic.c and irq_comm.c back to arch/x86/

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 17:19, Radim Krčmář wrote: > 2014-11-20 14:42+0100, Paolo Bonzini: >> ia64 does not need them anymore. > > (Similar for device assignment and iommu, should I prepare patches?) Sure! Feel free to join the party. ;) Paolo >> Signed-off-by: Paolo Bonzini >> --- > > At least one co

Re: can I make this work… (Foundation for accessibility project)

2014-11-21 Thread Eric S. Johansson
On 11/21/2014 09:06 AM, Paolo Bonzini wrote: On 20/11/2014 23:22, Eric S. Johansson wrote: I'll be able to run some tests in about 2 to 3 hours after I finish this document. Let me know what I should look at? on a side note, a pointer to an automated install process would be wonderful. GNOME

Re: [PATCH] kvm: x86: move ioapic.c and irq_comm.c back to arch/x86/

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 17:19, Radim Krčmář wrote: > KVM: x86: remove IA64 from ioapic.c and irq_comm.c > > They won't get compiled in x86 tree. Ah no, these were already in my ia64 removal patch. I had a deja-vu feeling... Paolo -- To unsubscribe from this list: send the line "unsubscribe kvm" in the bo

[PATCH 1/3] arm64: KVM: fix unmapping with 48-bit VAs

2014-11-21 Thread Marc Zyngier
From: Mark Rutland Currently if using a 48-bit VA, tearing down the hyp page tables (which can happen in the absence of a GICH or GICV resource) results in the rather nasty splat below, evidently becasue we access a table that doesn't actually exist. Commit 38f791a4e499792e (arm64: KVM: Implemen

[PULL] arm/arm64: KVM: pull request for 3.18-rc6

2014-11-21 Thread Marc Zyngier
Hi Paolo, Please consider pulling the following patches that fixes a few issues for KVM on arm/arm64. The following changes since commit 41e7ed64d86db351a94063596b478a0bfc040258: KVM: nVMX: Disable preemption while reading from shadow VMCS (2014-10-29 13:13:52 +0100) are available in the git

[PATCH 2/3] arm64: KVM: Handle traps of ICC_SRE_EL1 as RAZ/WI

2014-11-21 Thread Marc Zyngier
From: Christoffer Dall When running on a system with a GICv3, we currenly don't allow the guest to access the system register interface of the GICv3. We do this by clearing the ICC_SRE_EL2.Enable, which causes all guest accesses to ICC_SRE_EL1 to trap to EL2 and causes all guest accesses to othe

[PATCH 3/3] arm/arm64: KVM: vgic: Fix error code in kvm_vgic_create()

2014-11-21 Thread Marc Zyngier
From: Christoffer Dall If we detect another vCPU is running we just exit and return 0 as if we succesfully created the VGIC, but the VGIC wouldn't actual be created. This shouldn't break in-kernel behavior because the kernel will not observe the failed the attempt to create the VGIC, but userspa

Re: [PATCH] kvm: x86: move ioapic.c and irq_comm.c back to arch/x86/

2014-11-21 Thread Radim Krčmář
2014-11-21 18:05+0100, Paolo Bonzini: > On 21/11/2014 17:19, Radim Krčmář wrote: > > KVM: x86: remove IA64 from ioapic.c and irq_comm.c > > > > They won't get compiled in x86 tree. > > Ah no, these were already in my ia64 removal patch. I had a deja-vu > feeling... Oops, renaming simplifies con

Re: can I make this work… (Foundation for accessibility project)

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 17:52, Eric S. Johansson wrote: > > 4384 libvirt+ 20 0 2825112 2.058g 9960 R 109.1 26.6 12:47.73 > qemu-system-x86 > > next report after updates install > > btw, would you like a better UI design for a management tool? I have > some ideas but would need someone with hands

next puzzle: Re: can I make this work… (Foundation for accessibility project)

2014-11-21 Thread Eric S. Johansson
On 11/21/2014 11:52 AM, Eric S. Johansson wrote: 4384 libvirt+ 20 0 2825112 2.058g 9960 R 109.1 26.6 12:47.73 qemu-system-x86 next report after updates install next puzzle. updates are not working using bridged to eth0 using virt io driver (checked install on windows) browser works

[CFT PATCH 1/2] kvm: x86: mask out XSAVES

2014-11-21 Thread Paolo Bonzini
This feature is not supported inside KVM guests yet, because we do not emulate MSR_IA32_XSS. Mask it out. Cc: sta...@vger.kernel.org Cc: Nadav Amit Signed-off-by: Paolo Bonzini --- arch/x86/kvm/cpuid.c | 11 ++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/arch/x86/kvm

[CFT PATCH 2/2] KVM: x86: support XSAVES usage in the host

2014-11-21 Thread Paolo Bonzini
Userspace is expecting non-compacted format for KVM_GET_XSAVE, but struct xsave_struct might be using the compacted format. Convert in order to preserve userspace ABI. Fixes: f31a9f7c71691569359fa7fb8b0acaa44bce0324 Cc: Fenghua Yu Cc: sta...@vger.kernel.org Cc: Nadav Amit Signed-off-by: Paolo B

Re: [PULL] arm/arm64: KVM: pull request for 3.18-rc6

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 18:21, Marc Zyngier wrote: > git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm.git > tags/kvm-arm-for-3.18-rc6 Pulled, thanks. I'm not sure I'll be able to forward the request to Linus in time, though. Paolo -- To unsubscribe from this list: send the line "unsubscrib

[Bug 88671] BUG at drivers/pci/ats.c:62! the second time booting a kvm guest with pci passthrough

2014-11-21 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=88671 --- Comment #1 from Tom Stellard --- Created attachment 158391 --> https://bugzilla.kernel.org/attachment.cgi?id=158391&action=edit Backtrace from BUG_ON -- You are receiving this mail because: You are watching the assignee of the bug. -- To u

[Bug 88671] New: BUG at drivers/pci/ats.c:62! the second time booting a kvm guest with pci passthrough

2014-11-21 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=88671 Bug ID: 88671 Summary: BUG at drivers/pci/ats.c:62! the second time booting a kvm guest with pci passthrough Product: Virtualization Version: unspecified Kernel Version: 3.17.3

[Bug 88671] BUG at drivers/pci/ats.c:62! the second time booting a kvm guest with pci passthrough

2014-11-21 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=88671 --- Comment #2 from Tom Stellard --- Created attachment 158401 --> https://bugzilla.kernel.org/attachment.cgi?id=158401&action=edit Virtual machine definition -- You are receiving this mail because: You are watching the assignee of the bug. --

Re: KVM causes #GP on XRSTORS

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 15:46, Paolo Bonzini wrote: > Fenghua, which processors have XSAVEC, which have XGETBV with ECX=1, and > which have XSAVES? We need to expose this in QEMU, for which I can send > a patch later today or next week (CCing Eduardo for this). Actually no change in QEMU is needed to hid

[Bug 88671] BUG at drivers/pci/ats.c:62! the second time booting a kvm guest with pci passthrough

2014-11-21 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=88671 --- Comment #3 from Tom Stellard --- I should also mention that I have this hook executing when the machine starts up: if [ "$2" = "prepare" ]; then virsh nodedev-detach pci__01_00_1 fi -- You are receiving this mail because: You ar

Re: [PATCH 2/2] kvm: fix kvm_is_mmio_pfn() and rename to kvm_is_reserved_pfn()

2014-11-21 Thread Paolo Bonzini
On 10/11/2014 09:33, Ard Biesheuvel wrote: > This reverts commit 85c8555ff0 ("KVM: check for !is_zero_pfn() in > kvm_is_mmio_pfn()") and renames the function to kvm_is_reserved_pfn. > > The problem being addressed by the patch above was that some ARM code > based the memory mapping attributes of

Re: [PATCH 2/2] kvm: fix kvm_is_mmio_pfn() and rename to kvm_is_reserved_pfn()

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 14:18, Christoffer Dall wrote: > On Fri, Nov 21, 2014 at 02:06:40PM +0100, Paolo Bonzini wrote: >> >> >> On 21/11/2014 12:46, Christoffer Dall wrote: >>> Hi Paolo, >>> >>> I think these look good, would you mind queueing them as either a fix or >>> for 3.19 as you see fit, assuming

[CFT PATCH 0/2] KVM: support XSAVES usage in the host

2014-11-21 Thread Paolo Bonzini
The first patch ensures that XSAVES is not exposed in the guest until we emulate MSR_IA32_XSS. The second exports XSAVE data in the correct format. I tested these on a non-XSAVES system so they should not be completely broken, but I need some help. I am not even sure which XSAVE states are _not_

Re: next puzzle: Re: can I make this work… (Foundation for accessibility project)

2014-11-21 Thread Eric S. Johansson
a little more info On 11/21/2014 01:24 PM, Eric S. Johansson wrote: next puzzle. updates are not working using bridged to eth0 using virt io driver (checked install on windows) browser works in vm (quite well in fact) watching output of tcpdump and there is no apparent traffic for updates. in

[Bug 88671] BUG at drivers/pci/ats.c:62! the second time booting a kvm guest with pci passthrough

2014-11-21 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=88671 Alex Williamson changed: What|Removed |Added CC||alex.william...@redhat.com --- Comment

Re: [RFC PATCH v1 1/2] vfio: Add new interrupt group for VFIO

2014-11-21 Thread Alex Williamson
On Fri, 2014-11-21 at 06:06 +, Wu, Feng wrote: > > > -Original Message- > > From: Alex Williamson [mailto:alex.william...@redhat.com] > > Sent: Thursday, November 20, 2014 11:54 PM > > To: Wu, Feng > > Cc: pbonz...@redhat.com; kvm@vger.kernel.org; eric.auger > > Subject: Re: [RFC PATCH

Re: [CFT PATCH 2/2] KVM: x86: support XSAVES usage in the host

2014-11-21 Thread Andy Lutomirski
On 11/21/2014 10:31 AM, Paolo Bonzini wrote: > Userspace is expecting non-compacted format for KVM_GET_XSAVE, but > struct xsave_struct might be using the compacted format. Convert > in order to preserve userspace ABI. > > Fixes: f31a9f7c71691569359fa7fb8b0acaa44bce0324 > Cc: Fenghua Yu > Cc: st

Re: [Qemu-devel] [PATCH 00/17] RFC: userfault v2

2014-11-21 Thread Andrea Arcangeli
Hi Peter, On Wed, Oct 29, 2014 at 05:56:59PM +, Peter Maydell wrote: > On 29 October 2014 17:46, Andrea Arcangeli wrote: > > After some chat during the KVMForum I've been already thinking it > > could be beneficial for some usage to give userland the information > > about the fault being read

[PATCH] kvm: x86: move assigned-dev.c and iommu.c to arch/x86/

2014-11-21 Thread Radim Krčmář
Now that ia64 is gone, we can hide deprecated device assignment in x86. Notable changes: - kvm_vm_ioctl_assigned_device() was moved to x86/kvm_arch_vm_ioctl() The easy parts were removed from generic kvm code, remaining - kvm_iommu_(un)map_pages() would require new code to be moved - struct kv

Re: [CFT PATCH 2/2] KVM: x86: support XSAVES usage in the host

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 21:06, Andy Lutomirski wrote: >> > + cpuid_count(XSTATE_CPUID, index, >> > + &size, &offset, &ecx, &edx); >> > + memcpy(dest + offset, src, size); > Is this really the best way to do this? cpuid is serializing, so this

Re: [PATCH v4] KVM: x86: fix access memslots w/o hold srcu read lock

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 07:30, Wanpeng Li wrote: > I test it on the other guy's Ivytown and take advantage of the qemu command > line which he used, so I forget the accurate command line which used that day. > > Paolo also reproduce the bug, Paolo, ping. It also reproduced always for me with a debug ker

Re: [question] lots of interrupts injected to vm when pressing some key w/o releasing

2014-11-21 Thread Paolo Bonzini
On 21/11/2014 15:20, Zhang, Yang Z wrote: > Zhang Haoyu wrote on 2014-11-20: >> Hi all, >> >> If I press the one of "Insert/Delete/Home/End/PageUp/PageDown/UpArrow/ >> DownArrow/LeftArrow/RightArrow" key w/o releasing, then lots of >> interrupts will be injected to vm(win7/win2008), about 8000/s,

Re: [Qemu-devel] [PATCH 00/17] RFC: userfault v2

2014-11-21 Thread Peter Maydell
On 21 November 2014 20:14, Andrea Arcangeli wrote: > Hi Peter, > > On Wed, Oct 29, 2014 at 05:56:59PM +, Peter Maydell wrote: >> On 29 October 2014 17:46, Andrea Arcangeli wrote: >> > After some chat during the KVMForum I've been already thinking it >> > could be beneficial for some usage to

Re: [PATCH 3/3] arm/arm64: Enable Dirty Page logging for ARMv8 move log read, tlb flush to generic code

2014-11-21 Thread Mario Smarduch
On 11/21/2014 02:09 AM, Christoffer Dall wrote: > On Wed, Nov 19, 2014 at 12:15:55PM -0800, Mario Smarduch wrote: >> On 11/19/2014 06:39 AM, Christoffer Dall wrote: >>> Hi Mario, >>> >>> On Fri, Nov 07, 2014 at 12:51:39PM -0800, Mario Smarduch wrote: On 11/07/2014 12:20 PM, Christoffer Dall wr

Re: [PATCH 3/3] arm, arm64: KVM: handle potential incoherency of readonly memslots

2014-11-21 Thread Mario Smarduch
On 11/21/2014 03:19 AM, Christoffer Dall wrote: > Hi Mario, > > On Wed, Nov 19, 2014 at 03:32:31PM -0800, Mario Smarduch wrote: >> Hi Laszlo, >> >> couple observations. >> >> I'm wondering if access from qemu and guest won't >> result in mixed memory attributes and if that's acceptable >> to

[PATCH] KVM: nVMX: nested MSR auto load/restore emulation.

2014-11-21 Thread Wincy Van
Some hypervisors need MSR auto load/restore feature. We read MSRs from vm-entry MSR load area which specified by L1, and load them via kvm_set_msr in the nested entry. When nested exit occurs, we get MSRs via kvm_get_msr, writting them to L1`s MSR store area. After this, we read MSRs from vm-exit

Re: [PATCH] KVM: nVMX: nested MSR auto load/restore emulation.

2014-11-21 Thread Jan Kiszka
On 2014-11-22 05:24, Wincy Van wrote: > Some hypervisors need MSR auto load/restore feature. > > We read MSRs from vm-entry MSR load area which specified by L1, > and load them via kvm_set_msr in the nested entry. > When nested exit occurs, we get MSRs via kvm_get_msr, writting > them to L1`s MSR