Re: [PATCH v7 3/3] KVM: perf: kvm events analysis tool

2012-08-27 Thread Andrew Jones
On Mon, Aug 27, 2012 at 01:34:36PM -0600, David Ahern wrote: > On 8/27/12 9:53 AM, Andrew Jones wrote: > >On Mon, Aug 27, 2012 at 05:51:46PM +0800, Dong Hao wrote: > > > > > > > >>+struct event_stats { > >>+ u64 count; > >>+ u64 time; > >>+ > >>+ /* used to calculate stddev. */ > >>+ double

[PATCH] Documentation for kvm_stat.

2012-08-27 Thread Bo Yang
Signed-off-by: Bo Yang --- Makefile |9 - kvm_stat.texi | 55 +++ 2 files changed, 63 insertions(+), 1 deletions(-) create mode 100644 kvm_stat.texi diff --git a/Makefile b/Makefile index 1cd5bc8..ee524b0 100644 --- a/Makefi

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

2012-08-27 Thread Hugo
Hi, I have done similar things posted in http://article.gmane.org/gmane.comp.emulators.kvm.devel/95342/match=tracking+guest+writes+ept . However, I found some very weird situations. Basically, in the guest vm, I allocate a chunk of memory (with size of a page) in a user level program. Through a g

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

2012-08-27 Thread Felix
Xiao Guangrong linux.vnet.ibm.com> writes: > > 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 I

Re: [Qemu-devel] [PATCH 4/4] kvm: i386: Add classic PCI device assignment

2012-08-27 Thread Jan Kiszka
Hi Blue, thanks for the review. I addressed most of them, the others a commented below. On 2012-08-27 20:56, Blue Swirl wrote: >> +typedef struct AssignedDevice { >> +PCIDevice dev; >> +PCIHostDeviceAddress host; >> +uint32_t dev_id; >> +uint32_t features; >> +int intpin; >> +

Re: [patch 3/3] KVM: move postcommit flush to x86, as mmio sptes are x86 specific

2012-08-27 Thread Takuya Yoshikawa
On Mon, 27 Aug 2012 16:06:01 -0300 Marcelo Tosatti wrote: > > Any explanation why (old.base_gfn != new.base_gfn) case can be > > omitted? > > (old.base_gfn != new.base_gfn) check covers the cases > > 1. old.base_gfn = 0, new.base_gfn = !0 (slot creation) > > and > > x != 0, y != 0, x != y. >

Reminder: KVM Forum 2012 Call For Participation

2012-08-27 Thread KVM Forum 2012 Program Committee
Just a reminder, the CFP ends this Friday. -- = KVM Forum 2012: Call For Participation November 7-9, 2012 - Hotel Fira Palace - Barcelona, Spain (All submissions must be received before midnight Aug 31st, 2012) ==

KVM call agenda for Tuesda, August 28th

2012-08-27 Thread Juan Quintela
Hi Please send in any agenda items you are interested in covering. Thanks, Juan. -- 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 http://vger.kernel.org/majordomo-info.html

Re: /dev/kvm not sufficiently restricted, and in ways I didn't think were possible

2012-08-27 Thread Neal Murphy
On Monday, August 27, 2012 04:11:11 PM Henry Cejtin wrote: > I'm completely confused about access to /dev/kvm. In particular, it > looks like it is too open to access, but in a way that I don't > understand. > > On my machine, /dev/kvm is owned by root.root and mode 660. Here is th

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Michael Wolf
On Mon, 2012-08-27 at 14:41 -0700, Glauber Costa wrote: > On 08/27/2012 02:27 PM, Michael Wolf wrote: > > On Mon, 2012-08-27 at 13:31 -0700, Avi Kivity wrote: > >> On 08/27/2012 01:23 PM, Michael Wolf wrote: > > How would a guest know what its entitlement is? > > > >>> > >>> Cur

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Avi Kivity
On 08/27/2012 02:27 PM, Michael Wolf wrote: > On Mon, 2012-08-27 at 13:31 -0700, Avi Kivity wrote: > > On 08/27/2012 01:23 PM, Michael Wolf wrote: > > > > > > > > How would a guest know what its entitlement is? > > > > > > > > > > > > > > Currently the Admin/management tool setting up the guests

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Glauber Costa
On 08/27/2012 02:27 PM, Michael Wolf wrote: > On Mon, 2012-08-27 at 13:31 -0700, Avi Kivity wrote: >> On 08/27/2012 01:23 PM, Michael Wolf wrote: How would a guest know what its entitlement is? >>> >>> Currently the Admin/management tool setting up the guests will put it on >>>

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Michael Wolf
On Mon, 2012-08-27 at 13:31 -0700, Avi Kivity wrote: > On 08/27/2012 01:23 PM, Michael Wolf wrote: > > > > > > How would a guest know what its entitlement is? > > > > > > > > > > Currently the Admin/management tool setting up the guests will put it on > > the qemu commandline. From this it is p

Re: [PATCH for-3.6] kvm: fix KVM_GET_MSR for PV EOI

2012-08-27 Thread Marcelo Tosatti
On Mon, Aug 27, 2012 at 05:47:42PM -0300, Marcelo Tosatti wrote: > On Sun, Aug 26, 2012 at 06:00:29PM +0300, Michael S. Tsirkin wrote: > > KVM_GET_MSR was missing support for PV EOI, > > which is needed for migration. > > > > Signed-off-by: Michael S. Tsirkin > > --- > > > > Please consider this

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Glauber Costa
On 08/27/2012 01:19 PM, Michael Wolf wrote: > On Mon, 2012-08-27 at 11:50 -0700, Glauber Costa wrote: >> On 08/27/2012 08:50 AM, Michael Wolf wrote: >>> On Sat, 2012-08-25 at 19:36 -0400, Glauber Costa wrote: On 08/24/2012 11:11 AM, Michael Wolf wrote: > On Fri, 2012-08-24 at 08:53 +0400,

Re: setting time in guest with ntpdate results in VM hang

2012-08-27 Thread Marcelo Tosatti
On Mon, Aug 27, 2012 at 01:23:05PM -0600, David Ahern wrote: > On 8/27/12 10:58 AM, Dale Swanston wrote: > >Good idea. I'll try that. > > > >But are there any tools available to determine what the VM is doing when > >it appears hung? I've looked but haven't found much on debug or > >diagnostics o

Re: [PATCH] KVM: x86: lapic: Fix the misuse of likely() in find_highest_vector()

2012-08-27 Thread Marcelo Tosatti
On Fri, Aug 24, 2012 at 06:15:49PM +0900, Takuya Yoshikawa wrote: > Although returning -1 should be likely according to the likely(), > the ASSERT in apic_find_highest_irr() will be triggered in such a case. > It seems that this optimization is not working as expected. > > This patch simplifies th

Re: [PATCH v2] kvm/book3s: fix build error caused by gfn_to_hva_memslot()

2012-08-27 Thread Marcelo Tosatti
On Fri, Aug 24, 2012 at 07:03:14PM +1000, Paul Mackerras wrote: > On Fri, Aug 24, 2012 at 04:50:28PM +0800, Gavin Shan wrote: > > The build error was caused by that builtin functions are calling > > the functions implemented in modules. That was introduced by the > > following commit. > > > > comm

Re: [PATCH RFC 1/2] KVM: PPC: Move kvm->arch.slot_phys into memslot.arch

2012-08-27 Thread Marcelo Tosatti
On Sat, Aug 25, 2012 at 10:40:40PM +1000, Paul Mackerras wrote: > Now that we have an architecture-specific field in the kvm_memory_slot > structure, we can use it to store the array of page physical addresses > that we need for Book3S HV KVM on PPC970 processors. This reduces the > size of struct

Re: [PATCH for-3.6] kvm: fix KVM_GET_MSR for PV EOI

2012-08-27 Thread Marcelo Tosatti
On Sun, Aug 26, 2012 at 06:00:29PM +0300, Michael S. Tsirkin wrote: > KVM_GET_MSR was missing support for PV EOI, > which is needed for migration. > > Signed-off-by: Michael S. Tsirkin > --- > > Please consider this bugfix patch for 3.6. > Thanks! > > arch/x86/kvm/x86.c | 3 +++ > 1 file chang

Re: [PATCH v3] KVM: x86 emulator: access GPRs on demand

2012-08-27 Thread Marcelo Tosatti
On Mon, Aug 27, 2012 at 01:22:55PM -0700, Avi Kivity wrote: > On 08/26/2012 10:04 AM, Marcelo Tosatti wrote: > > On Thu, Aug 23, 2012 at 05:14:27AM -0300, Marcelo Tosatti wrote: > > > On Sun, Aug 19, 2012 at 12:32:36PM +0300, Avi Kivity wrote: > > > > On 08/17/2012 08:29 PM, Marcelo Tosatti wrote:

Re: [PATCH v3] KVM: x86 emulator: access GPRs on demand

2012-08-27 Thread Marcelo Tosatti
On Mon, Aug 27, 2012 at 05:53:32PM -0300, Marcelo Tosatti wrote: > With the fix, it rejects. About to merge the big real mode > patchset, so its not a bad idea to wait for that before > resending. Nevermind this sentence. -- To unsubscribe from this list: send the line "unsubscribe kvm" in the b

[PATCH v4] KVM: x86 emulator: access GPRs on demand

2012-08-27 Thread Avi Kivity
Instead of populating the the entire register file, read in registers as they are accessed, and write back only the modified ones. This saves a VMREAD and VMWRITE on Intel (for rsp, since it is not usually used during emulation), and a two 128-byte copies for the registers. Signed-off-by: Avi Kiv

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Avi Kivity
On 08/27/2012 01:23 PM, Michael Wolf wrote: > > > > How would a guest know what its entitlement is? > > > > > > Currently the Admin/management tool setting up the guests will put it on > the qemu commandline. From this it is passed via an ioctl to the host. > The guest will get the value from t

Re: [PATCH v3] KVM: x86 emulator: access GPRs on demand

2012-08-27 Thread Avi Kivity
On 08/27/2012 01:22 PM, Avi Kivity wrote: > On 08/26/2012 10:04 AM, Marcelo Tosatti wrote: > > On Thu, Aug 23, 2012 at 05:14:27AM -0300, Marcelo Tosatti wrote: > > > On Sun, Aug 19, 2012 at 12:32:36PM +0300, Avi Kivity wrote: > > > > On 08/17/2012 08:29 PM, Marcelo Tosatti wrote: > > > > > On Thu,

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Michael Wolf
On Mon, 2012-08-27 at 11:55 -0700, Avi Kivity wrote: > On 08/23/2012 04:14 PM, Michael Wolf wrote: > > This is an RFC regarding the reporting of stealtime. In the case of > > where you have a system that is running with partial processors such as > > KVM the user may see steal time being reported

Re: [PATCH v3] KVM: x86 emulator: access GPRs on demand

2012-08-27 Thread Avi Kivity
On 08/26/2012 10:04 AM, Marcelo Tosatti wrote: > On Thu, Aug 23, 2012 at 05:14:27AM -0300, Marcelo Tosatti wrote: > > On Sun, Aug 19, 2012 at 12:32:36PM +0300, Avi Kivity wrote: > > > On 08/17/2012 08:29 PM, Marcelo Tosatti wrote: > > > > On Thu, Aug 16, 2012 at 05:54:49PM +0300, Avi Kivity wrote:

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Michael Wolf
On Mon, 2012-08-27 at 11:50 -0700, Glauber Costa wrote: > On 08/27/2012 08:50 AM, Michael Wolf wrote: > > On Sat, 2012-08-25 at 19:36 -0400, Glauber Costa wrote: > >> On 08/24/2012 11:11 AM, Michael Wolf wrote: > >>> On Fri, 2012-08-24 at 08:53 +0400, Glauber Costa wrote: > On 08/24/2012 03:14

Re: /dev/kvm not sufficiently restricted, and in ways I didn't think were possible

2012-08-27 Thread Avi Kivity
On 08/27/2012 01:11 PM, Henry Cejtin wrote: > I'm completely confused about access to /dev/kvm. In particular, it > looks like it is too open to access, but in a way that I don't > understand. > > On my machine, /dev/kvm is owned by root.root and mode 660. Here is the > output of ls

/dev/kvm not sufficiently restricted, and in ways I didn't think were possible

2012-08-27 Thread Henry Cejtin
I'm completely confused about access to /dev/kvm. In particular, it looks like it is too open to access, but in a way that I don't understand. On my machine, /dev/kvm is owned by root.root and mode 660. Here is the output of ls: % ls -l /dev/kvm crw-rw+ 1 root root 10,

Re: [Qemu-devel] [PATCHv2 3/4] cpuid: disable pv eoi for 1.1 and older compat types

2012-08-27 Thread Blue Swirl
On Mon, Aug 27, 2012 at 7:24 PM, Michael S. Tsirkin wrote: > On Mon, Aug 27, 2012 at 07:12:27PM +, Blue Swirl wrote: >> On Mon, Aug 27, 2012 at 7:06 PM, Michael S. Tsirkin wrote: >> > On Mon, Aug 27, 2012 at 06:58:29PM +, Blue Swirl wrote: >> >> On Mon, Aug 27, 2012 at 12:20 PM, Michael S

Re: [PATCH v7 3/3] KVM: perf: kvm events analysis tool

2012-08-27 Thread David Ahern
On 8/27/12 9:53 AM, Andrew Jones wrote: On Mon, Aug 27, 2012 at 05:51:46PM +0800, Dong Hao wrote: +struct event_stats { + u64 count; + u64 time; + + /* used to calculate stddev. */ + double mean; + double M2; +}; How about moving the stats functions from builti

Re: [Qemu-devel] [PATCHv2 3/4] cpuid: disable pv eoi for 1.1 and older compat types

2012-08-27 Thread Michael S. Tsirkin
On Mon, Aug 27, 2012 at 07:12:27PM +, Blue Swirl wrote: > On Mon, Aug 27, 2012 at 7:06 PM, Michael S. Tsirkin wrote: > > On Mon, Aug 27, 2012 at 06:58:29PM +, Blue Swirl wrote: > >> On Mon, Aug 27, 2012 at 12:20 PM, Michael S. Tsirkin > >> wrote: > >> > In preparation for adding PV EOI s

Re: setting time in guest with ntpdate results in VM hang

2012-08-27 Thread David Ahern
On 8/27/12 10:58 AM, Dale Swanston wrote: Good idea. I'll try that. But are there any tools available to determine what the VM is doing when it appears hung? I've looked but haven't found much on debug or diagnostics on a running VM. Any links? If you have the vmlinux, enable the gdbserver

Re: [PATCHv2] kvm: Fix nonsense handling of compat ioctl

2012-08-27 Thread Marcelo Tosatti
On Wed, Aug 22, 2012 at 02:34:11PM +0100, Alan Cox wrote: > From: Alan Cox > > KVM_SET_SIGNAL_MASK passed a NULL argument leaves the on stack signal > sets uninitialized. It then passes them through to > kvm_vcpu_ioctl_set_sigmask. > > We should be passing a NULL in this case not translated garb

Re: [patch 3/3] KVM: move postcommit flush to x86, as mmio sptes are x86 specific

2012-08-27 Thread Marcelo Tosatti
On Mon, Aug 27, 2012 at 11:41:08PM +0900, Takuya Yoshikawa wrote: > On Fri, 24 Aug 2012 15:54:59 -0300 > Marcelo Tosatti wrote: > > > Other arches do not need this. > > > > Signed-off-by: Marcelo Tosatti > > > > Index: kvm/arch/x86/kvm/x86.c > >

Re: [Qemu-devel] [PATCHv2 3/4] cpuid: disable pv eoi for 1.1 and older compat types

2012-08-27 Thread Blue Swirl
On Mon, Aug 27, 2012 at 7:06 PM, Michael S. Tsirkin wrote: > On Mon, Aug 27, 2012 at 06:58:29PM +, Blue Swirl wrote: >> On Mon, Aug 27, 2012 at 12:20 PM, Michael S. Tsirkin wrote: >> > In preparation for adding PV EOI support, disable PV EOI by default for >> > 1.1 and older machine types, to

Re: [Qemu-devel] [PATCH 4/4] kvm: i386: Add classic PCI device assignment

2012-08-27 Thread Blue Swirl
On Mon, Aug 27, 2012 at 7:01 PM, Michael S. Tsirkin wrote: > On Mon, Aug 27, 2012 at 06:56:38PM +, Blue Swirl wrote: >> > +static uint32_t slow_bar_readb(void *opaque, target_phys_addr_t addr) >> > +{ >> > +AssignedDevRegion *d = opaque; >> > +uint8_t *in = d->u.r_virtbase + addr; >> >

Re: [Qemu-devel] [PATCHv2 3/4] cpuid: disable pv eoi for 1.1 and older compat types

2012-08-27 Thread Blue Swirl
On Mon, Aug 27, 2012 at 12:20 PM, Michael S. Tsirkin wrote: > In preparation for adding PV EOI support, disable PV EOI by default for > 1.1 and older machine types, to avoid CPUID changing during migration. > > PV EOI can still be enabled/disabled by specifying it explicitly. > Enable for 1.1

Re: [Qemu-devel] [PATCHv2 3/4] cpuid: disable pv eoi for 1.1 and older compat types

2012-08-27 Thread Michael S. Tsirkin
On Mon, Aug 27, 2012 at 06:58:29PM +, Blue Swirl wrote: > On Mon, Aug 27, 2012 at 12:20 PM, Michael S. Tsirkin wrote: > > In preparation for adding PV EOI support, disable PV EOI by default for > > 1.1 and older machine types, to avoid CPUID changing during migration. > > > > PV EOI can still

Re: [Qemu-devel] [PATCH 4/4] kvm: i386: Add classic PCI device assignment

2012-08-27 Thread Michael S. Tsirkin
On Mon, Aug 27, 2012 at 06:56:38PM +, Blue Swirl wrote: > > +static uint32_t slow_bar_readb(void *opaque, target_phys_addr_t addr) > > +{ > > +AssignedDevRegion *d = opaque; > > +uint8_t *in = d->u.r_virtbase + addr; > > Don't perform arithmetic with void pointers. Why not? We require

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Avi Kivity
On 08/23/2012 04:14 PM, Michael Wolf wrote: > This is an RFC regarding the reporting of stealtime. In the case of > where you have a system that is running with partial processors such as > KVM the user may see steal time being reported in accounting tools such > as top or vmstat. This can cause

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Glauber Costa
On 08/27/2012 08:50 AM, Michael Wolf wrote: > On Sat, 2012-08-25 at 19:36 -0400, Glauber Costa wrote: >> On 08/24/2012 11:11 AM, Michael Wolf wrote: >>> On Fri, 2012-08-24 at 08:53 +0400, Glauber Costa wrote: On 08/24/2012 03:14 AM, Michael Wolf wrote: > This is an RFC regarding the report

Re: [Qemu-devel] [PATCHv2 1/4] linux-headers: update to 3.6-rc3

2012-08-27 Thread Michael S. Tsirkin
On Mon, Aug 27, 2012 at 04:59:40PM +0200, Jan Kiszka wrote: > On 2012-08-27 16:53, Michael S. Tsirkin wrote: > > On Mon, Aug 27, 2012 at 02:48:57PM +0200, Jan Kiszka wrote: > >> On 2012-08-27 14:42, Peter Maydell wrote: > >>> On 27 August 2012 13:20, Michael S. Tsirkin wrote: > Update linux-h

Re: setting time in guest with ntpdate results in VM hang

2012-08-27 Thread Dale Swanston
On 8/24/2012 1:43 PM, Marcelo Tosatti wrote: On Fri, Aug 24, 2012 at 09:57:35AM -0600, Dale Swanston wrote: Hello. We are running a guest OS of CentOS 4.4 (kernel 2.6.12) for legacy reasons, upgrading is not an option. NTP is running on the host and synching with a local GPS NTP server. But

Re: [PATCH v7 3/3] KVM: perf: kvm events analysis tool

2012-08-27 Thread Andrew Jones
On Mon, Aug 27, 2012 at 05:51:46PM +0800, Dong Hao wrote: > +struct event_stats { > + u64 count; > + u64 time; > + > + /* used to calculate stddev. */ > + double mean; > + double M2; > +}; How about moving the stats functions from builtin-stat.c to e.g. util/stats.c, and the

Re: [PATCH RFC 0/3] Add guest cpu_entitlement reporting

2012-08-27 Thread Michael Wolf
On Sat, 2012-08-25 at 19:36 -0400, Glauber Costa wrote: > On 08/24/2012 11:11 AM, Michael Wolf wrote: > > On Fri, 2012-08-24 at 08:53 +0400, Glauber Costa wrote: > >> On 08/24/2012 03:14 AM, Michael Wolf wrote: > >>> This is an RFC regarding the reporting of stealtime. In the case of > >>> where y

Re: [Qemu-devel] [PATCHv2 1/4] linux-headers: update to 3.6-rc3

2012-08-27 Thread Jan Kiszka
On 2012-08-27 16:53, Michael S. Tsirkin wrote: > On Mon, Aug 27, 2012 at 02:48:57PM +0200, Jan Kiszka wrote: >> On 2012-08-27 14:42, Peter Maydell wrote: >>> On 27 August 2012 13:20, Michael S. Tsirkin wrote: Update linux-headers to version present in Linux 3.6-rc3. Header asm-x96_64/kvm

Re: [Qemu-devel] [PATCHv2 1/4] linux-headers: update to 3.6-rc3

2012-08-27 Thread Michael S. Tsirkin
On Mon, Aug 27, 2012 at 02:48:57PM +0200, Jan Kiszka wrote: > On 2012-08-27 14:42, Peter Maydell wrote: > > On 27 August 2012 13:20, Michael S. Tsirkin wrote: > >> Update linux-headers to version present in Linux 3.6-rc3. > >> Header asm-x96_64/kvm_para.h update is needed for the new PV EOI > >> f

Re: [Qemu-devel] [PATCHv2 1/4] linux-headers: update to 3.6-rc3

2012-08-27 Thread Michael S. Tsirkin
On Mon, Aug 27, 2012 at 01:42:03PM +0100, Peter Maydell wrote: > On 27 August 2012 13:20, Michael S. Tsirkin wrote: > > Update linux-headers to version present in Linux 3.6-rc3. > > Header asm-x96_64/kvm_para.h update is needed for the new PV EOI > > feature. > > > > Signed-off-by: Michael S. Tsir

Re: [patch 3/3] KVM: move postcommit flush to x86, as mmio sptes are x86 specific

2012-08-27 Thread Takuya Yoshikawa
On Fri, 24 Aug 2012 15:54:59 -0300 Marcelo Tosatti wrote: > Other arches do not need this. > > Signed-off-by: Marcelo Tosatti > > Index: kvm/arch/x86/kvm/x86.c > === > --- kvm.orig/arch/x86/kvm/x86.c > +++ kvm/arch/x86/kvm/x86.c >

Re: [PATCH v7 0/3] KVM: perf: kvm events analysis tool

2012-08-27 Thread David Ahern
On 8/27/12 3:59 AM, Xiao Guangrong wrote: CC David. Hi David, I should apologize to you that Dong forgot to post the patchset to you. Could you pick these up from the mail list? Yes, I do catch all perf related emails to LKML. I'll take a look at the patches today or tomorrow. David -- To

Re: [Qemu-devel] [PATCHv2 1/4] linux-headers: update to 3.6-rc3

2012-08-27 Thread Jan Kiszka
On 2012-08-27 14:42, Peter Maydell wrote: > On 27 August 2012 13:20, Michael S. Tsirkin wrote: >> Update linux-headers to version present in Linux 3.6-rc3. >> Header asm-x96_64/kvm_para.h update is needed for the new PV EOI >> feature. >> >> Signed-off-by: Michael S. Tsirkin >> --- >> linux-head

Re: [Qemu-devel] [PATCHv2 1/4] linux-headers: update to 3.6-rc3

2012-08-27 Thread Peter Maydell
On 27 August 2012 13:20, Michael S. Tsirkin wrote: > Update linux-headers to version present in Linux 3.6-rc3. > Header asm-x96_64/kvm_para.h update is needed for the new PV EOI > feature. > > Signed-off-by: Michael S. Tsirkin > --- > linux-headers/asm-s390/kvm.h | 2 +- > linux-headers/asm

[PATCHv2 4/4] kvm: get/set PV EOI MSR

2012-08-27 Thread Michael S. Tsirkin
Support get/set of new PV EOI MSR, for migration. Add an optional section for MSR value - send it out in case MSR was changed from the default value (0). Signed-off-by: Michael S. Tsirkin --- target-i386/cpu.h | 1 + target-i386/kvm.c | 13 + target-i386/machine.c | 21 +

[PATCHv2 3/4] cpuid: disable pv eoi for 1.1 and older compat types

2012-08-27 Thread Michael S. Tsirkin
In preparation for adding PV EOI support, disable PV EOI by default for 1.1 and older machine types, to avoid CPUID changing during migration. PV EOI can still be enabled/disabled by specifying it explicitly. Enable for 1.1 -M pc-1.1 -cpu kvm64,+kvm_pv_eoi Disable for 1.2 -M pc-1.2

[PATCHv2 2/4] pc: refactor compat code

2012-08-27 Thread Michael S. Tsirkin
In preparation to adding PV EOI migration for 1.2, trivially refactor some some compat code to make it easier to add version specific cpuid tweaks. Signed-off-by: Michael S. Tsirkin --- hw/pc_piix.c | 44 1 file changed, 36 insertions(+), 8 deletions(

[PATCHv2 1/4] linux-headers: update to 3.6-rc3

2012-08-27 Thread Michael S. Tsirkin
Update linux-headers to version present in Linux 3.6-rc3. Header asm-x96_64/kvm_para.h update is needed for the new PV EOI feature. Signed-off-by: Michael S. Tsirkin --- linux-headers/asm-s390/kvm.h | 2 +- linux-headers/asm-s390/kvm_para.h | 2 +- linux-headers/asm-x86/kvm.h | 1 + l

[PATCHv2 0/4] migrate PV EOI MSR

2012-08-27 Thread Michael S. Tsirkin
It turns out PV EOI gets disabled after migration - until next guest reset. This is because we are missing code to actually migrate it. This patch fixes it up: it applies cleanly to qemu.git as well as qemu-kvm.git, so I think it's cleaner to apply it in qemu.git to keep diff to minimum. Note: the

Re: [Qemu-devel] [PATCH 4/4] kvm: i386: Add classic PCI device assignment

2012-08-27 Thread Jan Kiszka
On 2012-08-27 14:07, Andreas Färber wrote: > Hi, > > Am 27.08.2012 08:28, schrieb Jan Kiszka: >> From: Jan Kiszka >> >> This adds PCI device assignment for i386 targets using the classic KVM >> interfaces. This version is 100% identical to what is being maintained >> in qemu-kvm for several years

Re: [Qemu-devel] [PATCH 4/4] kvm: i386: Add classic PCI device assignment

2012-08-27 Thread Andreas Färber
Hi, Am 27.08.2012 08:28, schrieb Jan Kiszka: > From: Jan Kiszka > > This adds PCI device assignment for i386 targets using the classic KVM > interfaces. This version is 100% identical to what is being maintained > in qemu-kvm for several years and is supported by libvirt as well. It is > expecte

Re: [PATCH v7 0/3] KVM: perf: kvm events analysis tool

2012-08-27 Thread Xiao Guangrong
CC David. Hi David, I should apologize to you that Dong forgot to post the patchset to you. Could you pick these up from the mail list? On 08/27/2012 05:51 PM, Dong Hao wrote: > From: Xiao Guangrong > > Changelog: > - rebased it on Arnaldo's newest git tree perf/core branch > > the change fro

[PATCH v7 3/3] KVM: perf: kvm events analysis tool

2012-08-27 Thread Dong Hao
From: Xiao Guangrong Add 'perf kvm stat' support to analyze kvm vmexit/mmio/ioport smartly Usage: - kvm stat run a command and gather performance counter statistics, it is the alias of perf stat - trace kvm events: perf kvm stat record, or, if other tracepoints are interesting as well, we

[PATCH v7 2/3] KVM: x86: trace mmio begin and complete

2012-08-27 Thread Dong Hao
From: Xiao Guangrong 'perf kvm stat record/report' will use kvm_exit and kvm_mmio(read...) to calculate mmio read emulated time for the old kernel, in order to trace mmio read event more exactly, we add kvm_mmio_begin to trace the time when mmio read begins, also, add kvm_io_done to trace the tim

[PATCH v7 1/3] KVM: x86: export svm/vmx exit code and vector code to userspace

2012-08-27 Thread Dong Hao
From: Xiao Guangrong Exporting KVM exit information to userspace to be consumed by perf. [ Dong Hao : rebase it on acme's git tree ] Signed-off-by: Xiao Guangrong Signed-off-by: Dong Hao --- arch/x86/include/asm/kvm_host.h | 36 --- arch/x86/include/asm/svm.h | 205 +++

[PATCH v7 0/3] KVM: perf: kvm events analysis tool

2012-08-27 Thread Dong Hao
From: Xiao Guangrong Changelog: - rebased it on Arnaldo's newest git tree perf/core branch the change from Arnaldo's comments: - directly get event from evsel->tp_format - remove die() and return the proper error code - rename thread->private to thread->priv the change from David's comments: -

Re: Question: Timekeeping between Host and Guest with NTP

2012-08-27 Thread Aritoki TAKADA
Hello, (2012/08/25 0:00), Marcelo Tosatti wrote: kvmclock driver has access to the ntpd corrected frequency of the host, but: 1) kvmclock time as reported to the guest uses the TSC as an offset in addition to the host monotonic clock, TSC is susceptible to frequency variations. The guest has

Re: registering ioeventfd in qemu/kvm

2012-08-27 Thread Paolo Bonzini
Il 23/08/2012 05:35, Shesha Sreenivasamurthy ha scritto: > Hi, > I am trying to generate eventfd upon a IO write from the guest, say it > is at offset IO_NOTIFY_REG (0x10). When the guest writes to this > register, I get control to QEMU's to the write function associated in > mypci_iomem_ops. Howev

Re: [patch 3/3] KVM: move postcommit flush to x86, as mmio sptes are x86 specific

2012-08-27 Thread Xiao Guangrong
On 08/25/2012 02:54 AM, Marcelo Tosatti wrote: > Other arches do not need this. > > Signed-off-by: Marcelo Tosatti > > Index: kvm/arch/x86/kvm/x86.c > === > --- kvm.orig/arch/x86/kvm/x86.c > +++ kvm/arch/x86/kvm/x86.c > @@ -6455,6 +

Export offsets of VMCS fields as note information for kdump

2012-08-27 Thread Zhang Yanfei
Hello Avi, About this VMCSINFO patch, we really need this functionality in our development. And YOSHIDA Masanori(masanori.yoshida...@hitachi.com), the developer from Hitachi, has said they need this too. So could you please tell us why the patch is unacceptable? You dislike the whole export-VMCS