Re: [RFC-v5] tcm_vhost: Initial merge for vhost level target fabric driver

2012-07-31 Thread Paolo Bonzini
Il 31/07/2012 22:52, Eric Northup ha scritto: > It seems to me like this is not the way that virtio devices are supposed > to behave - if a guest splits a virtio_scsi_cmd_req or _resp across a > page boundary, then this code won't work. Buffers can cover several pages. Of course, data buffers hav

[PATCH 3/3] vfio: Enable vfio-pci and mark supported

2012-07-31 Thread Alex Williamson
Signed-off-by: Alex Williamson --- MAINTAINERS |5 + configure | 12 hw/i386/Makefile.objs |1 + 3 files changed, 18 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 2d219d2..9680d69 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -460,6

[PATCH 1/3] vfio: Import vfio kernel header

2012-07-31 Thread Alex Williamson
Signed-off-by: Alex Williamson --- linux-headers/linux/vfio.h | 368 1 file changed, 368 insertions(+) create mode 100644 linux-headers/linux/vfio.h diff --git a/linux-headers/linux/vfio.h b/linux-headers/linux/vfio.h new file mode 100644 index 000

[PATCH 0/3] VFIO-based PCI device assignment for QEMU 1.2

2012-07-31 Thread Alex Williamson
VFIO kernel support was just merged into Linux, so I'd like to formally propose inclusion of the QEMU vfio-pci driver for QEMU 1.2. Included here is support for x86 PCI device assignment. PCI INTx is not yet enabled, but devices making use of either MSI or MSI-X work. The level irqfd and eoifd su

Re: [RFC PATCH] KVM: Only print vcpu_unimpl when DEBUG is set

2012-07-31 Thread Marcelo Tosatti
On Thu, Jul 26, 2012 at 02:22:48PM +0200, Markus Trippelsdorf wrote: > Every time I start qemu-kvm on my system the following line is added to > the syslog: > > vcpu0 unhandled rdmsr: 0xc0010001 > > AFAICS all calls to vcpu_unimpl only contain debugging info with little > or no value for the end

Re: [PATCH 0/4] kvm_timer cleanup

2012-07-31 Thread Marcelo Tosatti
On Thu, Jul 26, 2012 at 06:01:49PM +0300, Avi Kivity wrote: > While preparing to fix up KVM_REQ_PENDING_TIMERS, and looking for a bug that > turned > out not to exist, I cleaned up kvm_timer a little. > > Avi Kivity (4): > KVM: Remove internal timer abstraction. > KVM: Simplify kvm_timer >

Reset problem vs. MMIO emulation, hypercalls, etc...

2012-07-31 Thread Benjamin Herrenschmidt
Hi Avi ! We identified a problem on powerpc which seems to actually be a generic issue, and Alex suggested we propose a generic fix. I want to make sure we are on the right track first before proposing an actual patch as we would like the patch to go in ASAP (ie not waiting the next merge window)

Re: [PATCH] Documentation/kvm : Add documentation on Hypercalls

2012-07-31 Thread Marcelo Tosatti
On Tue, Jul 24, 2012 at 02:23:59PM +0530, Raghavendra K T wrote: > From: Raghavendra K T > > Thanks Alex for KVM_HC_FEATURES inputs and Jan for VAPIC_POLL_IRQ, > and Peter (HPA) for suggesting hypercall ABI addition. > > Signed-off-by: Raghavendra K T > --- > Please have a closer look at Hyperc

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

2012-07-31 Thread Alexander Graf
On 01.08.2012, at 04:13, Scott Wood wrote: > On 07/31/2012 06:59 PM, Alexander Graf wrote: >> Well, user space always comes in via the ioctl path, which in turn >> does vcpu_load(vcpu), thus should always be running as the vcpu >> context itself. > > Right, it's the timers you're racing with. >

Re: [PATCH 4/4] Enable kvm emulated watchdog

2012-07-31 Thread Alexander Graf
On 20.07.2012, at 07:23, Bharat Bhushan wrote: > Enable the KVM emulated watchdog if KVM supports (use the > capability enablement in watchdog handler). Also watchdog exit > (KVM_EXIT_WATCHDOG) handling is added. > Watchdog state machine is cleared whenever VM state changes to running. > This is

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

2012-07-31 Thread Scott Wood
On 07/31/2012 06:59 PM, Alexander Graf wrote: > Well, user space always comes in via the ioctl path, which in turn > does vcpu_load(vcpu), thus should always be running as the vcpu > context itself. Right, it's the timers you're racing with. > It boils down to the original thing I was saying back

pci_get_subsys: GFP_KERNEL allocations with IRQs disabled

2012-07-31 Thread Fengguang Wu
On Tue, Jul 31, 2012 at 05:18:11PM -0700, Paul E. McKenney wrote: > On Tue, Jul 31, 2012 at 08:09:38PM -0400, Steven Rostedt wrote: > > On Tue, 2012-07-31 at 16:57 -0700, Paul E. McKenney wrote: > > > > > > What was the next lines? I bet you it was "PASSED". Which means it did > > > > not fail. Th

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Paul E. McKenney
On Tue, Jul 31, 2012 at 08:09:38PM -0400, Steven Rostedt wrote: > On Tue, 2012-07-31 at 16:57 -0700, Paul E. McKenney wrote: > > > > What was the next lines? I bet you it was "PASSED". Which means it did > > > not fail. This is the second bug you found that has to do with RCU being > > > called in

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Steven Rostedt
On Tue, 2012-07-31 at 16:57 -0700, Paul E. McKenney wrote: > > What was the next lines? I bet you it was "PASSED". Which means it did > > not fail. This is the second bug you found that has to do with RCU being > > called in 'idle'. The one that Paul posted a patch for. > > Though it needs anothe

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

2012-07-31 Thread Alexander Graf
On 31.07.2012, at 23:24, Scott Wood wrote: > On 07/31/2012 06:50 AM, Alexander Graf wrote: >> >> On 25.07.2012, at 05:49, Bharat Bhushan wrote: >> >>> This patch adds the watchdog emulation in KVM. The watchdog >>> emulation is enabled by KVM_ENABLE_CAP(KVM_CAP_PPC_BOOKE_WATCHDOG) ioctl. >>> Th

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Fengguang Wu
On Tue, Jul 31, 2012 at 07:51:39PM -0400, Steven Rostedt wrote: > On Wed, 2012-08-01 at 07:43 +0800, Fengguang Wu wrote: > > On Tue, Jul 31, 2012 at 09:13:39AM -0400, Steven Rostedt wrote: > > > On Tue, 2012-07-31 at 15:50 +0300, Avi Kivity wrote: > > > > On 07/31/2012 03:43 PM, Steven Rostedt wrot

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Paul E. McKenney
On Tue, Jul 31, 2012 at 07:51:39PM -0400, Steven Rostedt wrote: > On Wed, 2012-08-01 at 07:43 +0800, Fengguang Wu wrote: > > On Tue, Jul 31, 2012 at 09:13:39AM -0400, Steven Rostedt wrote: > > > On Tue, 2012-07-31 at 15:50 +0300, Avi Kivity wrote: > > > > On 07/31/2012 03:43 PM, Steven Rostedt wrot

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Steven Rostedt
On Wed, 2012-08-01 at 07:43 +0800, Fengguang Wu wrote: > On Tue, Jul 31, 2012 at 09:13:39AM -0400, Steven Rostedt wrote: > > On Tue, 2012-07-31 at 15:50 +0300, Avi Kivity wrote: > > > On 07/31/2012 03:43 PM, Steven Rostedt wrote: > > > > > That would be better. A hypervisor might be real-time cap

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Fengguang Wu
On Tue, Jul 31, 2012 at 09:13:39AM -0400, Steven Rostedt wrote: > On Tue, 2012-07-31 at 15:50 +0300, Avi Kivity wrote: > > On 07/31/2012 03:43 PM, Steven Rostedt wrote: > > > That would be better. A hypervisor might be real-time capable (with > > some effort kvm can do this), so we don't want to

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

2012-07-31 Thread Scott Wood
On 07/31/2012 06:50 AM, Alexander Graf wrote: > > On 25.07.2012, at 05:49, Bharat Bhushan wrote: > >> This patch adds the watchdog emulation in KVM. The watchdog >> emulation is enabled by KVM_ENABLE_CAP(KVM_CAP_PPC_BOOKE_WATCHDOG) ioctl. >> The kernel timer are used for watchdog emulation and em

Re: KVM: MMU: Tracking guest writes through EPT entries ?

2012-07-31 Thread Sunil Agham
On Mon, Jul 30, 2012 at 10:49 PM, Xiao Guangrong wrote: > On 07/31/2012 01:18 AM, Sunil wrote: >> Hello List, >> >> I am a KVM newbie and studying KVM mmu code. >> >> On the existing guest, I am trying to track all guest writes by >> marking page table entry as read-only in EPT entry [ I am using

Re: [GIT PULL (PATCH 0/4)] VFIO driver for v3.6

2012-07-31 Thread Alex Williamson
On Tue, 2012-07-31 at 08:53 -0600, Alex Williamson wrote: > On Mon, 2012-07-30 at 22:11 -0700, Linus Torvalds wrote: > > On Mon, Jul 30, 2012 at 4:17 PM, Alex Williamson > > wrote: > > > > > > I'm pretty anxious to find out as well. Linus, ping, any thoughts on > > > including this in 3.6? Thank

Re: qemu-kvm-1.1.0 crashing with kernel 3.5.0-rc6

2012-07-31 Thread Marcelo Tosatti
On Tue, Jul 31, 2012 at 12:11:13PM +0300, Avi Kivity wrote: > On 07/31/2012 02:36 AM, Marcelo Tosatti wrote: > > On Mon, Jul 30, 2012 at 07:39:31PM +0300, Avi Kivity wrote: > >> On 07/30/2012 05:07 PM, Chris Clayton wrote: > >> >> > >> With kernel 3.5.0 with b2da15ac26a0c00 reverted, I have ju

Re: KVM segfaults with 3.5 while installing ubuntu 12.04

2012-07-31 Thread Stefan Priebe
Now i got it working - sorry used old gdb. This is the backtrace: Core was generated by `/usr/bin/qemu-system-x86_64 -id 103 -chardev socket,id=qmp,path=/var/run/qemu-s'. Program terminated with signal 11, Segmentation fault. #0 0x7f6ca10faed8 in ?? () from /lib/libc.so.6 (gdb) where #0

Re: KVM segfaults with 3.5 while installing ubuntu 12.04

2012-07-31 Thread Stefan Priebe
Am 31.07.2012 16:54, schrieb Avi Kivity: On 07/31/2012 02:59 PM, Stefan Priebe - Profihost AG wrote: Hello list, i hope it is correct to list the maintainers of kvm. While trying to install ubuntu 12.04 amd64 on a kvm based vm the KVM process segfaults while ubuntu tries to detect the HW: kvm[2

Re: [Qemu-devel] [RFC PATCH] vfio: VFIO PCI driver for Qemu

2012-07-31 Thread Alex Williamson
On Tue, 2012-07-31 at 15:34 +0300, Avi Kivity wrote: > On 07/31/2012 01:29 AM, Alex Williamson wrote: > >> > >> If the region size is zero, then both memory_region_del_subregion() > >> (assuming the region is parented) and munmap() do nothing. So you could > >> call this unconditionally. > > > >

Re: qemu-kvm-1.1.0 crashing with kernel 3.5.0-rc6

2012-07-31 Thread Avi Kivity
On 07/31/2012 07:29 PM, Marcelo Tosatti wrote: >> >> So the same problem should happen with %fs and %gs, no? > > AFAICS: > > depends on CONFIG_X86_32_LAZY_GS for GS, unconditional for FS. This fs/gs were already in there, I wonder how it wasn't broken before. Something's fishy here. > >> x8

Re: [Qemu-devel] KVM call minutes July 31th

2012-07-31 Thread Andreas Färber
Am 31.07.2012 18:06, schrieb Igor Mammedov: > - Original Message - >> From: "Eduardo Habkost" >> To: "Juan Quintela" , "Anthony Liguori" >> >> Cc: qemu-de...@nongnu.org, "KVM devel mailing list" >> Sent: Tuesday, July 31, 2012 5:40:14 PM >> Subject: Re: [Qemu-devel] KVM call minutes Jul

Re: [Qemu-devel] KVM call minutes July 31th

2012-07-31 Thread Igor Mammedov
- Original Message - > From: "Eduardo Habkost" > To: "Juan Quintela" , "Anthony Liguori" > > Cc: qemu-de...@nongnu.org, "KVM devel mailing list" > Sent: Tuesday, July 31, 2012 5:40:14 PM > Subject: Re: [Qemu-devel] KVM call minutes July 31th > > On Tue, Jul 31, 2012 at 04:32:05PM +0200

Re: [Qemu-devel] KVM call minutes July 31th

2012-07-31 Thread Andreas Färber
Am 31.07.2012 17:40, schrieb Eduardo Habkost: > On Tue, Jul 31, 2012 at 04:32:05PM +0200, Juan Quintela wrote: >> - 1.2 plans for CPU model versioning/compatibility (eduardo) >> (global properties vs QOM vs qdev) >> how to do it ? configuration file? moving back to the code? >> different ex

Re: KVM call minutes July 31th

2012-07-31 Thread Eduardo Habkost
On Tue, Jul 31, 2012 at 04:32:05PM +0200, Juan Quintela wrote: > - 1.2 plans for CPU model versioning/compatibility (eduardo) > (global properties vs QOM vs qdev) > how to do it ? configuration file? moving back to the code? > different external interface from internal one Another question

QEMU CPU model versioning/compatibility (was Re: KVM call minutes July 31th)

2012-07-31 Thread Eduardo Habkost
On Tue, Jul 31, 2012 at 04:32:05PM +0200, Juan Quintela wrote: > - 1.2 plans for CPU model versioning/compatibility (eduardo) > (global properties vs QOM vs qdev) > how to do it ? configuration file? moving back to the code? > different external interface from internal one (CCing libvir-li

Re: KVM segfaults with 3.5 while installing ubuntu 12.04

2012-07-31 Thread Avi Kivity
On 07/31/2012 02:59 PM, Stefan Priebe - Profihost AG wrote: > Hello list, > > i hope it is correct to list the maintainers of kvm. While trying to > install ubuntu 12.04 amd64 on a kvm based vm the KVM process segfaults > while ubuntu tries to detect the HW: > kvm[2978]: segfault at 7fb90d9035e0 i

Re: [GIT PULL (PATCH 0/4)] VFIO driver for v3.6

2012-07-31 Thread Alex Williamson
On Mon, 2012-07-30 at 22:11 -0700, Linus Torvalds wrote: > On Mon, Jul 30, 2012 at 4:17 PM, Alex Williamson > wrote: > > > > I'm pretty anxious to find out as well. Linus, ping, any thoughts on > > including this in 3.6? Thanks, > > I just pulled it, but then I unpulled again when I realized it

Re: [Qemu-devel] 9p broken?

2012-07-31 Thread Avi Kivity
On 07/31/2012 04:30 PM, Aneesh Kumar K.V wrote: > > Did this help ? > > http://mid.gmane.org/1343719453-26768-1-git-send-email-aneesh.ku...@linux.vnet.ibm.com > It did: thanks. -- error compiling committee.c: too many arguments to function -- To unsubscribe from this list: send the line "u

Re: [Qemu-devel] 9p broken?

2012-07-31 Thread Aneesh Kumar K.V
Avi Kivity writes: > On 07/31/2012 09:51 AM, Aneesh Kumar K.V wrote: >> Avi Kivity writes: >> >>> Having an annoying bug on i386 kvm I decided to debug it buy running an >>> i386 guest on my x86_64 host, use 9p to access a guest image, and run it >>> using nested kvm. >>> >>> However, 9p appear

Re: [Qemu-devel] [PATCH v4] Fixes related to processing of qemu's -numa option

2012-07-31 Thread Eduardo Habkost
Ping? Can anybody help Vinod, here? How can we get the attention of some maintainer, to get this pulled in? On Wed, Jul 18, 2012 at 06:26:52PM +, Vinod, Chegu wrote: > Thanks Eduardo ! > > Hi Anthony, If you are ok with this patch...could you pl pull these changes > into upstream (or) > s

Re: [Qemu-devel] KVM call agenda for Tuesday, July 31

2012-07-31 Thread Eduardo Habkost
On Mon, Jul 30, 2012 at 09:34:05AM +0200, Juan Quintela wrote: > > Hi > > Please send in any agenda items you are interested in covering. - 1.2 plans for CPU model versioning/compatibility (global properties vs QOM vs qdev) -- Eduardo -- To unsubscribe from this list: send the line "unsubscr

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Steven Rostedt
On Tue, 2012-07-31 at 15:50 +0300, Avi Kivity wrote: > On 07/31/2012 03:43 PM, Steven Rostedt wrote: > That would be better. A hypervisor might be real-time capable (with > some effort kvm can do this), so we don't want to turn off real time > features just based on that. It would only turn off

Re: KVM call agenda for Tuesday, July 31

2012-07-31 Thread Stefan Hajnoczi
On Mon, Jul 30, 2012 at 8:34 AM, Juan Quintela wrote: > Please send in any agenda items you are interested in covering. QEMU 1.2 Test Day * Let's find -rc bugs and ensure the release is stable * We've done this in the past and have a wiki template but can discuss suggestions on the call Stefan

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Avi Kivity
On 07/31/2012 03:43 PM, Steven Rostedt wrote: > On Tue, 2012-07-31 at 15:37 +0300, Avi Kivity wrote: >> On 07/31/2012 03:17 PM, Fengguang Wu wrote: >> > >> > It's good to quickly get to the root cause :) Can we possibly detect >> > whether we are in a virtual machine and hence skip this particular

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Steven Rostedt
On Tue, 2012-07-31 at 15:37 +0300, Avi Kivity wrote: > On 07/31/2012 03:17 PM, Fengguang Wu wrote: > > > > It's good to quickly get to the root cause :) Can we possibly detect > > whether we are in a virtual machine and hence skip this particular > > test case? > > cpu_has(&boot_cpu, X86_FEATURE_

Re: How does QEMU communicate with KVM?

2012-07-31 Thread Avi Kivity
On 07/30/2012 08:47 AM, Richard Yao wrote: > Is there any documentation on how QEMU communicates with KVM? > See Documentation/virtual/kvm/api.txt. -- error compiling committee.c: too many arguments to function -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Avi Kivity
On 07/31/2012 03:17 PM, Fengguang Wu wrote: > > It's good to quickly get to the root cause :) Can we possibly detect > whether we are in a virtual machine and hence skip this particular > test case? cpu_has(&boot_cpu, X86_FEATURE_HYPERVISOR) -- error compiling committee.c: too many arguments to

Re: [Qemu-devel] [RFC PATCH] vfio: VFIO PCI driver for Qemu

2012-07-31 Thread Avi Kivity
On 07/31/2012 01:29 AM, Alex Williamson wrote: >> >> If the region size is zero, then both memory_region_del_subregion() >> (assuming the region is parented) and munmap() do nothing. So you could >> call this unconditionally. > > I suppose parenting them is the key. I'm counting on memory_regio

Re: Testing tracer wakeup_rt: .. no entries found ..FAILED!

2012-07-31 Thread Fengguang Wu
[CC kvm developers] On Mon, Jul 30, 2012 at 11:45:05AM -0400, Steven Rostedt wrote: > On Tue, 2012-07-24 at 17:07 +0800, Fengguang Wu wrote: > > On Tue, Jul 24, 2012 at 05:03:30PM +0800, Fengguang Wu wrote: > > > And this warning shows up in one of the dozens of boots, for the same > > kconfig. >

Re: [Qemu-devel] 9p broken?

2012-07-31 Thread Avi Kivity
On 07/31/2012 09:51 AM, Aneesh Kumar K.V wrote: > Avi Kivity writes: > >> Having an annoying bug on i386 kvm I decided to debug it buy running an >> i386 guest on my x86_64 host, use 9p to access a guest image, and run it >> using nested kvm. >> >> However, 9p appears to be broken: first, the con

KVM segfaults with 3.5 while installing ubuntu 12.04

2012-07-31 Thread Stefan Priebe - Profihost AG
Hello list, i hope it is correct to list the maintainers of kvm. While trying to install ubuntu 12.04 amd64 on a kvm based vm the KVM process segfaults while ubuntu tries to detect the HW: kvm[2978]: segfault at 7fb90d9035e0 ip 7fb90d9035e0 sp7fff652e4ed8 error 15 This does not happe

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

2012-07-31 Thread Alexander Graf
On 25.07.2012, at 05:49, Bharat Bhushan wrote: > This patch adds the watchdog emulation in KVM. The watchdog > emulation is enabled by KVM_ENABLE_CAP(KVM_CAP_PPC_BOOKE_WATCHDOG) ioctl. > The kernel timer are used for watchdog emulation and emulates > h/w watchdog state machine. On watchdog timer

[PATCH v3] kvm: Check if smp_cpus exceeds max cpus supported by kvm

2012-07-31 Thread riegamaths
From: Dunrong Huang Add a helper function for fetching max cpus supported by kvm. Make QEMU exit with an error message if smp_cpus exceeds limit of VCPU count retrieved by invoking this helper function. Signed-off-by: Dunrong Huang --- v1 -> v2: * Fix indentation(thanks to Stefan Hajnoczi f

[PATCH v3 8/8] KVM-doc: Add paravirt tlb flush document

2012-07-31 Thread Nikunj A. Dadhania
Signed-off-by: Nikunj A. Dadhania --- Documentation/virtual/kvm/msr.txt|4 ++ Documentation/virtual/kvm/paravirt-tlb-flush.txt | 53 ++ 2 files changed, 57 insertions(+), 0 deletions(-) create mode 100644 Documentation/virtual/kvm/paravirt-tlb-flush.txt

[PATCH v3 7/8] Enable HAVE_RCU_TABLE_FREE for kvm when PARAVIRT_TLB_FLUSH is enabled

2012-07-31 Thread Nikunj A. Dadhania
Signed-off-by: Nikunj A. Dadhania --- arch/x86/Kconfig | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index c70684f..354160d 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@ -612,6 +612,17 @@ config PARAVIRT_SPINLOCK

[PATCH v3 4/8] KVM-HV: Add VCPU running/pre-empted state for guest

2012-07-31 Thread Nikunj A. Dadhania
From: Nikunj A. Dadhania Hypervisor code to indicate guest running/pre-empteded status through msr. The page is now pinned during MSR write time and use kmap_atomic/kunmap_atomic to access the shared area vcpu_state area. Suggested-by: Marcelo Tosatti Signed-off-by: Nikunj A. Dadhania --- arc

[PATCH v3 6/8] KVM-HV: Add flush_on_enter before guest enter

2012-07-31 Thread Nikunj A. Dadhania
From: Nikunj A. Dadhania PV-Flush guest would indicate to flush on enter, flush the TLB before entering and exiting the guest. Signed-off-by: Nikunj A. Dadhania --- arch/x86/kvm/x86.c | 23 +++ 1 files changed, 7 insertions(+), 16 deletions(-) diff --git a/arch/x86/kvm/x

[PATCH v3 5/8] KVM Guest: Add paravirt kvm_flush_tlb_others

2012-07-31 Thread Nikunj A. Dadhania
From: Nikunj A. Dadhania flush_tlb_others_ipi depends on lot of statics in tlb.c. Replicated the flush_tlb_others_ipi as kvm_flush_tlb_others to further adapt to paravirtualization. Use the vcpu state information inside the kvm_flush_tlb_others to avoid sending ipi to pre-empted vcpus. * Do no

[PATCH v3 2/8] mm: Add missing TLB invalidate to RCU page-table freeing

2012-07-31 Thread Nikunj A. Dadhania
From: Peter Zijlstra For normal systems we need a TLB invalidate before freeing the page-tables, the generic RCU based page-table freeing code lacked this. This is because this code originally came from ppc where the hardware never walks the linux page-tables and thus this invalidate is not requ

[PATCH v3 3/8] KVM Guest: Add VCPU running/pre-empted state for guest

2012-07-31 Thread Nikunj A. Dadhania
From: Nikunj A. Dadhania The patch adds guest code for msr between guest and hypervisor. The msr will export the vcpu running/pre-empted information to the guest from host. This will enable guest to intelligently send ipi to running vcpus and set flag for pre-empted vcpus. This will prevent waiti

[PATCH v3 1/8] mm, x86: Add HAVE_RCU_TABLE_FREE support

2012-07-31 Thread Nikunj A. Dadhania
From: Peter Zijlstra Implements optional HAVE_RCU_TABLE_FREE support for x86. This is useful for things like Xen and KVM where paravirt tlb flush means the software page table walkers like GUP-fast cannot rely on IRQs disabling like regular x86 can. Not for inclusion - is part of PeterZ's "Unif

[PATCH v3 0/8] KVM paravirt remote flush tlb

2012-07-31 Thread Nikunj A. Dadhania
Remote flushing api's does a busy wait which is fine in bare-metal scenario. But with-in the guest, the vcpus might have been pre-empted or blocked. In this scenario, the initator vcpu would end up busy-waiting for a long amount of time. This was discovered in our gang scheduling test and other w

Re: [Qemu-devel] [PATCH v2] kvm: Check if smp_cpus exceeds max cpus supported by kvm

2012-07-31 Thread Dunrong Huang
2012/7/31 Peter Maydell : > On 31 July 2012 11:14, wrote: >> >> @@ -1256,6 +1274,13 @@ int kvm_init(void) >> goto err; >> } >> >> +max_vcpus = kvm_max_vcpus(s); >> +if (smp_cpus > max_vcpus) { >> +fprintf(stderr, "Number of SMP cpus requested (%d) exceeds max cpus >

Re: [regression] virtio net locks up

2012-07-31 Thread Stefan Hajnoczi
On Mon, Jul 30, 2012 at 7:08 PM, Bernd Schubert wrote: > On 07/30/2012 07:33 PM, Bernd Schubert wrote: >> >> Hello Stefan, >> >> Stefan Hajnoczi gmail.com> writes: >>> >>> >>> On Wed, Jan 11, 2012 at 4:18 PM, Bernd Schubert >>> itwm.fraunhofer.de> wrote: On 01/11/2012 05:04 PM, Stefan

Re: [Qemu-devel] [PATCH v2] kvm: Check if smp_cpus exceeds max cpus supported by kvm

2012-07-31 Thread Peter Maydell
On 31 July 2012 11:14, wrote: > > @@ -1256,6 +1274,13 @@ int kvm_init(void) > goto err; > } > > +max_vcpus = kvm_max_vcpus(s); > +if (smp_cpus > max_vcpus) { > +fprintf(stderr, "Number of SMP cpus requested (%d) exceeds max cpus " > +"supported by KVM

[PATCH v2] kvm: Check if smp_cpus exceeds max cpus supported by kvm

2012-07-31 Thread riegamaths
From: Dunrong Huang Add a helper function for fetching max cpus supported by kvm. Make QEMU exit with an error message if smp_cpus exceeds limit of VCPU count retrieved by invoking this helper function. Signed-off-by: Dunrong Huang --- v1 -> v2: * Fix indentation kvm-all.c | 25 +

Re: [Qemu-devel] [PATCH] kvm: Check if smp_cpus exceeds max cpus supported by kvm

2012-07-31 Thread Peter Maydell
On 30 July 2012 19:22, wrote: > +static int kvm_max_vcpus(KVMState *s) > +{ > +int max_vcpus = 4; > +int ret; > +ret = kvm_check_extension(s, KVM_CAP_MAX_VCPUS); > +if (ret) { > +max_vcpus = ret; > +} else { > + ret = kvm_check_extension(s, KVM_CAP_NR_VCPUS); > +

Re: [Qemu-devel] [PATCH] kvm: Check if smp_cpus exceeds max cpus supported by kvm

2012-07-31 Thread Stefan Hajnoczi
On Mon, Jul 30, 2012 at 7:22 PM, wrote: > From: Dunrong Huang > > Add a helper function for fetching max cpus supported by kvm. > > Make QEMU exit with an error message if smp_cpus exceeds limit > of VCPU count retrieved by invoking this helper function. > > Signed-off-by: Dunrong Huang > --- >

Re: qemu-kvm-1.1.0 crashing with kernel 3.5.0-rc6

2012-07-31 Thread Avi Kivity
On 07/31/2012 02:36 AM, Marcelo Tosatti wrote: > On Mon, Jul 30, 2012 at 07:39:31PM +0300, Avi Kivity wrote: >> On 07/30/2012 05:07 PM, Chris Clayton wrote: >> >> >> With kernel 3.5.0 with b2da15ac26a0c00 reverted, I have just had 15 >> clean invocations of vanilla qemu-kvm-1.1.1. So that

Re: [PATCH V3 3/3] virtio-blk: Add bio-based IO path for virtio-blk

2012-07-31 Thread Asias He
On 07/30/2012 09:43 PM, Christoph Hellwig wrote: On Mon, Jul 30, 2012 at 12:43:12PM +0800, Asias He wrote: I think we can add REQ_FLUSH & REQ_FUA support to bio path and that deserves another patch. Adding it is a requirement for merging the code. OK. Will add that. -- Asias -- To unsubscr

Re: [Qemu-devel] 9p broken?

2012-07-31 Thread Aneesh Kumar K.V
Avi Kivity writes: > Having an annoying bug on i386 kvm I decided to debug it buy running an > i386 guest on my x86_64 host, use 9p to access a guest image, and run it > using nested kvm. > > However, 9p appears to be broken: first, the configure test fails (patch > sent). Second, while mount wo