Add unit test for basic functionality of PCID/INVPCID feature exposing in kvm.
Changes from v1:
Hard code 'invpcid' instruction
Signed-off-by: Junjie Mao
---
config-x86-common.mak |2 +
config-x86_64.mak |3 +-
x86/README|1 +
x86/pcid.c| 185 +++
This patch handles PCID/INVPCID for guests.
Process-context identifiers (PCIDs) are a facility by which a logical processor
may cache information for multiple linear-address spaces so that the processor
may retain cached information when software switches to a different linear
address space. Refer
Alexander,
Is that any better? :)
@@ -1779,11 +1779,29 @@ static void pci_del_option_rom(PCIDevice *pdev)
* in pci config space */
int pci_add_capability(PCIDevice *pdev, uint8_t cap_id,
uint8_t offset, uint8_t size)
{
-uint8_t *config;
+uint8_t *config, exist
On Wed, May 16, 2012 at 02:31:37PM +0300, Avi Kivity wrote:
> Signed-off-by: Avi Kivity
> ---
> scripts/kvm/vmxcap | 13 +
> 1 file changed, 13 insertions(+)
Applied to uq/master, thanks.
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to
On Wed, May 16, 2012 at 09:12:30AM +0800, Xudong Hao wrote:
> Enabling Access bit when doing memory swapping.
>
> Signed-off-by: Haitao Shan
> Signed-off-by: Xudong Hao
> ---
> arch/x86/kvm/mmu.c | 13 +++--
> arch/x86/kvm/vmx.c |6 --
> 2 files changed, 11 insertions(+), 8 de
On Tue, May 15, 2012 at 09:57:20AM -0300, Jan Kiszka wrote:
> Removes two unused KVM core functions and some unneeded diffs in
> msi/msix.c.
>
> Jan Kiszka (4):
> qemu-kvm: Drop unused kvm_clear_gsi_routes
> qemu-kvm: Drop unused kvm_del_irq_route
> qemu-kvm: msi: Drop redundant support test
There is some brief documentation on top of each trace entry definition
in the arch/x86/kvm/trace.h file, in the kernel source code.
http://git.kernel.org/?p=virt/kvm/kvm.git;a=blob;f=arch/x86/kvm/trace.h;h=911d2641f14c5cba355abc25e00f38f07ced1df9;hb=refs/heads/next-candidate
There is an exact m
On Tue, May 15, 2012 at 02:15:24PM +0200, Christian Borntraeger wrote:
> Avi, Marcelo,
>
> here are 4 feature patches for kvm-s390. One patch deals with
> the memory management of kvm and allows MAP_PRIVATE. The other
> patches implement user space access for some missing registers
> via the ONE_
On Mon, May 14, 2012 at 06:25:42AM +, Mao, Junjie wrote:
> Add unit test for basic functionality of PCID/INVPCID feature exposing in kvm.
>
> Signed-off-by: Junjie Mao
> ---
> config-x86-common.mak |2 +
> config-x86_64.mak |3 +-
> x86/README|1 +
> x86/pcid.c
On 05/17/2012 04:03 PM, Alexander Graf wrote:
>
> On 17.05.2012, at 22:58, Scott Wood wrote:
>
>> On 05/17/2012 03:56 PM, Alexander Graf wrote:
>>>
>>> On 17.05.2012, at 18:37, Scott Wood wrote:
>>>
On 05/16/2012 08:25 AM, Alexander Graf wrote:
> When reinjecting host interrupt requests
On 17.05.2012, at 22:58, Scott Wood wrote:
> On 05/17/2012 03:56 PM, Alexander Graf wrote:
>>
>> On 17.05.2012, at 18:37, Scott Wood wrote:
>>
>>> On 05/16/2012 08:25 AM, Alexander Graf wrote:
When reinjecting host interrupt requests in the exit handler code,
let's also tell the inter
On 05/17/2012 03:56 PM, Alexander Graf wrote:
>
> On 17.05.2012, at 18:37, Scott Wood wrote:
>
>> On 05/16/2012 08:25 AM, Alexander Graf wrote:
>>> When reinjecting host interrupt requests in the exit handler code,
>>> let's also tell the interrupt handler which interrupt number we're
>>> coming
https://bugzilla.kernel.org/show_bug.cgi?id=42980
--- Comment #9 from Luke-Jr 2012-05-17
20:58:50 ---
The while/ping thing doesn't reproduce it even before the patch. :(
--
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
--- You are receiving this mail because:
On 17.05.2012, at 18:37, Scott Wood wrote:
> On 05/16/2012 08:25 AM, Alexander Graf wrote:
>> When reinjecting host interrupt requests in the exit handler code,
>> let's also tell the interrupt handler which interrupt number we're
>> coming from.
>>
>> Signed-off-by: Alexander Graf
>> ---
>> ar
On Thu, May 17, 2012 at 10:14:35PM +0200, Sasha Levin wrote:
> On Thu, May 17, 2012 at 10:05 PM, Gleb Natapov wrote:
> > On Thu, May 17, 2012 at 09:49:08PM +0200, Sasha Levin wrote:
> >> Hi all,
> >>
> >> I've observed a guest hang after putting a little stress testing on
> >> it. It basically han
On Thu, May 17, 2012 at 10:05 PM, Gleb Natapov wrote:
> On Thu, May 17, 2012 at 09:49:08PM +0200, Sasha Levin wrote:
>> Hi all,
>>
>> I've observed a guest hang after putting a little stress testing on
>> it. It basically hangs in ~10 secs after running several trinity
>> instances inside a KVM to
On Thu, May 17, 2012 at 09:49:08PM +0200, Sasha Levin wrote:
> Hi all,
>
> I've observed a guest hang after putting a little stress testing on
> it. It basically hangs in ~10 secs after running several trinity
> instances inside a KVM tools guest.
>
And do you set hypervisor bit in KVM tool?
> T
Hi all,
I've observed a guest hang after putting a little stress testing on
it. It basically hangs in ~10 secs after running several trinity
instances inside a KVM tools guest.
The hang is easy to describe and reproduce:
1. No userspace exits observed
2. kvm_stat looks as follows (with all other
On Thu, May 17, 2012 at 11:36:24PM +0530, Jaspal wrote:
> Hi ,
>
> Is it possible to keep a count of reads / writes taking place in a
> vm using qemu ( using kvm as hypervisor ) ? Is there a api ( or any
> patch ) for it ?
Memory reads and writes is surely going to generate a huge
amount of outpu
Hi ,
Is it possible to keep a count of reads / writes taking place in a vm
using qemu ( using kvm as hypervisor ) ? Is there a api ( or any patch )
for it ?
Thanks ,
Jaspal
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majord...@vger.kernel.org
On Thu, May 17, 2012 at 10:56:36AM -0600, Eric Blake wrote:
> On 05/17/2012 10:26 AM, Eduardo Habkost wrote:
>
> > The problem is that this makes the resulting CPU feature flags
> > unpredictable and dependent on the host CPU and kernel version. This
> > breaks live-migration badly if migrating fr
On 05/17/2012 10:26 AM, Eduardo Habkost wrote:
> The problem is that this makes the resulting CPU feature flags
> unpredictable and dependent on the host CPU and kernel version. This
> breaks live-migration badly if migrating from a host CPU that supports
> some features on that CPUID leaf (runnin
On 05/16/2012 08:25 AM, Alexander Graf wrote:
> When reinjecting host interrupt requests in the exit handler code,
> let's also tell the interrupt handler which interrupt number we're
> coming from.
>
> Signed-off-by: Alexander Graf
> ---
> arch/powerpc/kvm/booke.c | 12 +++-
> 1 files
Changes v1 -> v2:
- Use kvm_arch_get_supported_cpuid() instead of host_cpuid() on
cpu_x86_fill_host().
We should use GET_SUPPORTED_CPUID for all bits on "-cpu host"
eventually, but I am not changing all the other CPUID leaves because
we may not be able to test such an intrusive change
On Thu, 2012-05-17 at 15:19 +0800, Anonymous wrote:
> Alex,
>
> On Sat, May 12, 2012 at 6:55 AM, Alex Williamson
> wrote:
> > Integrating IOMMU groups more closely into the driver core allows
> > us to more easily work around DMA quirks. The Ricoh multifunction
> > controller is a favorite examp
On Thu, May 17, 2012 at 02:37:21AM +, Mao, Junjie wrote:
> > > You can disable INVPCID exec control (which #UDs), if its in Level-2
> > > guest mode (see if_guest_mode()), and restore the Level-1 value when
> > > leaving nested mode.
> >
> > This "!cpu_has_hypervisor " is brought by my ignoran
From: Jan Kiszka
We will add kvm_irqchip_add_msi_route, so let's make the difference
clearer.
Signed-off-by: Jan Kiszka
---
hw/pc_piix.c |8
kvm-all.c|2 +-
kvm.h|2 +-
3 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/hw/pc_piix.c b/hw/pc_piix.c
i
From: Jan Kiszka
This allows to drop routes created by kvm_irqchip_add_irq/msi_route
again.
Signed-off-by: Jan Kiszka
---
kvm-all.c |2 +-
kvm-stub.c |4
kvm.h |1 +
3 files changed, 6 insertions(+), 1 deletions(-)
diff --git a/kvm-all.c b/kvm-all.c
index 7f906ca..ca6ce
From: Jan Kiszka
Make use of the new vector notifier to track changes of the MSI-X
configuration of virtio PCI devices. On enabling events, we establish
the required virtual IRQ to MSI-X message route and link the signaling
eventfd file descriptor to this vIRQ line. That way, vhost-generated
inte
From: Jan Kiszka
Analogously to msi_nr_vectors_allocated, add a service for MSI-X. Will
be used by the virtio-pci layer.
Signed-off-by: Jan Kiszka
---
hw/msix.c |5 +
hw/msix.h |2 ++
2 files changed, 7 insertions(+), 0 deletions(-)
diff --git a/hw/msix.c b/hw/msix.c
index 1622e16
From: Jan Kiszka
Provide a dummy kvm_kernel_irqchip so that kvm_irqchip_in_kernel can be
used by code that is not under CONFIG_KVM protection.
Signed-off-by: Jan Kiszka
---
kvm-stub.c |1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/kvm-stub.c b/kvm-stub.c
index b4cf03f
From: Jan Kiszka
Add services to associate an eventfd file descriptor as input with an
IRQ line as output. Such a line can be an input pin of an in-kernel
irqchip or a virtual line returned by kvm_irqchip_add_route.
Signed-off-by: Jan Kiszka
---
kvm-all.c | 30 ++
From: Jan Kiszka
Automatically commit route changes after kvm_add_routing_entry and
kvm_irqchip_release_virq. There is no performance relevant use case for
which collecting multiple route changes is beneficial. This makes
kvm_irqchip_commit_routes an internal service which assert()s that the
corr
From: Jan Kiszka
Add a service that establishes a static route from a virtual IRQ line to
an MSI message. Will be used for IRQFD and device assignment. As we will
use this service outside of CONFIG_KVM protected code, stub it properly.
Signed-off-by: Jan Kiszka
---
kvm-all.c | 31 ++
From: Jan Kiszka
Vector notifiers shall be triggered by the MSI/MSI-X core whenever a
relevant configuration change is programmed by the guest. In case of
MSI-X, changes are reported when the effective mask (global &&
per-vector) alters its state. On unmask, the current vector
configuration is in
From: Jan Kiszka
In preparation of firing vector notifiers on mask changes, call
msix_handle_mask_update also from msix_mask_all. So far, this will have
no real effect.
Signed-off-by: Jan Kiszka
---
hw/msix.c |4
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/hw/msix.c
From: Jan Kiszka
This helper will also be used by the upcoming config notifier.
Signed-off-by: Jan Kiszka
---
hw/msix.c | 19 +--
1 files changed, 13 insertions(+), 6 deletions(-)
diff --git a/hw/msix.c b/hw/msix.c
index 3835eaa..3197465 100644
--- a/hw/msix.c
+++ b/hw/msix.
[ changes in v2: rebase over uq/master ]
This series is another major milestone of merging qemu-kvm into
upstream. It implements the required interfaces and logic to directly
inject MSI-X interrupts generated by the vhost-net kernel module into
the KVM in-kernel irqchip. This involves
- establish
On Wed, May 16, 2012 at 05:58:05PM -0300, Eduardo Habkost wrote:
[...]
> @@ -521,6 +523,13 @@ static int cpu_x86_fill_host(x86_def_t *x86_cpu_def)
> x86_cpu_def->ext_features = ecx;
> x86_cpu_def->features = edx;
>
> +if (x86_cpu_def->level >= 7) {
> +host_cpuid(0x7, 0, &eax
Currently we check that the mmu root exits before every entry. Use the
existing KVM_REQ_MMU_RELOAD mechanism instead, by making it really reload
the mmu, and by adding the request to mmu initialization code.
Signed-off-by: Avi Kivity
---
arch/x86/kvm/mmu.c |2 ++
arch/x86/kvm/x86.c | 14 +
Instead of using a atomic operation per active request, use just one
to get all requests at once, then check them with local ops. This
probably isn't any faster, since simultaneous requests are rare, but
it does reduce code size.
Signed-off-by: Avi Kivity
---
arch/x86/kvm/x86.c | 33 +
Put the KVM_REQ_EVENT block in the regular vcpu->requests if (),
instead of its own little check.
Signed-off-by: Avi Kivity
---
arch/x86/kvm/x86.c | 30 --
1 file changed, 16 insertions(+), 14 deletions(-)
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c
index
Nothing spectacular, just regularization of the code.
Avi Kivity (3):
KVM: Simplify KVM_REQ_EVENT/req_int_win handling
KVM: Optimize vcpu->requests slow path slightly
KVM: Move mmu reload out of line
arch/x86/kvm/mmu.c |2 ++
arch/x86/kvm/x86.c | 73 --
On Wed, May 16, 2012 at 09:32:44PM -0500, Anthony Liguori wrote:
> On 05/16/2012 03:58 PM, Eduardo Habkost wrote:
> >Description of the bug:
> >
> >Since QEMU 0.15, the CPUID information on CPUID[EAX=7,ECX=0] is being
> >returned unfiltered to the guest, directly from the GET_SUPPORTED_CPUID
> >ret
On 05/17/2012 01:24 PM, Avi Kivity wrote:
> Currently we flush the TLB while holding mmu_lock. This
> increases the lock hold time by the IPI round-trip time, increasing
> contention, and makes dropping the lock (for latency reasons) harder.
>
> This patch changes TLB management to be usable lockl
Currently we flush the TLB while holding mmu_lock. This
increases the lock hold time by the IPI round-trip time, increasing
contention, and makes dropping the lock (for latency reasons) harder.
This patch changes TLB management to be usable locklessly, introducing
the following APIs:
kvm_mark_
Signed-off-by: Avi Kivity
---
arch/x86/kvm/mmu.c |8 +---
virt/kvm/kvm_main.c |2 ++
2 files changed, 3 insertions(+), 7 deletions(-)
diff --git a/arch/x86/kvm/mmu.c b/arch/x86/kvm/mmu.c
index 0e1faec..85ed48a 100644
--- a/arch/x86/kvm/mmu.c
+++ b/arch/x86/kvm/mmu.c
@@ -1138,7 +1138
mmu_page_zap_pte() is modified to mark the TLB as dirty; but currently
only FNAME(invlpg) takes advantage of this.
Signed-off-by: Avi Kivity
---
arch/x86/kvm/mmu.c |7 +++
arch/x86/kvm/paging_tmpl.h |7 +++
2 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/ar
Signed-off-by: Avi Kivity
---
virt/kvm/kvm_main.c | 16
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index 585ab45..9f6d15d 100644
--- a/virt/kvm/kvm_main.c
+++ b/virt/kvm/kvm_main.c
@@ -302,11 +302,11 @@ static void kv
This allows us to later move the actual flush out of protection of the
mmu spinlock, provided there are no additional dependencies.
Constructs of the form
if (pred)
kvm_flush_remote_tlbs(kvm)
are converted to
if (pred)
kvm_mark_tlb_dirty(kvm)
kvm_cond_flush_remote_t
Practically all patches to ia64 KVM are build fixes; numerous warnings remain;
the last patch from the maintainer was committed more than three years ago. It
is clear that no one is using this thing.
Mark as BROKEN to ensure people don't get hit by pointless build problems.
Signed-off-by: Avi Ki
The following changes since commit 0e93b4b304ae052ba1bc73f6d34a68556fe93429:
Merge git://git.kernel.org/pub/scm/virt/kvm/kvm (2012-05-16 14:30:51 -0700)
are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git for_linus
for you to fetch changes up
On Thu, May 17, 2012 at 12:24:30PM +0300, Avi Kivity wrote:
> On 05/17/2012 11:07 AM, Gleb Natapov wrote:
> > >
> > > No, let's refactor this so it makes sense. The {has|get}_interrupt
> > > split is the cause of the problem, I think. We need a single function,
> > > with callbacks that are call
On 05/16/2012 02:46 PM, Michael S. Tsirkin wrote:
> Implementation of PV EOI using shared memory.
> This reduces the number of exits an interrupt
> causes as much as by half.
>
> The idea is simple: there's a bit, per APIC, in guest memory,
> that tells the guest that it does not need EOI.
> We set
On 05/17/2012 12:12 PM, Gleb Natapov wrote:
> >
> > OK will look into this next week.
> >
> What about looking into my suggestion with setting vcpu->request bit? I
> think totally refactoring irq handling path should not be done as part
> of this series.
>
Certainly not as part of it, but maybe
On 05/17/2012 11:07 AM, Gleb Natapov wrote:
> >
> > No, let's refactor this so it makes sense. The {has|get}_interrupt
> > split is the cause of the problem, I think. We need a single function,
> > with callbacks that are called when an event happens. The callbacks can
> > request an irq window
From: Liu Ping Fan
Make vhost net support to spread on host node according the command.
And consider the whole vhost_net componsed of lots of logic net units.
for each node, there is a unit, which includes a vhost_worker thread,
rx/tx vhost_virtqueue.
Signed-off-by: Liu Ping Fan
---
drivers/vh
From: Liu Ping Fan
Vhost net uses separate transfer logic unit in different node.
Virtio net must determine which logic unit it will talk with,
so we can improve the performance.
Signed-off-by: Liu Ping Fan
---
drivers/net/virtio_net.c | 425 ++
1 f
From: Liu Ping Fan
For each numa node reported by vhost, we alloc a pair of i/o vq,
and assign them msix IRQ, and set irq affinity to a set of vcpu
in the same node.
Also we alloc vqs on PAGE_SIZE align, so they will be allocated by
host when pg fault happen on different node.
Signed-off-by: Liu
From: Liu Ping Fan
Make vhost allocate vhost_virtqueue on different host nodes as required.
Signed-off-by: Liu Ping Fan
---
drivers/vhost/vhost.c | 380 +++--
drivers/vhost/vhost.h | 41 --
include/linux/vhost.h |2 +-
3 files changed, 304
Currently, the guest can not know the NUMA info of the vcpu, which will
result in performance drawback.
This is the discovered and experiment by
Shirley Ma
Krishna Kumar
Tom Lendacky
Refer to - http://www.mail-archive.com/kvm@vger.kernel.org/msg69868.html
we can see the
On Thu, May 17, 2012 at 12:10:55PM +0300, Michael S. Tsirkin wrote:
> On Thu, May 17, 2012 at 10:57:33AM +0300, Avi Kivity wrote:
> > On 05/17/2012 10:49 AM, Michael S. Tsirkin wrote:
> > > On Thu, May 17, 2012 at 10:28:41AM +0300, Gleb Natapov wrote:
> > > > On Wed, May 16, 2012 at 10:07:58PM +030
On Thu, May 17, 2012 at 10:57:33AM +0300, Avi Kivity wrote:
> On 05/17/2012 10:49 AM, Michael S. Tsirkin wrote:
> > On Thu, May 17, 2012 at 10:28:41AM +0300, Gleb Natapov wrote:
> > > On Wed, May 16, 2012 at 10:07:58PM +0300, Michael S. Tsirkin wrote:
> > > > > This code is reached from kvm_cpu_get
On Thu, May 17, 2012 at 10:57:33AM +0300, Avi Kivity wrote:
> On 05/17/2012 10:49 AM, Michael S. Tsirkin wrote:
> > On Thu, May 17, 2012 at 10:28:41AM +0300, Gleb Natapov wrote:
> > > On Wed, May 16, 2012 at 10:07:58PM +0300, Michael S. Tsirkin wrote:
> > > > > This code is reached from kvm_cpu_get
On 05/17/2012 10:49 AM, Michael S. Tsirkin wrote:
> On Thu, May 17, 2012 at 10:28:41AM +0300, Gleb Natapov wrote:
> > On Wed, May 16, 2012 at 10:07:58PM +0300, Michael S. Tsirkin wrote:
> > > > This code is reached from kvm_cpu_get_interrupt(), but this function
> > > > will
> > > > not be called
On Thu, May 17, 2012 at 10:49:47AM +0300, Michael S. Tsirkin wrote:
> On Thu, May 17, 2012 at 10:28:41AM +0300, Gleb Natapov wrote:
> > On Wed, May 16, 2012 at 10:07:58PM +0300, Michael S. Tsirkin wrote:
> > > > This code is reached from kvm_cpu_get_interrupt(), but this function
> > > > will
> >
On Thu, May 17, 2012 at 10:28:41AM +0300, Gleb Natapov wrote:
> On Wed, May 16, 2012 at 10:07:58PM +0300, Michael S. Tsirkin wrote:
> > > This code is reached from kvm_cpu_get_interrupt(), but this function will
> > > not be called in above scenario.
> >
> > I think I see. So this shall fix it als
On Wed, May 16, 2012 at 10:07:58PM +0300, Michael S. Tsirkin wrote:
> > This code is reached from kvm_cpu_get_interrupt(), but this function will
> > not be called in above scenario.
>
> I think I see. So this shall fix it also makes code cleaner
> (no -2 hack). Right? kvm_apic_has_interrupt is ca
On Wed, May 16, 2012 at 06:25:48PM -0700, Sriram Murthy wrote:
> Hi,
>Can I run Intel vTune program that uses hardware events from the PMU, for
> profiling, on my linux VM on KVM? Also, what is the current state of PMU
> support for guest VMs on KVM?.
No, unfortunately you can't. vTune does
Alex,
On Sat, May 12, 2012 at 6:55 AM, Alex Williamson
wrote:
> Integrating IOMMU groups more closely into the driver core allows
> us to more easily work around DMA quirks. The Ricoh multifunction
> controller is a favorite example of devices that are currently
> incompatible with IOMMU isolati
70 matches
Mail list logo