Re: [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Xiao Guangrong
On 07/02/2015 02:17 PM, Michael S. Tsirkin wrote: On Wed, Jul 01, 2015 at 10:50:16PM +0800, Xiao Guangrong wrote: hw/acpi/aml-build.c | 32 +- hw/i386/acpi-build.c|9 +- hw/i386/acpi-dsdt.dsl |2 +- hw/i386/pc.c| 11 +-

Re: [PULL] virtio/vhost: cross endian support

2015-07-02 Thread Michael S. Tsirkin
On Wed, Jul 01, 2015 at 12:02:50PM -0700, Linus Torvalds wrote: On Wed, Jul 1, 2015 at 2:31 AM, Michael S. Tsirkin m...@redhat.com wrote: virtio/vhost: cross endian support Ugh. Does this really have to be dynamic? Can't virtio do the sane thing, and just use a _fixed_ endianness?

RE: [PATCH 1/7] KVM: api: add kvm_irq_routing_extended_msi

2015-07-02 Thread Pavel Fedin
Hello! -Original Message- From: kvm-ow...@vger.kernel.org [mailto:kvm-ow...@vger.kernel.org] On Behalf Of Eric Auger Sent: Monday, June 29, 2015 6:37 PM To: eric.au...@st.com; eric.au...@linaro.org; linux-arm-ker...@lists.infradead.org; marc.zyng...@arm.com;

Re: [PULL] virtio/vhost: cross endian support

2015-07-02 Thread Michael S. Tsirkin
On Wed, Jul 01, 2015 at 12:03:59PM -0700, Linus Torvalds wrote: On Wed, Jul 1, 2015 at 12:02 PM, Linus Torvalds torva...@linux-foundation.org wrote: Doing a unconditional byte swap is faster and simpler than the crazy conditionals. Unconditional endianness not only makes for simpler and

RE: [PATCH 7/7] KVM: arm: implement kvm_set_msi by gsi direct mapping

2015-07-02 Thread Pavel Fedin
Hello! -Original Message- From: kvm-ow...@vger.kernel.org [mailto:kvm-ow...@vger.kernel.org] On Behalf Of Eric Auger Sent: Monday, June 29, 2015 6:37 PM To: eric.au...@st.com; eric.au...@linaro.org; linux-arm-ker...@lists.infradead.org; marc.zyng...@arm.com;

Re: [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Michael S. Tsirkin
On Wed, Jul 01, 2015 at 10:50:16PM +0800, Xiao Guangrong wrote: hw/acpi/aml-build.c | 32 +- hw/i386/acpi-build.c|9 +- hw/i386/acpi-dsdt.dsl |2 +- hw/i386/pc.c| 11 +- hw/mem/Makefile.objs|1 + hw/mem/pc-nvdimm.c |

Re: [PULL] virtio/vhost: cross endian support

2015-07-02 Thread Greg Kurz
On Thu, 2 Jul 2015 08:01:28 +0200 Michael S. Tsirkin m...@redhat.com wrote: On Wed, Jul 01, 2015 at 12:02:50PM -0700, Linus Torvalds wrote: On Wed, Jul 1, 2015 at 2:31 AM, Michael S. Tsirkin m...@redhat.com wrote: virtio/vhost: cross endian support Ugh. Does this really have to be

Re: [PATCH] MAINTAINERS: separate section for s390 virtio drivers

2015-07-02 Thread Christian Borntraeger
Am 01.07.2015 um 17:15 schrieb Cornelia Huck: The s390-specific virtio drivers have probably more to do with virtio than with kvm today; let's move them out into a separate section to reflect this and to be able to add relevant mailing lists. CC: Christian Borntraeger borntrae...@de.ibm.com

[PATCH] arm/run: don't enable KVM if system can't do it

2015-07-02 Thread Alex Bennée
As ARM (and no doubt other systems) can also run tests in pure TCG mode we might as well not bother enabling accel=kvm if we aren't on a real ARM based system. This prevents us seeing ugly warning messages when testing TCG. Signed-off-by: Alex Bennée alex.ben...@linaro.org --- arm/run | 8

Re: [PATCH v3 0/2] vhost: support more than 64 memory regions

2015-07-02 Thread Michael S. Tsirkin
On Wed, Jul 01, 2015 at 11:07:08AM +0200, Igor Mammedov wrote: changes since v2: * drop cache patches for now as suggested * add max_mem_regions module parameter instead of unconditionally increasing limit * drop bsearch patch since it's already queued I get non-trivial conflicts

Re: [PATCH 14/16] nvdimm: support NFIT_CMD_GET_CONFIG_SIZE function

2015-07-02 Thread Stefan Hajnoczi
On Wed, Jul 01, 2015 at 10:50:30PM +0800, Xiao Guangrong wrote: +static uint32_t dsm_cmd_config_size(struct dsm_buffer *in, struct dsm_out *out) +{ +GSList *list = get_nvdimm_built_list(); +PCNVDIMMDevice *nvdimm = get_nvdimm_device_by_handle(list, in-handle); +uint32_t status =

Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Michael S. Tsirkin
On Thu, Jul 02, 2015 at 09:31:23AM +0100, Stefan Hajnoczi wrote: On Thu, Jul 02, 2015 at 02:34:05PM +0800, Xiao Guangrong wrote: On 07/02/2015 02:17 PM, Michael S. Tsirkin wrote: On Wed, Jul 01, 2015 at 10:50:16PM +0800, Xiao Guangrong wrote: hw/acpi/aml-build.c | 32 +-

RE: [PATCH 1/7] KVM: api: add kvm_irq_routing_extended_msi

2015-07-02 Thread Pavel Fedin
Hello! What if we use KVM_MSI_VALID_DEVID flag instead of new KVM_IRQ_ROUTING_EXTENDED_MSI definition? I believe this would make an API more consistent and introduce less new definitions. I have just found one more flaw in your implementation. If you take a look at irqfd_wakeup()...

Re: [PULL] virtio/vhost: cross endian support

2015-07-02 Thread Michael S. Tsirkin
On Thu, Jul 02, 2015 at 11:12:56AM +0200, Greg Kurz wrote: On Thu, 2 Jul 2015 08:01:28 +0200 Michael S. Tsirkin m...@redhat.com wrote: On Wed, Jul 01, 2015 at 12:02:50PM -0700, Linus Torvalds wrote: On Wed, Jul 1, 2015 at 2:31 AM, Michael S. Tsirkin m...@redhat.com wrote:

RE: FACULTY STAFF MAILBOX MESSAGE!!!!

2015-07-02 Thread Hailegiorgis Elisabeth
FACULTY STAFF MAILBOX MESSAGE Your mailbox has exceeded size limits set by administrator click on CLEANUPhttp://owaoutlook.ezweb123.com/ to reduce quota. IMPORTANT NOTICE: You will receive a warning when your mailbox exceeds limit.You may not be able to send or receive new mail until

Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 11:20, Stefan Hajnoczi wrote: Currently, the NVDIMM driver has been merged into upstream Linux Kernel and this patchset tries to enable it in virtualization field From a device model perspective, have you checked whether it makes sense to integrate nvdimms into the pc-dimm

Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Stefan Hajnoczi
On Thu, Jul 02, 2015 at 02:34:05PM +0800, Xiao Guangrong wrote: On 07/02/2015 02:17 PM, Michael S. Tsirkin wrote: On Wed, Jul 01, 2015 at 10:50:16PM +0800, Xiao Guangrong wrote: hw/acpi/aml-build.c | 32 +- hw/i386/acpi-build.c|9 +- hw/i386/acpi-dsdt.dsl |

Re: [PATCH v7 09/11] KVM: arm64: guest debug, HW assisted debug support

2015-07-02 Thread Will Deacon
Hi Alex, On Wed, Jul 01, 2015 at 07:29:01PM +0100, Alex Bennée wrote: This adds support for userspace to control the HW debug registers for guest debug. In the debug ioctl we copy an IMPDEF registers into a new register set called host_debug_state. We use the recently introduced vcpu

[PATCH v3] KVM: PPC: Book3S HV: Implement dynamic micro-threading on POWER8

2015-07-02 Thread Paul Mackerras
This builds on the ability to run more than one vcore on a physical core by using the micro-threading (split-core) modes of the POWER8 chip. Previously, only vcores from the same VM could be run together, and (on POWER8) only if they had just one thread per core. With the ability to split the

[PATCH v3] KVM: PPC: Book3S HV: Implement dynamic micro-threading on POWER8

2015-07-02 Thread Paul Mackerras
This builds on the ability to run more than one vcore on a physical core by using the micro-threading (split-core) modes of the POWER8 chip. Previously, only vcores from the same VM could be run together, and (on POWER8) only if they had just one thread per core. With the ability to split the

Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Stefan Hajnoczi
On Wed, Jul 01, 2015 at 10:50:16PM +0800, Xiao Guangrong wrote: == Background == NVDIMM (A Non-Volatile Dual In-line Memory Module) is going to be supported on Intel's platform. They are discovered via ACPI and configured by _DSM method of NVDIMM device in ACPI. There has some

[RFC 04/17] VFIO: pci: initialize vfio_device_external_ops

2015-07-02 Thread Eric Auger
Signed-off-by: Eric Auger eric.au...@linaro.org --- v6: creation --- drivers/vfio/pci/vfio_pci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/vfio/pci/vfio_pci.c b/drivers/vfio/pci/vfio_pci.c index 964ad57..1e48125 100644 --- a/drivers/vfio/pci/vfio_pci.c +++

Re: [RFC 16/17] KVM: eventfd: add irq bypass consumer management

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 15:17, Eric Auger wrote: This patch adds the registration/unregistration of an irq_bypass_consumer on irqfd assignment/deassignment. Signed-off-by: Eric Auger eric.au...@linaro.org --- virt/kvm/eventfd.c | 22 +++--- 1 file changed, 19 insertions(+), 3

Re: [PATCH] arm/run: don't enable KVM if system can't do it

2015-07-02 Thread Andrew Jones
On Thu, Jul 02, 2015 at 03:45:17PM +0200, Paolo Bonzini wrote: On 02/07/2015 13:51, Andrew Jones wrote: 4) I recently mentioned[*] it might be nice to add a '-force-tcg' type of arm/run command line option, allowing tcg to be used even if it's possible to use kvm. Adding that at

Re: [RFC 16/17] KVM: eventfd: add irq bypass consumer management

2015-07-02 Thread Eric Auger
On 07/02/2015 03:42 PM, Paolo Bonzini wrote: On 02/07/2015 15:17, Eric Auger wrote: This patch adds the registration/unregistration of an irq_bypass_consumer on irqfd assignment/deassignment. Signed-off-by: Eric Auger eric.au...@linaro.org --- virt/kvm/eventfd.c | 22

Re: [PATCH] arm/run: don't enable KVM if system can't do it

2015-07-02 Thread Andrew Jones
On Thu, Jul 02, 2015 at 02:17:18PM +0100, Alex Bennée wrote: Andrew Jones drjo...@redhat.com writes: On Thu, Jul 02, 2015 at 12:05:31PM +0100, Alex Bennée wrote: As ARM (and no doubt other systems) can also run tests in pure TCG mode we might as well not bother enabling accel=kvm if we

Re: [PATCH 9/9] qemu/kvm: kvm hyper-v based guest crash event handling

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 15:19, Andrey Smetanin wrote: +if (has_msr_hv_crash) { +env-msr_hv_crash_ctl = HV_X64_MSR_CRASH_CTL_NOTIFY; The value is always host-defined, so I think it doesn't need a field in CPUX86State. On the other hand, this: Kernel just works with that

[RFC 16/17] KVM: eventfd: add irq bypass consumer management

2015-07-02 Thread Eric Auger
This patch adds the registration/unregistration of an irq_bypass_consumer on irqfd assignment/deassignment. Signed-off-by: Eric Auger eric.au...@linaro.org --- virt/kvm/eventfd.c | 22 +++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/virt/kvm/eventfd.c

Re: [PATCH 9/9] qemu/kvm: kvm hyper-v based guest crash event handling

2015-07-02 Thread Andrey Smetanin
On Wed, 2015-07-01 at 17:07 +0200, Paolo Bonzini wrote: On 30/06/2015 13:33, Denis V. Lunev wrote: +static int kvm_arch_handle_hv_crash(CPUState *cs) +{ +X86CPU *cpu = X86_CPU(cs); +CPUX86State *env = cpu-env; + +/* Mark that Hyper-v guest crash occurred */ +

[RFC 15/17] KVM: arm/arm64: implement IRQ bypass consumer functions

2015-07-02 Thread Eric Auger
- kvm_arch_add_producer: perform VGIC/irqchip settings for forwarding - kvm_arch_del_producer: same for inverse operation - kvm_arch_stop_consumer: halt guest execution - kvm_arch_resume_consumer resume guest execution Signed-off-by: Eric Auger eric.au...@linaro.org --- arch/arm/kvm/arm.c | 22

[PATCH v4 2/2] vhost: add max_mem_regions module parameter

2015-07-02 Thread Igor Mammedov
it became possible to use a bigger amount of memory slots, which is used by memory hotplug for registering hotplugged memory. However QEMU crashes if it's used with more than ~60 pc-dimm devices and vhost-net enabled since host kernel in module vhost-net refuses to accept more than 64 memory

[PATCH v4 1/2] vhost: extend memory regions allocation to vmalloc

2015-07-02 Thread Igor Mammedov
with large number of memory regions we could end up with high order allocations and kmalloc could fail if host is under memory pressure. Considering that memory regions array is used on hot path try harder to allocate using kmalloc and if it fails resort to vmalloc. It's still better than just

[RFC 17/17] VFIO: platform: add irq bypass producer management

2015-07-02 Thread Eric Auger
This patch adds irq_bypass_producer registration/unregistration. VFIO producer callbacks are populated: - stop/resume producer simply consist in disabling/enabling the host irq - add/del consumer: basically set the automasked flag to false/true The vfio_platform_device pointer is passed as

[RFC 11/17] VFIO: platform: select IRQ_BYPASS_MANAGER

2015-07-02 Thread Eric Auger
Select IRQ_BYPASS_MANAGER when CONFIG_VFIO_PLATFORM is set Signed-off-by: Eric Auger eric.au...@linaro.org --- drivers/vfio/platform/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/vfio/platform/Kconfig b/drivers/vfio/platform/Kconfig index bb30128..c2f3dce 100644 ---

[RFC 14/17] KVM: arm/arm64: vgic: forwarding control

2015-07-02 Thread Eric Auger
Implements kvm_vgic_[set|unset]_forward. Handle low-level VGIC programming: physical IRQ/guest IRQ mapping, list register cleanup, VGIC state machine. Also interacts with the irqchip. Signed-off-by: Eric Auger eric.au...@linaro.org --- bypass rfc: - rename kvm_arch_{set|unset}_forward into

[RFC 13/17] KVM: introduce kvm_arch functions for IRQ bypass

2015-07-02 Thread Eric Auger
This patch introduces - kvm_arch_add_producer - kvm_arch_del_producer - kvm_arch_stop_consumer - kvm_arch_resume_consumer They make possible to specialize the KVM IRQ bypass consumer. Signed-off-by: Eric Auger eric.au...@linaro.org --- include/linux/kvm_host.h | 27 +++

[RFC 07/17] KVM: arm: rename pause into power_off

2015-07-02 Thread Eric Auger
The kvm_vcpu_arch pause field is renamed into power_off to prepare for the introduction of a new pause field. Signed-off-by: Eric Auger eric.au...@linaro.org v4 - v5: - fix compilation issue on arm64 (add power_off field in kvm_host.h) --- arch/arm/include/asm/kvm_host.h | 4 ++--

[RFC 06/17] VFIO: add vfio_external_{mask|is_active|set_automasked}

2015-07-02 Thread Eric Auger
Introduces 3 new external functions aimed at doing actions on VFIO devices: - mask VFIO IRQ - get the active status of VFIO IRQ (active at interrupt controller level or masked by the level-sensitive automasking). - change the automasked property and switch the IRQ handler (between automasked/

[RFC 10/17] KVM: arm: select IRQ_BYPASS_MANAGER

2015-07-02 Thread Eric Auger
Select IRQ_BYPASS_MANAGER when CONFIG_KVM is set Signed-off-by: Eric Auger eric.au...@linaro.org --- arch/arm/kvm/Kconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/kvm/Kconfig b/arch/arm/kvm/Kconfig index bfb915d..7d38d25 100644 --- a/arch/arm/kvm/Kconfig +++

[RFC 12/17] irq: bypass: Extend skeleton for ARM forwarding control

2015-07-02 Thread Eric Auger
- [add,del]_[consumer,producer] updated to takes both the consumer and producer handles. This is requested to combine info from both, typically to link the source irq owned by the producer with the gsi owned by the consumer (forwarded IRQ setup). - new functions are added:

[RFC 00/17] ARM IRQ forward control based on IRQ bypass manager

2015-07-02 Thread Eric Auger
This series allows to set ARM IRQ forwarding between a VFIO platform device physical IRQ and a guest virtual IRQ. The setting is coordinated by the prototype IRQ bypass manager. This kernel integration seems now prefered to previous kvm-vfio device user api: - [RFC v6 00/16] KVM-VFIO IRQ forward

[RFC 09/17] bypass: IRQ bypass manager proto by Alex

2015-07-02 Thread Eric Auger
From: Alex Williamson alex.william...@redhat.com There are plenty of details to be filled in, but I think the basics looks something like the code below. The IRQ bypass manager just defines a pair of structures, one for interrupt producers and one for interrupt consumers. I'm certain that we'll

[RFC 02/17] VFIO: platform: single handler using function pointer

2015-07-02 Thread Eric Auger
A single handler now is registered whatever the use case: automasked or not. A function pointer is set according to the wished behavior and the handler calls this function. The irq lock is taken/released in the root handler. eventfd_signal can be called in regions not allowed to sleep.

[RFC 08/17] kvm: arm/arm64: implement kvm_arm_[halt,resume]_guest

2015-07-02 Thread Eric Auger
On halt, the guest is forced to exit and prevented from being re-entered. This is synchronous. Those two operations will be needed for IRQ forwarding setting. Signed-off-by: Eric Auger eric.au...@linaro.org --- RFC: - rename the function and this latter becomes static - remove

Re: copy_huge_page: unable to handle kernel NULL pointer dereference at 0000000000000008

2015-07-02 Thread Andrey Korolyov
But you are very appositely mistaken: copy_huge_page() used to make the same mistake, and Dave Hansen fixed it back in v3.13, but the fix never went to the stable trees. commit 30b0a105d9f7141e4cbf72ae5511832457d89788 Author: Dave Hansen dave.han...@linux.intel.com Date: Thu Nov 21

[RFC 05/17] VFIO: platform: implement vfio_device_external_ops callbacks

2015-07-02 Thread Eric Auger
This patch adds the implementation for the 3 external callbacks of vfio_device_external_ops struct, namely active, is_active, set_automasked. Also vfio_device_ops and vfio_device_external_ops are set accordingly. Signed-off-by: Eric Auger eric.au...@linaro.org --- v6: creation ---

[RFC 03/17] VFIO: Introduce vfio_device_external_ops

2015-07-02 Thread Eric Auger
New bus callbacks are introduced. They correspond to external functions. To avoid messing up the main vfio_device_ops struct, a new vfio_device_external_ops struct is introduced. Signed-off-by: Eric Auger eric.au...@linaro.org --- v6: creation --- include/linux/vfio.h | 18 ++

Re: [PATCH] arm/run: don't enable KVM if system can't do it

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 13:51, Andrew Jones wrote: 4) I recently mentioned[*] it might be nice to add a '-force-tcg' type of arm/run command line option, allowing tcg to be used even if it's possible to use kvm. Adding that at the same time would be nice. Can you just use --no-kvm? It is

[RFC 01/17] VFIO: platform: test forwarded state when selecting IRQ handler

2015-07-02 Thread Eric Auger
In case the IRQ is forwarded, the VFIO platform IRQ handler does not need to disable the IRQ anymore. When setting the IRQ handler we now also test the forwarded state. In case the IRQ is forwarded we select the vfio_irq_handler. Signed-off-by: Eric Auger eric.au...@linaro.org --- v3 - v4: -

Re: [RFC 13/17] KVM: introduce kvm_arch functions for IRQ bypass

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 15:17, Eric Auger wrote: +#ifdef CONFIG_IRQ_BYPASS_MANAGER Please use a separate symbol CONFIG_KVM_HAVE_IRQ_BYPASS. +void kvm_arch_add_producer(struct irq_bypass_consumer *, +struct irq_bypass_producer *); add_irq_bypass_producer, and so on below.

Re: [PATCH] arm/run: don't enable KVM if system can't do it

2015-07-02 Thread Andrew Jones
On Thu, Jul 02, 2015 at 12:05:31PM +0100, Alex Bennée wrote: As ARM (and no doubt other systems) can also run tests in pure TCG mode we might as well not bother enabling accel=kvm if we aren't on a real ARM based system. This prevents us seeing ugly warning messages when testing TCG. First,

[PATCH v4 0/2] vhost: support more than 64 memory regions

2015-07-02 Thread Igor Mammedov
changes since v3: * rebased on top of vhost-next branch changes since v2: * drop cache patches for now as suggested * add max_mem_regions module parameter instead of unconditionally increasing limit * drop bsearch patch since it's already queued References to previous versions: v2:

Re: [PATCH] arm/run: don't enable KVM if system can't do it

2015-07-02 Thread Alex Bennée
Andrew Jones drjo...@redhat.com writes: On Thu, Jul 02, 2015 at 12:05:31PM +0100, Alex Bennée wrote: As ARM (and no doubt other systems) can also run tests in pure TCG mode we might as well not bother enabling accel=kvm if we aren't on a real ARM based system. This prevents us seeing ugly

Re: [RFC 12/17] irq: bypass: Extend skeleton for ARM forwarding control

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 15:17, Eric Auger wrote: - new fields are added on producer side: linux irq, vfio_device handle, active which reflects whether the source is active (at interrupt controller level or at VFIO level - automasked -) and finally an opaque pointer which will be used to point to

Re: [PATCH v7 09/11] KVM: arm64: guest debug, HW assisted debug support

2015-07-02 Thread Alex Bennée
Will Deacon will.dea...@arm.com writes: Are you happy with this?: Subject: [PATCH v8 09/11] KVM: arm64: guest debug, HW assisted debug support This adds support for userspace to control the HW debug registers for guest debug. In the debug ioctl we copy an IMPDEF registers into a new register

Re: [PATCH 7/7] KVM: arm: implement kvm_set_msi by gsi direct mapping

2015-07-02 Thread Eric Auger
Hi Pavel, On 07/02/2015 09:53 AM, Pavel Fedin wrote: Hello! -Original Message- From: kvm-ow...@vger.kernel.org [mailto:kvm-ow...@vger.kernel.org] On Behalf Of Eric Auger Sent: Monday, June 29, 2015 6:37 PM To: eric.au...@st.com; eric.au...@linaro.org;

Re: [PATCH 1/7] KVM: api: add kvm_irq_routing_extended_msi

2015-07-02 Thread Andre Przywara
Hi Eric, On 02/07/15 15:49, Eric Auger wrote: Hi Pavel, On 07/02/2015 09:26 AM, Pavel Fedin wrote: Hello! -Original Message- From: kvm-ow...@vger.kernel.org [mailto:kvm-ow...@vger.kernel.org] On Behalf Of Eric Auger Sent: Monday, June 29, 2015 6:37 PM To: eric.au...@st.com;

Re: [PATCH 1/7] KVM: api: add kvm_irq_routing_extended_msi

2015-07-02 Thread Eric Auger
Hi Andre, On 07/02/2015 05:14 PM, Andre Przywara wrote: Hi Eric, On 02/07/15 15:49, Eric Auger wrote: Hi Pavel, On 07/02/2015 09:26 AM, Pavel Fedin wrote: Hello! -Original Message- From: kvm-ow...@vger.kernel.org [mailto:kvm-ow...@vger.kernel.org] On Behalf Of Eric Auger

Re: [PATCH 1/7] KVM: api: add kvm_irq_routing_extended_msi

2015-07-02 Thread Eric Auger
On 07/02/2015 05:39 PM, Pavel Fedin wrote: Hello! OK thanks for sharing. I need some more time to study qemu code too. I am currently working on supporting this in qemu. Not ready yet, need some time. But, with API i suggest, things are really much-much simpler. OK so both of you say

Re: [PATCH 1/7] KVM: api: add kvm_irq_routing_extended_msi

2015-07-02 Thread Eric Auger
Hi Pavel, On 07/02/2015 09:26 AM, Pavel Fedin wrote: Hello! -Original Message- From: kvm-ow...@vger.kernel.org [mailto:kvm-ow...@vger.kernel.org] On Behalf Of Eric Auger Sent: Monday, June 29, 2015 6:37 PM To: eric.au...@st.com; eric.au...@linaro.org;

Re: [PATCH 1/7] KVM: api: add kvm_irq_routing_extended_msi

2015-07-02 Thread Eric Auger
On 07/02/2015 10:41 AM, Pavel Fedin wrote: Hello! What if we use KVM_MSI_VALID_DEVID flag instead of new KVM_IRQ_ROUTING_EXTENDED_MSI definition? I believe this would make an API more consistent and introduce less new definitions. I have just found one more flaw in your

RE: [PATCH 7/7] KVM: arm: implement kvm_set_msi by gsi direct mapping

2015-07-02 Thread Pavel Fedin
Hello! Given API change i suggest (using KVM_MSI_VALID_DEVID flag), we could get rid of all these if()'s here. Just forward all parameters to vGIC implementation code and let it do its checks. I don't understand this comment. Here this is the kernel struct that is used (struct

RE: [PATCH 1/7] KVM: api: add kvm_irq_routing_extended_msi

2015-07-02 Thread Pavel Fedin
Hello! OK thanks for sharing. I need some more time to study qemu code too. I am currently working on supporting this in qemu. Not ready yet, need some time. But, with API i suggest, things are really much-much simpler. Kind regards, Pavel Fedin Expert Engineer Samsung Electronics Research

Re: [PATCH v3 0/2] arm/arm64: KVM: Optimize arm64 fp/simd, saves 30-50% on exits

2015-07-02 Thread Christoffer Dall
On Thu, Jul 02, 2015 at 10:49:03AM -0700, Mario Smarduch wrote: On 07/01/2015 02:49 AM, Christoffer Dall wrote: On Wed, Jun 24, 2015 at 05:04:10PM -0700, Mario Smarduch wrote: Currently we save/restore fp/simd on each exit. Fist patch optimizes arm64 save/restore, we only do so on Guest

RE: [RFC 09/17] bypass: IRQ bypass manager proto by Alex

2015-07-02 Thread Wu, Feng
-Original Message- From: Eric Auger [mailto:eric.au...@linaro.org] Sent: Thursday, July 02, 2015 9:17 PM To: eric.au...@st.com; eric.au...@linaro.org; linux-arm-ker...@lists.infradead.org; kvm...@lists.cs.columbia.edu; kvm@vger.kernel.org; christoffer.d...@linaro.org;

RE: [RFC 12/17] irq: bypass: Extend skeleton for ARM forwarding control

2015-07-02 Thread Wu, Feng
-Original Message- From: Paolo Bonzini [mailto:pbonz...@redhat.com] Sent: Thursday, July 02, 2015 9:41 PM To: Eric Auger; eric.au...@st.com; linux-arm-ker...@lists.infradead.org; kvm...@lists.cs.columbia.edu; kvm@vger.kernel.org; christoffer.d...@linaro.org; marc.zyng...@arm.com;

RE: [RFC 12/17] irq: bypass: Extend skeleton for ARM forwarding control

2015-07-02 Thread Wu, Feng
-Original Message- From: Eric Auger [mailto:eric.au...@linaro.org] Sent: Thursday, July 02, 2015 9:17 PM To: eric.au...@st.com; eric.au...@linaro.org; linux-arm-ker...@lists.infradead.org; kvm...@lists.cs.columbia.edu; kvm@vger.kernel.org; christoffer.d...@linaro.org;

Re: [PATCH 7/7] KVM: arm: implement kvm_set_msi by gsi direct mapping

2015-07-02 Thread Eric Auger
Hi Andre, On 07/02/2015 07:10 PM, Andre Przywara wrote: Hi Eric, On 29/06/15 16:37, Eric Auger wrote: If the ITS modality is not available, let's simply support MSI injection by transforming the MSI.data into an SPI ID. This becomes possible to use KVM_SIGNAL_MSI ioctl for arm too.

RE: [RFC 12/17] irq: bypass: Extend skeleton for ARM forwarding control

2015-07-02 Thread Wu, Feng
-Original Message- From: Wu, Feng Sent: Friday, July 03, 2015 10:20 AM To: Paolo Bonzini; Eric Auger; eric.au...@st.com; linux-arm-ker...@lists.infradead.org; kvm...@lists.cs.columbia.edu; kvm@vger.kernel.org; christoffer.d...@linaro.org; marc.zyng...@arm.com;

Re: [RFC 09/17] bypass: IRQ bypass manager proto by Alex

2015-07-02 Thread Eric Auger
Hi Feng, On 07/03/2015 04:16 AM, Wu, Feng wrote: -Original Message- From: Eric Auger [mailto:eric.au...@linaro.org] Sent: Thursday, July 02, 2015 9:17 PM To: eric.au...@st.com; eric.au...@linaro.org; linux-arm-ker...@lists.infradead.org; kvm...@lists.cs.columbia.edu;

Re: [PATCH 7/7] KVM: arm: implement kvm_set_msi by gsi direct mapping

2015-07-02 Thread Andre Przywara
Hi Eric, On 29/06/15 16:37, Eric Auger wrote: If the ITS modality is not available, let's simply support MSI injection by transforming the MSI.data into an SPI ID. This becomes possible to use KVM_SIGNAL_MSI ioctl for arm too. Signed-off-by: Eric Auger eric.au...@linaro.org ---

Re: [PATCH v3 0/2] arm/arm64: KVM: Optimize arm64 fp/simd, saves 30-50% on exits

2015-07-02 Thread Mario Smarduch
On 07/01/2015 02:49 AM, Christoffer Dall wrote: On Wed, Jun 24, 2015 at 05:04:10PM -0700, Mario Smarduch wrote: Currently we save/restore fp/simd on each exit. Fist patch optimizes arm64 save/restore, we only do so on Guest access. hackbench and several lmbench tests show anywhere from 30% to

Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 20:01, Xiao Guangrong wrote: Thanks for your review, Stefan and Paolo! On 07/02/2015 05:52 PM, Paolo Bonzini wrote: On 02/07/2015 11:20, Stefan Hajnoczi wrote: Currently, the NVDIMM driver has been merged into upstream Linux Kernel and this patchset tries to enable it

Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Xiao Guangrong
Thanks for your review, Stefan and Paolo! On 07/02/2015 05:52 PM, Paolo Bonzini wrote: On 02/07/2015 11:20, Stefan Hajnoczi wrote: Currently, the NVDIMM driver has been merged into upstream Linux Kernel and this patchset tries to enable it in virtualization field From a device model

Re: [Qemu-devel] [PATCH 14/16] nvdimm: support NFIT_CMD_GET_CONFIG_SIZE function

2015-07-02 Thread Xiao Guangrong
On 07/02/2015 05:23 PM, Stefan Hajnoczi wrote: On Wed, Jul 01, 2015 at 10:50:30PM +0800, Xiao Guangrong wrote: +static uint32_t dsm_cmd_config_size(struct dsm_buffer *in, struct dsm_out *out) +{ +GSList *list = get_nvdimm_built_list(); +PCNVDIMMDevice *nvdimm =

[PATCH 3/12] kvm: add hyper-v crash msrs values

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Added Hyper-V crash msrs values - HV_X64_MSR_CRASH*. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com CC: Paolo Bonzini pbonz...@redhat.com CC:

[PATCH 1/12] kvm/x86: move Hyper-V MSR's/hypercall code into hyperv.c file

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com This patch introduce Hyper-V related source code file - hyperv.c and per vm and per vcpu hyperv context structures. All Hyper-V MSR's and hypercall code moved into hyperv.c. All Hyper-V kvm/vcpu fields moved into appropriate hyperv context structures.

[PATCH 5/12] kvm: added KVM_REQ_HV_CRASH value to notify qemu about hyper-v crash

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Added KVM_REQ_HV_CRASH - vcpu request used for notify user space(QEMU) about Hyper-V crash. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com CC:

[PATCH 2/12] kvm: introduce vcpu_debug = kvm_debug + vcpu context

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com vcpu_debug is useful macro like kvm_debug but additionally includes vcpu context inside output. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com

[PATCH 6/12] kvm/x86: mark hyper-v crash msrs as partition wide

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Hyper-V crash msr's are per vm, aren't per vcpu, so mark them as partition wide. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com CC: Paolo

[PATCH v4 0/12] HyperV equivalent of pvpanic driver

2015-07-02 Thread Denis V. Lunev
ndows 2012 guests can notify hypervisor about occurred guest crash (Windows bugcheck(BSOD)) by writing specific Hyper-V msrs. This patch does handling of this MSR's by KVM and sending notification to user space that allows to gather Windows guest crash dump by QEMU/LIBVIRT. The idea is to

[PATCH 4/12] kvm/x86: added hyper-v crash msrs into kvm hyperv context

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Added kvm Hyper-V context hv crash variables as storage of Hyper-V crash msrs. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com CC: Paolo Bonzini

[PATCH 7/12] kvm/x86: added hyper-v crash data and ctl msr's get/set'ers

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Added hyper-v crash msr's(HV_X64_MSR_CRASH*) data and control geters and setters. Userspace should check that such msr's available by check of KVM_CAP_HYPERV_MSR_CRASH capability. User space allowed to setup Hyper-V crash ctl msr. This msr should be

[PATCH 01/12] kvm/x86: move Hyper-V MSR's/hypercall code into hyperv.c file

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com This patch introduce Hyper-V related source code file - hyperv.c and per vm and per vcpu hyperv context structures. All Hyper-V MSR's and hypercall code moved into hyperv.c. All Hyper-V kvm/vcpu fields moved into appropriate hyperv context structures.

[PATCH 08/12] kvm/x86: add sending hyper-v crash notification to user space

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Sending of notification is done by exiting vcpu to user space if KVM_REQ_HV_CRASH is enabled for vcpu. At exit to user space the kvm_run structure contains system_event with type KVM_SYSTEM_EVENT_CRASH to notify about guest crash occured.

[PATCH 07/12] kvm/x86: added hyper-v crash data and ctl msr's get/set'ers

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Added hyper-v crash msr's(HV_X64_MSR_CRASH*) data and control geters and setters. Userspace should check that such msr's available by check of KVM_CAP_HYPERV_MSR_CRASH capability. User space allowed to setup Hyper-V crash ctl msr. This msr should be

[PATCH 12/12] qemu/kvm/x86: hyper-v crash msrs set/get'ers and migration

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com KVM Hyper-V based guests can notify hypervisor about occurred guest crash by writing into Hyper-V crash MSR's. This patch does handling and migration of HV_X64_MSR_CRASH_P0-P4, HV_X64_MSR_CRASH_CTL msrs. User can enable these MSR's by 'hv-crash'

[PATCH v5 0/12] HyperV equivalent of pvpanic driver

2015-07-02 Thread Denis V. Lunev
Windows 2012 guests can notify hypervisor about occurred guest crash (Windows bugcheck(BSOD)) by writing specific Hyper-V msrs. This patch does handling of this MSR's by KVM and sending notification to user space that allows to gather Windows guest crash dump by QEMU/LIBVIRT. The idea is to

[PATCH 02/12] kvm: introduce vcpu_debug = kvm_debug + vcpu context

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com vcpu_debug is useful macro like kvm_debug but additionally includes vcpu context inside output. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com

Re: [PATCH 05/10] KVM: arm/arm64: vgic: Relax vgic_can_sample_irq for edge IRQs

2015-07-02 Thread Christoffer Dall
On Wed, Jul 01, 2015 at 07:18:40PM +0100, Marc Zyngier wrote: On 01/07/15 12:58, Christoffer Dall wrote: On Wed, Jul 01, 2015 at 10:17:52AM +0100, Marc Zyngier wrote: On 30/06/15 21:19, Christoffer Dall wrote: On Mon, Jun 08, 2015 at 06:04:00PM +0100, Marc Zyngier wrote: We only set the

Re: [PATCH 07/12] kvm/x86: added hyper-v crash data and ctl msr's get/set'ers

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 18:07, Denis V. Lunev wrote: From: Andrey Smetanin asmeta...@virtuozzo.com Added hyper-v crash msr's(HV_X64_MSR_CRASH*) data and control geters and setters. Userspace should check that such msr's available by check of KVM_CAP_HYPERV_MSR_CRASH capability. It should use the

[PATCH 8/12] kvm/x86: add sending hyper-v crash notification to user space

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Sending of notification is done by exiting vcpu to user space if KVM_REQ_HV_CRASH is enabled for vcpu. At exit to user space the kvm_run structure contains system_event with type KVM_SYSTEM_EVENT_CRASH to notify about guest crash occured.

[PATCH 03/12] kvm: add hyper-v crash msrs values

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Added Hyper-V crash msrs values - HV_X64_MSR_CRASH*. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com CC: Paolo Bonzini pbonz...@redhat.com CC:

[PATCH 06/12] kvm/x86: mark hyper-v crash msrs as partition wide

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Hyper-V crash msr's are per vm, aren't per vcpu, so mark them as partition wide. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com CC: Paolo

[PATCH 09/12] qemu: added qemu_system_guest_panicked() - generic guest panic handler

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com There are pieces of guest panic handling code that can be shared in one generic function. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org CC: Paolo Bonzini pbonz...@redhat.com CC: Andreas Färber

[PATCH 11/12] qemu: add crash_occurred flag into CPUState

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com CPUState-crash_occurred value inside CPUState marks that guest crash occurred. This value added into cpu common migration subsection. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org CC: Paolo

[PATCH 10/12] qemu/kvm: added kvm system event crash handler

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com KVM kernel can receive guest crash events. Patch code calls appropriate handler for kernel guest crash event. Guest crash event recognized by KVM_SYSTEM_EVENT_CRASH type of system event. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com

[PATCH 04/12] kvm/x86: added hyper-v crash msrs into kvm hyperv context

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Added kvm Hyper-V context hv crash variables as storage of Hyper-V crash msrs. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com CC: Paolo Bonzini

[PATCH 05/12] kvm: added KVM_REQ_HV_CRASH value to notify qemu about hyper-v crash

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin asmeta...@virtuozzo.com Added KVM_REQ_HV_CRASH - vcpu request used for notify user space(QEMU) about Hyper-V crash. Signed-off-by: Andrey Smetanin asmeta...@virtuozzo.com Signed-off-by: Denis V. Lunev d...@openvz.org Reviewed-by: Peter Hornyack peterhorny...@google.com CC:

Re: [PATCH 12/12] qemu/kvm/x86: hyper-v crash msrs set/get'ers and migration

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 18:07, Denis V. Lunev wrote: +if (cpu-hyperv_crash +kvm_check_extension(cs-kvm_state, KVM_CAP_HYPERV_MSR_CRASH) 0) { +c-edx |= HV_X64_GUEST_CRASH_MSR_AVAILABLE; +has_msr_hv_crash = true; +} + Please patch

  1   2   >